You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/if-nodejs-version-bump.yml
+10-5Lines changed: 10 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -46,18 +46,23 @@ jobs:
46
46
# There is no need to substract "v" from the tag as version script handles it
47
47
# When adding "bump:version" script in package.json, make sure no tags are added by default (--no-git-tag-version) as they are already added by release workflow
48
48
# When adding "bump:version" script in package.json, make sure --allow-same-version is set in case someone forgot and updated package.json manually and we want to avoide this action to fail and raise confusion
49
-
run: VERSION=${{github.event.release.tag_name}} npm run bump:version
49
+
env:
50
+
VERSION: ${{github.event.release.tag_name}}
51
+
run: npm run bump:version
50
52
- if: steps.packagejson.outputs.exists == 'true'
51
53
name: Create Pull Request with updated asset files including package.json
52
54
uses: peter-evans/create-pull-request@38e0b6e68b4c852a5500a94740f0e535e0d7ba54 # use 4.2.4 https://github.com/peter-evans/create-pull-request/releases/tag/v4.2.4
- name: Publish information about the release to Twitter # tweet only if detected version change is not a patch
70
81
# tweet goes out even if the type is not major or minor but "You need provide version number to compare."
71
82
# it is ok, it just means we did not identify previous version as we are tweeting out information about the release for the first time
72
83
if: steps.releasetype.outputs.type != 'null' && steps.releasetype.outputs.type != 'patch' # null means that versions are the same
73
84
uses: m1ner79/Github-Twittction@d1e508b6c2170145127138f93c49b7c46c6ff3a7 # using 2.0.0 https://github.com/m1ner79/Github-Twittction/releases/tag/v2.0.0
85
+
env:
86
+
RELEASE_TAG: ${{github.event.release.tag_name}}
87
+
REPO_NAME: ${{github.repository}}
88
+
AUTHOR_NAME: ${{ steps.author.outputs.name }}
89
+
RELEASE_URL: ${{github.event.release.html_url}}
74
90
with:
75
-
twitter_status: "Release ${{github.event.release.tag_name}} for ${{github.repository}} is out in the wild π±πͺπΎπ\n\nThank you for the contribution ${{ steps.author.outputs.name }} ${{github.event.release.html_url}}"
91
+
twitter_status: "Release ${{ env.RELEASE_TAG }} for ${{ env.REPO_NAME }} is out in the wild π±πͺπΎπ\n\nThank you for the contribution ${{ env.AUTHOR_NAME }} ${{ env.RELEASE_URL }}"
0 commit comments