Skip to content
This repository has been archived by the owner on Nov 27, 2023. It is now read-only.

chore(deps): update actions/checkout action to v4 #242

chore(deps): update actions/checkout action to v4

chore(deps): update actions/checkout action to v4 #242

name: Ship js prepare release
on:
issue_comment:
types: [created]
jobs:
prepare_release:
if: |
github.event_name == 'issue_comment' &&
(github.event.comment.author_association == 'member' || github.event.comment.author_association == 'owner') &&
startsWith(github.event.comment.body, '@shipjs prepare')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: |
git fetch --prune --unshallow
- uses: actions/setup-node@v3
- run: |
yarn install
- run: |
git config --global user.email "[email protected]"
git config --global user.name "Markus Wolf"
- run: yarn shipjs prepare --yes --no-browse
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
create_done_comment:
if: success()
needs: prepare_release
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '@${{ github.actor }} `shipjs prepare` done'
})
create_fail_comment:
if: cancelled() || failure()
needs: prepare_release
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '@${{ github.actor }} `shipjs prepare` fail'
})