ci: add beta release channel
This commit is contained in:
parent
4646491fd4
commit
2e17ba2085
2 changed files with 33 additions and 6 deletions
|
@ -12,7 +12,7 @@ variables:
|
|||
|
||||
when:
|
||||
event: tag
|
||||
evaluate: CI_COMMIT_TAG matches "^[0-9]+\\\\.[0-9]+\\\\.[0-9]+$"
|
||||
evaluate: CI_COMMIT_TAG matches "^[0-9]+\\\\.[0-9]+\\\\.[0-9]+(-[0-9]+)?$"
|
||||
|
||||
depends_on:
|
||||
- checks
|
||||
|
@ -44,6 +44,20 @@ steps:
|
|||
commands:
|
||||
- <<: *enable_pnpm
|
||||
- pnpm changelog
|
||||
choose-latest-channel:
|
||||
group: prepare-release
|
||||
image: alpine:latest
|
||||
commands:
|
||||
- echo latest > .RELEASE_CHANNEL
|
||||
when:
|
||||
evaluate: CI_COMMIT_TAG matches "^[0-9]+\\\\.[0-9]+\\\\.[0-9]+$"
|
||||
choose-beta-channel:
|
||||
group: prepare-release
|
||||
image: alpine:latest
|
||||
commands:
|
||||
- echo beta > .RELEASE_CHANNEL
|
||||
when:
|
||||
evaluate: CI_COMMIT_TAG matches "^[0-9]+\\\\.[0-9]+\\\\.[0-9]+-[0-9]+$"
|
||||
release:
|
||||
image: woodpeckerci/plugin-gitea-release
|
||||
settings:
|
||||
|
@ -55,14 +69,15 @@ steps:
|
|||
- ${CI_REPO_NAME}/system.json
|
||||
api_key:
|
||||
from_secret: forge_token
|
||||
publish-latest-manifest:
|
||||
publish-manifest:
|
||||
group: publish
|
||||
image: alpine:latest
|
||||
commands:
|
||||
- apk update
|
||||
- apk add curl
|
||||
- 'curl --header "Authorization: token $${FORGE_TOKEN}" -X "DELETE" "${CI_FORGE_URL}/api/packages/${CI_REPO_OWNER}/generic/${CI_REPO_NAME}/latest/system.json"'
|
||||
- 'curl --fail --header "Authorization: token $${FORGE_TOKEN}" --upload-file ${CI_REPO_NAME}/system.json "${CI_FORGE_URL}/api/packages/${CI_REPO_OWNER}/generic/${CI_REPO_NAME}/latest/system.json"'
|
||||
- export RELEASE_CHANNEL=$(cat .RELEASE_CHANNEL)
|
||||
- 'curl --header "Authorization: token $${FORGE_TOKEN}" -X "DELETE" "${CI_FORGE_URL}/api/packages/${CI_REPO_OWNER}/generic/${CI_REPO_NAME}/$${RELEASE_CHANNEL}/system.json"'
|
||||
- 'curl --fail --header "Authorization: token $${FORGE_TOKEN}" --upload-file ${CI_REPO_NAME}/system.json "${CI_FORGE_URL}/api/packages/${CI_REPO_OWNER}/generic/${CI_REPO_NAME}/$${RELEASE_CHANNEL}/system.json"'
|
||||
secrets:
|
||||
- forge_token
|
||||
publish-to-foundry-admin:
|
||||
|
@ -78,3 +93,5 @@ steps:
|
|||
- fvtt_package_id
|
||||
- fvtt_username
|
||||
- fvtt_password
|
||||
when:
|
||||
evaluate: CI_COMMIT_TAG matches "^[0-9]+\\\\.[0-9]+\\\\.[0-9]+$"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue