Skip to content

Commit

Permalink
fix: create the archive after running semantic-release
Browse files Browse the repository at this point in the history
  • Loading branch information
TimPietrusky committed Apr 18, 2024
1 parent 36c02da commit b571f87
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 24 deletions.
28 changes: 18 additions & 10 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,29 @@ jobs:
with:
node-version-file: ".nvmrc"

- name: Setup 7zip
run: |
sudo apt-get update
sudo apt-get install -y p7zip-full
- name: Install dependencies
run: npm install

- name: Fix auto-fixable eslint issues
run: npm run eslint -- --fix

- name: Update the ToC in the README.md
run: npx markdown-toc README.md -i

- name: Semantic Release
run: npx semantic-release
- name: Build app
run: npm run build

- name: Semantic release
uses: codfish/semantic-release-action@v3
with:
additional-packages: |
['@semantic-release/git', '@semantic-release/changelog']
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Create archive
run: /usr/bin/7za a app.7z ./out/* ./package.json ./captain.md ./CHANGELOG.md

- name: Add archive to release
uses: softprops/action-gh-release@v1
with:
files: app.7z
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
15 changes: 1 addition & 14 deletions .releaserc
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,6 @@
"changelogFile": "CHANGELOG.md"
}
],
[
"@semantic-release/exec",
{
"prepareCmd": "npm run build && /usr/bin/7za a app.7z ./out/*"
}
],
[
"@semantic-release/git",
{
Expand All @@ -34,14 +28,7 @@
}
],
[
"@semantic-release/github",
{
"assets": [
{
"path": "app.7z"
}
]
}
"@semantic-release/github"
]
]
}

0 comments on commit b571f87

Please sign in to comment.