diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml new file mode 100644 index 0000000..dbd1da5 --- /dev/null +++ b/.github/workflows/changelog.yml @@ -0,0 +1,15 @@ +name: Release + +on: + workflow_dispatch: + inputs: + version: + description: Release version + required: true + type: string + +jobs: + changelog: + uses: ExEr7um/workflows/.github/workflows/changelog.yml@v0.7.0 + with: + version: ${{ inputs.version }} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..044dbd6 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,12 @@ +name: Publish to VSCode Marketplace + +on: + workflow_run: + workflows: [Release] + types: [completed] + +jobs: + publish: + uses: ExEr7um/workflows/.github/workflows/publish-vscode.yml@v0.7.0 + secrets: + VSCE_PAT: ${{ secrets.VSCE_PAT }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index 2fac476..0000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Release - -on: - workflow_dispatch: - inputs: - version: - description: Release version - required: true - type: string - -permissions: - contents: write - -jobs: - release: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - - name: Setup NodeJS - uses: actions/setup-node@v3 - - - name: Configure Git - run: | - git config --global user.name "github-actions[bot]" - git config --global user.email "github-actions[bot]@users.noreply.github.com" - - - name: Generate Changelog and GH Release - run: | - npx changelogen@latest --release --push -r ${{ inputs.version }} - npx changelogen@latest gh release --token ${{ secrets.GITHUB_TOKEN }} - - - name: Release VS Code Package - env: - VSCE_PAT: ${{ secrets.VSCE_PAT }} - run: | - npx @vscode/vsce@latest publish