forked from HugoBlox/kit
-
Notifications
You must be signed in to change notification settings - Fork 0
67 lines (57 loc) · 1.72 KB
/
Copy pathrelease-modules.yml
File metadata and controls
67 lines (57 loc) · 1.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: Release HugoBlox Modules
on:
workflow_dispatch:
inputs:
dry_run:
description: "Run without committing/tagging"
type: boolean
default: true
propagate:
description: "Propagate dependency bumps to dependents"
type: boolean
default: true
permissions:
contents: write
concurrency:
group: release-modules
cancel-in-progress: false
jobs:
release:
runs-on: ubuntu-latest
env:
LOG_LEVEL: INFO
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.13'
- name: Install Poetry
uses: snok/install-poetry@v1
with:
version: 1.8.3
virtualenvs-create: true
virtualenvs-in-project: true
- name: Install dependencies
run: |
poetry --version
poetry install --no-interaction --no-ansi
- name: Configure Git identity
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
- name: Show plan (dry run)
if: ${{ inputs.dry_run }}
run: |
poetry run python scripts/release_modules.py --print-plan --log-level $LOG_LEVEL
- name: Release (commit, tag, push)
if: ${{ !inputs.dry_run }}
run: |
if [ "${{ inputs.propagate }}" = "true" ]; then
poetry run python scripts/release_modules.py --yes --propagate --log-level $LOG_LEVEL
else
poetry run python scripts/release_modules.py --yes --no-propagate --log-level $LOG_LEVEL
fi