From 021b70b538dd2cc35f22ea20078b83aba6989799 Mon Sep 17 00:00:00 2001 From: Jonas Michaelis Date: Fri, 26 Jun 2020 14:42:56 +0200 Subject: [PATCH 1/2] feat: add release pipeline --- .github/workflows/release.yml | 24 ++++++++ .releaserc.json | 105 ++++++++++++++++++++++++++++++++++ 2 files changed, 129 insertions(+) create mode 100644 .github/workflows/release.yml create mode 100644 .releaserc.json diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..4884706 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,24 @@ +name: Release Pipeline + +on: + push: + branches: + - develop + - master + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v1 + with: + node-version: 12.16.3 + + - name: prepare + run: npm install @semantic-release/gitlab @semantic-release/exec conventional-changelog-conventionalcommits + + - name: release + run: npx semantic-release + env: + GH_TOKEN: ${{ secrets.GH_TOKEN }} diff --git a/.releaserc.json b/.releaserc.json new file mode 100644 index 0000000..fe3ab6b --- /dev/null +++ b/.releaserc.json @@ -0,0 +1,105 @@ +{ + "plugins":[ + [ + "@semantic-release/commit-analyzer", + { + "releaseRules":[ + { + "type":"refactor", + "release":"patch" + }, + { + "type":"docs", + "release":"patch" + }, + { + "type":"test", + "release":"patch" + }, + { + "type":"style", + "release":"patch" + }, + { + "type":"perf", + "release":"patch" + }, + { + "type":"ci", + "release":"patch" + }, + { + "type":"build", + "release":"patch" + } + ] + } + ], + [ + "@semantic-release/release-notes-generator", + { + "preset":"conventionalcommits", + "presetConfig":{ + "types":[ + { + "type":"feat", + "section":"Features", + "hidden":false + }, + { + "type":"fix", + "section":"Fixes", + "hidden":false + }, + { + "type":"docs", + "section":"Documentation", + "hidden":false + }, + { + "type":"style", + "section":"Styling", + "hidden":false + }, + { + "type":"refactor", + "section":"Refactor", + "hidden":false + }, + { + "type":"perf", + "section":"Performance", + "hidden":false + }, + { + "type":"test", + "section":"Tests", + "hidden":false + }, + { + "type":"ci", + "section":"CI", + "hidden":false + }, + { + "type":"chore", + "section":"Chore", + "hidden":false + } + ] + } + } + ], + [ + "@semantic-release/exec", + { + "verifyReleaseCmd":"echo ${nextRelease.version} > version" + } + ], + "@semantic-release/github" + ], + "branches":[ + {"name": "master"}, + {"name": "develop", "channel": "develop", "prerelease": "develop"} + ] + } \ No newline at end of file From 7c6f666ee7de143e22531ca681f924a2a193b658 Mon Sep 17 00:00:00 2001 From: Jonas Michaelis Date: Fri, 26 Jun 2020 14:45:32 +0200 Subject: [PATCH 2/2] docs: update name in readme --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 1146892..38c2896 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# pipeline-django-demo +# pipeline-django-semver-demo Beispiel einer Pipeline, die folgendes kann: - Outdated Check