-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from qiwi/pr_to_upstream
feat: run publish step in parallel
- Loading branch information
Showing
27 changed files
with
3,629 additions
and
3,139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,5 @@ | ||
#!/usr/bin/env node | ||
|
||
// Execa hook. | ||
if (process.argv.includes("--execasync")) { | ||
require("../lib/execaHook").hook(); | ||
} | ||
const runner = require("./runner"); | ||
|
||
// Imports. | ||
const getWorkspacesYarn = require("../lib/getWorkspacesYarn"); | ||
const multiSemanticRelease = require("../lib/multiSemanticRelease"); | ||
|
||
// Get directory. | ||
const cwd = process.cwd(); | ||
|
||
// Catch errors. | ||
try { | ||
// Get list of package.json paths according to Yarn workspaces. | ||
const paths = getWorkspacesYarn(cwd); | ||
|
||
// Do multirelease (log out any errors). | ||
multiSemanticRelease(paths, {}, { cwd }).then( | ||
() => { | ||
// Success. | ||
process.exit(0); | ||
}, | ||
error => { | ||
// Log out errors. | ||
console.error(`[multi-semantic-release]:`, error); | ||
process.exit(1); | ||
} | ||
); | ||
} catch (error) { | ||
// Log out errors. | ||
console.error(`[multi-semantic-release]:`, error); | ||
process.exit(1); | ||
} | ||
runner(process.argv); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
module.exports = (argv) => { | ||
// Imports. | ||
const getWorkspacesYarn = require("../lib/getWorkspacesYarn"); | ||
const multiSemanticRelease = require("../lib/multiSemanticRelease"); | ||
const multisemrelPkgJson = require("../package.json"); | ||
const semrelPkgJson = require("semantic-release/package.json"); | ||
|
||
// Get directory. | ||
const cwd = process.cwd(); | ||
|
||
// Catch errors. | ||
try { | ||
console.log(`multi-semantic-release version: ${multisemrelPkgJson.version}`); | ||
console.log(`semantic-release version: ${semrelPkgJson.version}`); | ||
|
||
// Get list of package.json paths according to Yarn workspaces. | ||
const paths = getWorkspacesYarn(cwd); | ||
console.log("yarn paths", paths); | ||
|
||
// Do multirelease (log out any errors). | ||
multiSemanticRelease(paths, {}, { cwd }).then( | ||
() => { | ||
// Success. | ||
process.exit(0); | ||
}, | ||
(error) => { | ||
// Log out errors. | ||
console.error(`[multi-semantic-release]:`, error); | ||
process.exit(1); | ||
} | ||
); | ||
} catch (error) { | ||
// Log out errors. | ||
console.error(`[multi-semantic-release]:`, error); | ||
process.exit(1); | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.