diff options
author | Vijay Aravamudhan <vraravam@users.noreply.github.com> | 2022-07-01 05:30:27 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-01 00:00:27 +0000 |
commit | 1912425b21f8a93c62f3da7099a9af8cf39942dd (patch) | |
tree | 2b2795574cd99544557257d75bca5d5e5fb825de /.github | |
parent | Feature: Copy Ferdium info from the 'About' dialog into the clipboard (#402) (diff) | |
download | ferdium-app-1912425b21f8a93c62f3da7099a9af8cf39942dd.tar.gz ferdium-app-1912425b21f8a93c62f3da7099a9af8cf39942dd.tar.zst ferdium-app-1912425b21f8a93c62f3da7099a9af8cf39942dd.zip |
Moved tagging of the repo from the nightly build process to the post-publishing process [skip ci] (#404)
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/builds.yml | 9 | ||||
-rw-r--r-- | .github/workflows/tag-repos.yml | 35 |
2 files changed, 36 insertions, 8 deletions
diff --git a/.github/workflows/builds.yml b/.github/workflows/builds.yml index abc1b50d8..8d3a7646f 100644 --- a/.github/workflows/builds.yml +++ b/.github/workflows/builds.yml | |||
@@ -46,7 +46,6 @@ jobs: | |||
46 | ref: nightly | 46 | ref: nightly |
47 | submodules: recursive | 47 | submodules: recursive |
48 | fetch-depth: 0 # Note: Needed to be able to pull the 'develop' branch as well for merging | 48 | fetch-depth: 0 # Note: Needed to be able to pull the 'develop' branch as well for merging |
49 | # ssh-key: ${{ secrets.FERDIUM_PUBLISH_TOKEN }} | ||
50 | - name: Use Node.js specified in the '.nvmrc' file | 49 | - name: Use Node.js specified in the '.nvmrc' file |
51 | uses: actions/setup-node@v3 | 50 | uses: actions/setup-node@v3 |
52 | if: ${{ github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && contains(github.event.inputs.message, '[nightly branch]')) }} | 51 | if: ${{ github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && contains(github.event.inputs.message, '[nightly branch]')) }} |
@@ -77,15 +76,9 @@ jobs: | |||
77 | # there were other changes coming from the 'develop' branch (or) | 76 | # there were other changes coming from the 'develop' branch (or) |
78 | # this is a manual trigger with the key-phrase | 77 | # this is a manual trigger with the key-phrase |
79 | git checkout develop | 78 | git checkout develop |
80 | TAG_NAME=$(npm version -m "%s [skip ci]" prerelease --preid=nightly) | 79 | npm version -m "%s [skip ci]" prerelease --preid=nightly |
81 | git commit --all --amend --no-edit --no-verify | 80 | git commit --all --amend --no-edit --no-verify |
82 | git push origin develop --no-verify | 81 | git push origin develop --no-verify |
83 | git tag -f $TAG_NAME | ||
84 | git push origin --tags --no-verify | ||
85 | # Also tag the submodule so as to help identify which changes went into which nightly release | ||
86 | # TODO: Not working due to cross-repo access issues by the github-action bot | ||
87 | # git -C recipes tag -f $TAG_NAME | ||
88 | # git -C recipes push origin --tags --no-verify | ||
89 | 82 | ||
90 | git checkout nightly | 83 | git checkout nightly |
91 | fi | 84 | fi |
diff --git a/.github/workflows/tag-repos.yml b/.github/workflows/tag-repos.yml new file mode 100644 index 000000000..a8459c1e6 --- /dev/null +++ b/.github/workflows/tag-repos.yml | |||
@@ -0,0 +1,35 @@ | |||
1 | name: Tag all repos | ||
2 | |||
3 | on: | ||
4 | release: | ||
5 | types: [published] | ||
6 | # Manual trigger from the UI | ||
7 | workflow_dispatch: | ||
8 | |||
9 | jobs: | ||
10 | bump-casks: | ||
11 | runs-on: macos-latest | ||
12 | steps: | ||
13 | - name: Checkout code along with submodules for the 'nightly' branch if the trigger event is 'scheduled' | ||
14 | uses: actions/checkout@v3 | ||
15 | if: ${{ contains(github.event.release.tag_name, 'nightly') }} | ||
16 | with: | ||
17 | ref: nightly | ||
18 | submodules: recursive | ||
19 | fetch-depth: 0 # Note: Needed to be able to pull the 'develop' branch as well for merging | ||
20 | - name: Checkout code along with submodules for the 'release' branch if the trigger event is 'scheduled' | ||
21 | uses: actions/checkout@v3 | ||
22 | if: ${{ !contains(github.event.release.tag_name, 'nightly') }} | ||
23 | with: | ||
24 | ref: release | ||
25 | submodules: recursive | ||
26 | fetch-depth: 0 # Note: Needed to be able to pull the 'develop' branch as well for merging | ||
27 | - name: Tag the branch | ||
28 | run: | | ||
29 | TAG_NAME=$(node -p 'require("./package.json").version') | ||
30 | git tag -f $TAG_NAME | ||
31 | git push origin --tags --no-verify | ||
32 | # Also tag the submodule so as to help identify which changes went into which nightly release | ||
33 | # TODO: Not working due to cross-repo access issues by the github-action bot | ||
34 | # git -C recipes tag -f $TAG_NAME | ||
35 | # git -C recipes push origin --tags --no-verify | ||