Skip to content

Commit

Permalink
Fixed create and publish actions
Browse files Browse the repository at this point in the history
  • Loading branch information
bard83 committed Dec 13, 2023
1 parent dd743f3 commit c4779dd
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 5 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/create_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,25 @@ jobs:
LATEST_TAG=${GITHUB_REF#refs/tags/}
git checkout $LATEST_TAG
- name: Prepare Artifact Folder
run: mkdir out/artifact

- name: Prepare Package
uses: DerYeger/yarn-setup-action@master
uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}

- name: Build extension
run: |
npm i -g @vscode/vsce
vsce package --yarn -o csharpextension-${GITHUB_REF#refs/tags/}.vsix
mv csharpextension-${GITHUB_REF#refs/tags/}.vsix out/artifact/csharpextension-${GITHUB_REF#refs/tags/}.vsix
- name: Upload Artifact
uses: actions/upload-artifact@master
with:
name: csharpextension-artifact
path: out/artifact

draft_release:
name: Draft Release
Expand All @@ -44,9 +55,15 @@ jobs:
id: get_tag
run: echo ::set-output name=TAG::${GITHUB_REF#refs/tags/}

- name: Download Artifact
uses: actions/download-artifact@master
with:
name: csharpextension-artifact
path: out/artifact

- name: Create Draft Release
id: draft_release
uses: softprops/action-gh-release@v1
with:
files: 'csharpextension-${GITHUB_REF#refs/tags/}.vsix'
files: 'out/artifact/csharpextension-${GITHUB_REF#refs/tags/}.vsix'
draft: true
6 changes: 3 additions & 3 deletions .github/workflows/publish_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ jobs:
- name: Check out code
uses: actions/checkout@v3

- name: Prepare publish
uses: DerYeger/yarn-setup-action@master
- name: Prepare Package
uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}

- name: Install vsce CLI
run: yarn install
run: npm i -g @vscode/vsce

- name: Publish
run: |
Expand Down

0 comments on commit c4779dd

Please sign in to comment.