Skip to content

Commit

Permalink
update for create-release
Browse files Browse the repository at this point in the history
  • Loading branch information
m2Giles committed Nov 19, 2024
1 parent ef2f78e commit 73314df
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 9 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build-iso.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ jobs:
just check
- name: Maximize Build Space
if: contains(fromJson('["workflow_dispatch", "workflow_call"]'), github.event_name) || github.event.schedule == '41 6 * * 0'
uses: ublue-os/remove-unwanted-software@v7

- name: Build ISO
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/changelogs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
if: contains(fromJson('["stable", "bazzite"]'), inputs.target)
shell: bash
run: |
set -eoux pipefail
touch url.md
for artifact in $(find url-${{ inputs.target }}-*);
do
Expand All @@ -48,19 +49,18 @@ jobs:
- name: Generate Release Text
id: generate-release
run: |
set -eoux pipefail
python3 ./changelogs.py \
"${{ inputs.target }}" \
./output.env ./changelog.md --workdir . --handwritten "${{ inputs.handwritten }}" --urlmd "${{ steps.merge-artifacts.outputs.urlmd }}"
source ./output.env
echo "title=${TITLE}" >> $GITHUB_OUTPUT
echo "tag=${TAG}" >> $GITHUB_OUTPUT
./output-${{ inputs.target }}.env ./changelog-${{ inputs.target }}.md --workdir . --handwritten "${{ inputs.handwritten }}" --urlmd "${{ steps.merge-artifacts.outputs.urlmd }}"
source ./output-${{ inputs.target }}.env
- name: Upload Changelogs as Artifact
uses: actions/upload-artifact@v4
with:
name: changelogs-${{ inputs.target }}
path:
./changelog.md
./changelog-${{ inputs.target }}.md
if-no-files-found: error
retention-days: 0
compression-level: 0
Expand Down
9 changes: 6 additions & 3 deletions .github/workflows/create-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,22 @@ jobs:
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Download Artifacts
uses: actions/download-artifact@v4
with:
pattern: changelogs**
merge-multiple: false
pattern: changelogs-*
merge-multiple: true
run-id: ${{ inputs.run-id || github.run_id }}

- name: Prepare Release
id: prepare-release
shell: bash
run: |
set -eoux pipefail
cat changelogs-*/changelog.md >> changelog.md
cat changelog*.md > changelog.md
last_tag=$(git tag --list m2os-* | sort -r | head -1)
date_extract="$(echo ${last_tag:-} | cut -d "-" -f 2 | cut -d "." -f 1)"
date_version="$(echo ${last_tag:-} | cut -d "." -f 2)"
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
m2os_*
previous.manifest*
changelog-*.md
changelog.md
output-*.env
output.env
version.txt
2 changes: 1 addition & 1 deletion Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ run-iso image="bluefin":
changelogs branch="stable" urlmd="" handwritten="":
#!/usr/bin/bash
set -eoux pipefail
python3 changelogs.py {{ branch }} ./output.env ./changelog.md --workdir . --handwritten "{{ handwritten }}" --urlmd "{{ urlmd }}"
python3 changelogs.py {{ branch }} ./output-{{ branch }}.env ./changelog-{{ branch }}.md --workdir . --handwritten "{{ handwritten }}" --urlmd "{{ urlmd }}"

# Verify Container with Cosign
[group('Utility')]
Expand Down

0 comments on commit 73314df

Please sign in to comment.