Skip to content

Commit

Permalink
refactor: simplify release workflow (#302)
Browse files Browse the repository at this point in the history
Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Co-authored-by: ben <ben@prologe.io>
  • Loading branch information
1 parent c95cfef commit 4bfb892
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 168 deletions.
33 changes: 29 additions & 4 deletions .github/workflows/manual-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,40 @@ jobs:
run: |
cd packages/plugin
pnpm version ${{ github.event.inputs.increment }} --no-git-tag-version
- name: Build plugin
run: pnpm --filter "./packages/plugin" build

- name: Update manifest and versions
- name: Create Release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
cd packages/plugin
pnpm run version
version=$(node -p "require('./packages/plugin/manifest.json').version")
# Create a temporary directory for release files
mkdir release
cp packages/plugin/dist/main.js release/
cp packages/plugin/dist/styles.css release/
cp packages/plugin/manifest.json release/
# Create release notes
echo "## Changes in this release" > release/notes.md
echo "Version bump: ${{ github.event.inputs.increment }}" >> release/notes.md
# Create the release
gh release create "$version" \
--title="Version $version" \
--notes-file=release/notes.md \
--draft=false \
release/main.js \
release/styles.css \
release/manifest.json
- name: Create and push tag
run: |
cd packages/plugin
node commit.js
version=$(node -p "require('./manifest.json').version")
git tag -a "$version" -m "Release $version"
git push origin "$version"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
59 changes: 0 additions & 59 deletions .github/workflows/release.yml

This file was deleted.

24 changes: 0 additions & 24 deletions packages/plugin/commit.js

This file was deleted.

81 changes: 0 additions & 81 deletions release.js

This file was deleted.

0 comments on commit 4bfb892

Please sign in to comment.