Update .github/workflows/update-colorschemes.yml to track the latest release and update the ghostty-specific download

This commit is contained in:
azhn
2025-09-13 07:17:00 +10:00
parent 928f5492dc
commit ffa54dceea

View File

@@ -40,9 +40,11 @@ jobs:
- name: Run zig fetch
id: zig_fetch
run: |
UPSTREAM_REV="$(curl "https://api.github.com/repos/mbadolato/iTerm2-Color-Schemes/commits/master" | jq -r '.sha')"
nix develop -c zig fetch --save="iterm2_themes" "https://github.com/mbadolato/iTerm2-Color-Schemes/archive/$UPSTREAM_REV.tar.gz"
echo "upstream_rev=$UPSTREAM_REV" >> "$GITHUB_OUTPUT"
# Get the latest release from iTerm2-Color-Schemes
RELEASE_INFO=$(gh api repos/mbadolato/iTerm2-Color-Schemes/releases/latest)
TAG_NAME=$(echo "$RELEASE_INFO" | jq -r '.tag_name')
nix develop -c zig fetch --save="iterm2_themes" "https://github.com/mbadolato/iTerm2-Color-Schemes/releases/download/${TAG_NAME}/ghostty-themes.tgz"
echo "tag_name=$TAG_NAME" >> $GITHUB_OUTPUT
- name: Update zig cache hash
run: |
@@ -71,5 +73,5 @@ jobs:
build.zig.zon.json
flatpak/zig-packages.json
body: |
Upstream revision: https://github.com/mbadolato/iTerm2-Color-Schemes/tree/${{ steps.zig_fetch.outputs.upstream_rev }}
Upstream release: https://github.com/mbadolato/iTerm2-Color-Schemes/releases/tag/${{ steps.zig_fetch.outputs.tag_name }}
labels: dependencies