-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update version in core/api.cfc as part of release automation
- Loading branch information
Showing
1 changed file
with
21 additions
and
14 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,22 +41,17 @@ jobs: | |
- name: bump version | ||
run: npm version ${{ github.event.inputs.version }} | ||
|
||
- name: Push latest version | ||
run: git push origin main --follow-tags | ||
|
||
- name: get-npm-version | ||
id: package-version | ||
uses: martinbeentjes/npm-get-version-action@master | ||
|
||
- name: Create Release Notes | ||
uses: actions/[email protected] | ||
with: | ||
github-token: ${{secrets.GITHUB_TOKEN}} | ||
script: | | ||
await github.request(`POST /repos/${{ github.repository }}/releases`, { | ||
tag_name: "v${{ steps.package-version.outputs.current-version }}", | ||
generate_release_notes: true | ||
}); | ||
- name: Update version in api.cfc | ||
run: | | ||
cat core/api.cfc | sed 's/local\._taffy\.version = \"[0-9]\{1,\}\.[0-9]\{1,\}\.[0-9]\{1,\}\"/local._taffy.version = "${{ steps.package-version.outputs.current-version }}"/gi' > core/api.new.cfc | ||
rm -f core/api.cfc | ||
mv core/api.new.cfc core/api.cfc | ||
git add core/api.cfc | ||
git commit --amend --no-edit | ||
- name: Cut a docs file for the new release | ||
run: | | ||
|
@@ -66,8 +61,20 @@ jobs: | |
rm -f docs/readme.md | ||
mv docs/readme-next.md docs/readme.md | ||
git add docs/readme.md | ||
git commit -m"New doc file ${{ steps.package-version.outputs.current-version }}.md" | ||
git push | ||
git commit --amend --no-edit | ||
- name: Push latest version | ||
run: git push origin main --follow-tags | ||
|
||
- name: Create Release Notes | ||
uses: actions/[email protected] | ||
with: | ||
github-token: ${{secrets.GITHUB_TOKEN}} | ||
script: | | ||
await github.request(`POST /repos/${{ github.repository }}/releases`, { | ||
tag_name: "v${{ steps.package-version.outputs.current-version }}", | ||
generate_release_notes: true | ||
}); | ||
- name: Tweet-trigger-publish-release | ||
uses: mugi111/[email protected] | ||
|