fix: gitea workflow
Some checks are pending
Update Nix Packages with nix-update / nix-update (push) Waiting to run
Some checks are pending
Update Nix Packages with nix-update / nix-update (push) Waiting to run
This commit is contained in:
@@ -59,8 +59,8 @@ jobs:
|
||||
|
||||
echo "::group::Checking for opencode updates"
|
||||
|
||||
# Get latest release from GitHub API
|
||||
LATEST_RELEASE=$(curl -s "https://api.github.com/repos/anomalyco/opencode/releases/latest" | jq -r '.tag_name')
|
||||
# Get latest release from GitHub API (strip v prefix for comparison)
|
||||
LATEST_RELEASE=$(curl -s "https://api.github.com/repos/anomalyco/opencode/releases/latest" | jq -r '.tag_name' | sed 's/^v//')
|
||||
|
||||
# Extract current version from flake.nix
|
||||
CURRENT_VERSION=$(grep -oP 'opencode\.url = "github:anomalyco/opencode/v\K[^"]+' flake.nix)
|
||||
@@ -73,7 +73,7 @@ jobs:
|
||||
echo "🔄 Updating opencode from $CURRENT_VERSION to $LATEST_RELEASE"
|
||||
|
||||
# Update flake.nix with new version
|
||||
sed -i 's|opencode\.url = "github:anomalyco/opencode/v.*"|opencode.url = "github:anomalyco/opencode/'"$LATEST_VERSION"'"| flake.nix
|
||||
sed -i 's|opencode\.url = "github:anomalyco/opencode/v.*"|opencode.url = "github:anomalyco/opencode/v'"$LATEST_RELEASE"'"|' flake.nix
|
||||
|
||||
# Update flake lock to fetch new revision
|
||||
nix flake update opencode
|
||||
|
||||
Reference in New Issue
Block a user