mirror of
https://gitea.com/actions/gitea-release-action.git
synced 2024-11-10 10:21:07 +07:00
chore: change to manual
This commit is contained in:
parent
3494e663be
commit
1050fbf050
55
.github/workflows/publish.yml
vendored
55
.github/workflows/publish.yml
vendored
@ -1,37 +1,30 @@
|
|||||||
name: Build and Publish
|
name: Update Main Version
|
||||||
|
run-name: Move ${{ github.event.inputs.major_version }} to ${{ github.event.inputs.target }}
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
workflow_dispatch:
|
||||||
tags:
|
inputs:
|
||||||
- 'v[0-9]+.[0-9]+.[0-9]+'
|
target:
|
||||||
|
description: The tag or reference to use
|
||||||
|
required: true
|
||||||
|
major_version:
|
||||||
|
type: choice
|
||||||
|
description: The major version to update
|
||||||
|
options:
|
||||||
|
- v1
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
tag:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
name: 构建
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@v3
|
||||||
uses: actions/checkout@v4
|
with:
|
||||||
with:
|
fetch-depth: 0
|
||||||
ref: 'main'
|
- name: Git config
|
||||||
- uses: actions/setup-node@v4
|
run: |
|
||||||
with:
|
git config user.name github-actions
|
||||||
node-version: 16
|
git config user.email github-actions@github.com
|
||||||
cache: 'npm'
|
- name: Tag new target
|
||||||
cache-dependency-path: package-lock.json
|
run: git tag -f ${{ github.event.inputs.major_version }} ${{ github.event.inputs.target }}
|
||||||
- run: npm install -D
|
- name: Push new tag
|
||||||
- run: npm run package
|
run: git push origin ${{ github.event.inputs.major_version }} --force
|
||||||
- run: |
|
|
||||||
git config user.name github-actions
|
|
||||||
git config user.email github-actions@github.com
|
|
||||||
- run: |
|
|
||||||
git add .
|
|
||||||
git commit -m "Auto Build"
|
|
||||||
- id: get_version
|
|
||||||
uses: battila7/get-version-action@v2
|
|
||||||
- run: git tag -f "v${{ steps.get_version.outputs.major }}"
|
|
||||||
- run: git push
|
|
||||||
- run: git push --tags -f
|
|
Loading…
Reference in New Issue
Block a user