Skip to content
This repository was archived by the owner on Jul 18, 2024. It is now read-only.

build(deps-dev): bump @types/react from 18.2.74 to 18.2.75 #84

build(deps-dev): bump @types/react from 18.2.74 to 18.2.75

build(deps-dev): bump @types/react from 18.2.74 to 18.2.75 #84

Workflow file for this run

name: Release
on:
pull_request:
types: [opened, reopened, labeled]
jobs:
Patch:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.user.login == 'dependabot[bot]' || contains(github.event.pull_request.labels[*].name, 'patch') }}
steps:
- name: Checkout Base Branch
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.base.ref }}
- name: Version Get
run: |
NPM_VERSION=$(node -e "console.log(require('./package.json').version)")
printf "NPM_VERSION=%s" "$NPM_VERSION" >> $GITHUB_ENV
- uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Version Get
run: |
NPM_NEW_VERSION=$(node -e "console.log(require('./package.json').version)")
printf "NPM_NEW_VERSION=%s" "$NPM_NEW_VERSION" >> $GITHUB_ENV
- name: Automatic Rebase
uses: peter-evans/rebase@v3
- name: Update Version
if: ${{ env.NPM_VERSION >= env.NPM_NEW_VERSION }}
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
npm version patch
- name: Push changes
if: ${{ env.NPM_VERSION >= env.NPM_NEW_VERSION }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git push -u -f origin ${{ github.event.pull_request.head.ref }}
Minor:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.user.login != 'dependabot[bot]' || contains(github.event.pull_request.labels[*].name, 'minor') }}
steps:
- name: Checkout Base Branch
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.base.ref }}
- name: Version Get
run: |
NPM_VERSION=$(node -e "console.log(require('./package.json').version)")
printf "NPM_VERSION=%s" "$NPM_VERSION" >> $GITHUB_ENV
- uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Version Get
run: |
NPM_NEW_VERSION=$(node -e "console.log(require('./package.json').version)")
printf "NPM_NEW_VERSION=%s" "$NPM_NEW_VERSION" >> $GITHUB_ENV
- name: Automatic Rebase
uses: peter-evans/rebase@v3
- name: Update Version
if: ${{ env.NPM_VERSION >= env.NPM_NEW_VERSION }}
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
npm version minor
- name: Push changes
if: ${{ env.NPM_VERSION >= env.NPM_NEW_VERSION }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git push -u -f origin ${{ github.event.pull_request.head.ref }}
Major:
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.user.login != 'dependabot[bot]' || contains(github.event.pull_request.labels[*].name, 'major') }}
steps:
- name: Checkout Base Branch
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.base.ref }}
- name: Version Get
run: |
NPM_VERSION=$(node -e "console.log(require('./package.json').version)")
printf "NPM_VERSION=%s" "$NPM_VERSION" >> $GITHUB_ENV
- uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.ref }}
- name: Version Get
run: |
NPM_NEW_VERSION=$(node -e "console.log(require('./package.json').version)")
printf "NPM_NEW_VERSION=%s" "$NPM_NEW_VERSION" >> $GITHUB_ENV
- name: Automatic Rebase
uses: peter-evans/rebase@v3
- name: Update Version
if: ${{ env.NPM_VERSION >= env.NPM_NEW_VERSION }}
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
npm version major
- name: Push changes
if: ${{ env.NPM_VERSION >= env.NPM_NEW_VERSION }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git push -u -f origin ${{ github.event.pull_request.head.ref }}