forked from mammadataei/cypress-vite
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add release workflow (mammadataei#31)
- Loading branch information
1 parent
2cdf9e5
commit 9c53e2a
Showing
1 changed file
with
44 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
name: release-please | ||
|
||
jobs: | ||
release-please: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: google-github-actions/release-please-action@v3 | ||
id: release | ||
with: | ||
release-type: node | ||
package-name: cypress-vite | ||
|
||
- uses: actions/checkout@v3 | ||
if: ${{ steps.release.outputs.release_created }} | ||
|
||
- uses: pnpm/action-setup@v2 | ||
with: | ||
version: 7 | ||
run_install: false | ||
if: ${{ steps.release.outputs.release_created }} | ||
|
||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 18.x | ||
if: ${{ steps.release.outputs.release_created }} | ||
|
||
- name: Set pnpm publishing config | ||
run: pnpm config set '//registry.npmjs.org/:_authToken' "${NPM_AUTH_TOKEN}" | ||
env: | ||
NPM_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} | ||
if: ${{ steps.release.outputs.release_created }} | ||
|
||
- name: Install dependencies and build | ||
run: pnpm i && pnpm build | ||
if: ${{ steps.release.outputs.release_created }} | ||
|
||
- name: Publish to npm | ||
run: pnpm publish | ||
if: ${{ steps.release.outputs.release_created }} |