add back release pipeline
This commit is contained in:
parent
3ad1abdaac
commit
1c010624b9
|
@ -71,6 +71,56 @@ local PipelineTest(deps=[],) = {
|
|||
},
|
||||
};
|
||||
|
||||
local PipelineRelease(deps=[],) = {
|
||||
kind: 'pipeline',
|
||||
image_pull_secrets: ['docker_config'],
|
||||
name: 'release',
|
||||
platform: {
|
||||
os: 'linux',
|
||||
arch: 'amd64',
|
||||
},
|
||||
steps: [
|
||||
{
|
||||
name: 'changelog-generate',
|
||||
image: 'thegeeklab/git-chglog',
|
||||
commands: [
|
||||
'git fetch -tq',
|
||||
'git-chglog --no-color --no-emoji -o CHANGELOG.md ${DRONE_TAG:---next-tag unreleased unreleased}',
|
||||
],
|
||||
},
|
||||
{
|
||||
name: 'changelog-format',
|
||||
image: 'thegeeklab/alpine-tools',
|
||||
commands: [
|
||||
'prettier CHANGELOG.md',
|
||||
'prettier -w CHANGELOG.md',
|
||||
],
|
||||
},
|
||||
{
|
||||
name: 'publish',
|
||||
image: 'plugins/github-release',
|
||||
settings: {
|
||||
overwrite: true,
|
||||
api_key: {
|
||||
from_secret: 'github_token',
|
||||
},
|
||||
files: ['release/*'],
|
||||
title: '${DRONE_TAG}',
|
||||
note: 'CHANGELOG.md',
|
||||
},
|
||||
when: {
|
||||
ref: [
|
||||
'refs/tags/**',
|
||||
],
|
||||
},
|
||||
},
|
||||
],
|
||||
depends_on: deps,
|
||||
trigger: {
|
||||
ref: ['refs/heads/main', 'refs/tags/**', 'refs/pull/**'],
|
||||
},
|
||||
};
|
||||
|
||||
local PipelineDocs(deps=[],) = {
|
||||
kind: 'pipeline',
|
||||
name: 'docs',
|
||||
|
@ -137,6 +187,7 @@ local PipelineNotifications(deps=[],) = {
|
|||
|
||||
[
|
||||
PipelineTest(),
|
||||
PipelineDocs(deps=['test']),
|
||||
PipelineRelease(deps=['test'],),
|
||||
PipelineDocs(deps=['release']),
|
||||
PipelineNotifications(deps=['docs']),
|
||||
]
|
||||
|
|
42
.drone.yml
42
.drone.yml
|
@ -45,6 +45,46 @@ volumes:
|
|||
---
|
||||
depends_on:
|
||||
- test
|
||||
image_pull_secrets:
|
||||
- docker_config
|
||||
kind: pipeline
|
||||
name: release
|
||||
platform:
|
||||
arch: amd64
|
||||
os: linux
|
||||
steps:
|
||||
- commands:
|
||||
- git fetch -tq
|
||||
- git-chglog --no-color --no-emoji -o CHANGELOG.md ${DRONE_TAG:---next-tag unreleased
|
||||
unreleased}
|
||||
image: thegeeklab/git-chglog
|
||||
name: changelog-generate
|
||||
- commands:
|
||||
- prettier CHANGELOG.md
|
||||
- prettier -w CHANGELOG.md
|
||||
image: thegeeklab/alpine-tools
|
||||
name: changelog-format
|
||||
- image: plugins/github-release
|
||||
name: publish
|
||||
settings:
|
||||
api_key:
|
||||
from_secret: github_token
|
||||
files:
|
||||
- release/*
|
||||
note: CHANGELOG.md
|
||||
overwrite: true
|
||||
title: ${DRONE_TAG}
|
||||
when:
|
||||
ref:
|
||||
- refs/tags/**
|
||||
trigger:
|
||||
ref:
|
||||
- refs/heads/main
|
||||
- refs/tags/**
|
||||
- refs/pull/**
|
||||
---
|
||||
depends_on:
|
||||
- release
|
||||
kind: pipeline
|
||||
name: docs
|
||||
platform:
|
||||
|
@ -105,6 +145,6 @@ trigger:
|
|||
- failure
|
||||
---
|
||||
kind: signature
|
||||
hmac: 758e035deda2239882aef0b1654916e376f5959883149f109dcb59a30faa9d96
|
||||
hmac: 54d16ad27faa72c5a91fdd8fcf6031bdd15676183fc2edb1bd00db86551a306d
|
||||
|
||||
...
|
||||
|
|
Loading…
Reference in New Issue