@thisismanta/semantic-version 5.0.1 → 5.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/auto-npm-version.js +5 -7
- package/package.json +1 -1
package/lib/auto-npm-version.js
CHANGED
|
@@ -53,7 +53,7 @@ async function main() {
|
|
|
53
53
|
throw new Error('Expected "version" field to exist in package.json.');
|
|
54
54
|
}
|
|
55
55
|
const commits = getCommits(await getGitHistory(lastVersion));
|
|
56
|
-
console.log(`Found ${commits.length} qualified commits since v${lastVersion}`);
|
|
56
|
+
console.log(`Found ${commits.length} qualified commit${commits.length === 1 ? '' : 's'} since v${lastVersion}`);
|
|
57
57
|
(0, debug_1.debug)('commits »', JSON.stringify(commits, null, 2));
|
|
58
58
|
const releaseType = getReleaseType(commits);
|
|
59
59
|
(0, debug_1.debug)('releaseType »', JSON.stringify(releaseType));
|
|
@@ -73,16 +73,14 @@ async function main() {
|
|
|
73
73
|
(0, debug_1.debug)('releaseNote »', releaseNote);
|
|
74
74
|
const octokit = github.getOctokit(process.env.GITHUB_TOKEN);
|
|
75
75
|
// See https://octokit.github.io/rest.js/v19#repos-create-release
|
|
76
|
-
const
|
|
76
|
+
const releaseCreationRespond = await octokit.rest.repos.createRelease({
|
|
77
77
|
...github.context.repo,
|
|
78
78
|
tag_name: 'v' + nextVersion,
|
|
79
79
|
body: releaseNote,
|
|
80
|
-
make_latest: '
|
|
80
|
+
make_latest: 'legacy',
|
|
81
81
|
});
|
|
82
|
-
(0, debug_1.debug)('
|
|
83
|
-
|
|
84
|
-
console.log('Done with', releaseRespond.data.url);
|
|
85
|
-
}
|
|
82
|
+
(0, debug_1.debug)('releaseCreationRespond »', JSON.stringify(releaseCreationRespond, null, 2));
|
|
83
|
+
console.log('Done with a new release at', releaseCreationRespond.data.html_url);
|
|
86
84
|
}
|
|
87
85
|
async function run(command) {
|
|
88
86
|
(0, debug_1.debug)(command);
|