Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add auto-deployment #328

Merged
merged 3 commits into from
Jan 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Whenever any tag is pushed to the repo
on:
push:
tags:
- '*'

name: Deploy Extension
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
- uses: actions/[email protected]
- run: npm ci
- name: Publish to Open VSX Registry
uses: HaaLeo/publish-vscode-extension@v1
with:
# Generated via https://open-vsx.org/user-settings/tokens, valid forever?
pat: ${{ secrets.OPEN_VSX_TOKEN }}
- name: Publish to Visual Studio Marketplace
uses: HaaLeo/publish-vscode-extension@v1
with:
# https://dev.azure.com/markwiemer/_usersSettings/tokens, expires 2023-07-06
# Saved locally as "CI VS Code Marketplace Publish Token"
pat: ${{ secrets.VS_MARKETPLACE_TOKEN }}
registryUrl: https://marketplace.visualstudio.com
2 changes: 2 additions & 0 deletions .github/workflows/project-management.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,7 @@ jobs:
steps:
- uses: actions/[email protected]
with:
# https://github.com/settings/tokens
# https://github.com/vscode-autohotkey/ahkpp/settings/secrets/actions
project-url: https://github.com/orgs/vscode-autohotkey/projects/1
github-token: ${{ secrets.ADD_TO_PROJECT_PAT }}
17 changes: 9 additions & 8 deletions docs/Development.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,17 +46,18 @@ The tests should run automatically, and you should see passing output in the Deb
### Publishing

1. Tag the release
1. `git checkout main`
1. e.g. `git tag v2.8.2`
1. `git push origin v2.8.2`
1. [Create a new release for this tag](https://github.com/mark-wiemer/vscode-autohotkey-plus-plus/tags)
1. `git checkout main && git tag v2.8.2 && git push origin v2.8.2`
1. [Create a new GitHub release for this tag](https://github.com/mark-wiemer/vscode-autohotkey-plus-plus/tags)
1. Release title: Same as in [Changelog.md](../Changelog.md)
1. Description: Same as in changelog
1. Attach binary
1. Publish release
1. Publish the release through [Visual Studio Marketplace](https://marketplace.visualstudio.com/manage/publishers/mark-wiemer)
1. Select the ellipsis `Actions` icon and select `Update`.
1. Upload the `.vsix` release file packaged in a previous step.
1. Publish to Open VSX: `npx ovsx <file> -p <token>`

The release is usually available within 5 minutes of uploading.

### Validating deployment

1. [Deploy workflow](https://github.com/mark-wiemer/ahkpp/actions/workflows/deploy.yml)
1. [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=mark-wiemer.vscode-autohotkey-plus-plus)
1. [Publisher view](https://marketplace.visualstudio.com/manage/publishers/mark-wiemer)
1. [Open VSX Marketplace](https://open-vsx.org/extension/mark-wiemer/vscode-autohotkey-plus-plus)