Skip to content

Commit

Permalink
ci: push tags in postversion
Browse files Browse the repository at this point in the history
  • Loading branch information
EmileRolley committed Jun 4, 2024
1 parent 42c312d commit 88684b2
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 9 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
name: GitHub release and VSCode Extension publishing

on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_run:
workflows: ["Build, test and check format"]
branches: [main]
types:
- completed

jobs:
check_if_version_upgraded:
Expand Down Expand Up @@ -49,7 +48,7 @@ jobs:
needs:
- check_if_version_upgraded
steps:
- uses: softprops/action-gh-release@v1
- uses: softprops/action-gh-release@v2
with:
name: Release v${{ needs.check_if_version_upgraded.outputs.to_version }}
tag_name: v${{ needs.check_if_version_upgraded.outputs.to_version }}
Expand All @@ -62,6 +61,9 @@ jobs:

publish:
runs-on: ubuntu-latest
needs:
- check_if_version_upgraded
- create_github_release
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -70,9 +72,10 @@ jobs:
with:
registry-url: https://registry.npmjs.org/
node-version: 20.x
cache: yarn
- run: yarn install --frozen-lockfile
- run: yarn run compile
- name: Publish
run: yarn deploy
run: yarn publish
env:
VSCE_PAT: ${{ secrets.VSCE_PAT }}
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
"postinstall": "yarn install --cwd client && yarn install --cwd server",
"test": "sh ./scripts/e2e.sh",
"format": "prettier --write .",
"format:check": "prettier --check . server client"
"format:check": "prettier --check . server client",
"postversion": "git push --tags && git push"
},
"activationEvents": [
"onLanguage:publicodes"
Expand Down

0 comments on commit 88684b2

Please sign in to comment.