Serverless Framework relies on semantic commit messages which allow to streamline the release process (versioning and changelog generation is automated)
See proposed Commit Message Guidelines
In PR's as coming from forks (community contributions) while its welcome, we do not require to follow semantic commit messages. Yet, such PR is expected to be squash merged by project members with a single semantic commit message.
PR's coming from branches have commit messages validated with commmitlint
Releases are triggered manually by preparing a release PRs
Create the release
branch (should derive from the current master
state)
Bump version ranges of all dependencies to the latest supported versions (e.g. if the latest version of a dependency is 2.3.5
and the range in a package.json
is ^2.2.4
then it should be updated to ^2.3.5
)
Note: Unfortunately there seems no reliable utility to automate that (there's a request at npm-check-updates
)
If you handle the installation of dependencies through npm-cross-link then --bump-deps
option will bump version ranges as expected
Commit eventual dependency version updates with the following commit message:
chore: Bump dependencies
Run npm run prepare-release
command.
It'll automatically bump the version in package.json
to the expected one (by inspecting changes since the previous release) and will generate a new changelog entry.
Improve generated changelog entry in CHANGELOG.md
:
CHANGELOG.md
follows prettier formattingCommit package.json
and CHANGELOG.md
changes with the following commit message:
chore: Release
Note: For automation purpose, it must be the last commit in the PR
Push branch upstream and create a PR.
After PR is accepted by CI and one of the reviewers, merge it via "Rebase and merge" option
Further actions are automated in CI context:
master
CI build detects that release PR was merged (by fact that it covers change of version
field in package.json
file). Having that (after successful tests pass) version tag is created and pushed to the repository.Improvements to release notes can be done at any time to any already published version:
CHANGELOG.md
with desired changes (ensure they'd also end in master
)npx github-release-from-cc-changelog <version>
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。