File tree Expand file tree Collapse file tree 2 files changed +6
-15
lines changed
Expand file tree Collapse file tree 2 files changed +6
-15
lines changed Original file line number Diff line number Diff line change @@ -136,4 +136,4 @@ jobs:
136136 env :
137137 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
138138 run : |
139- bash scripts/update-homebrew-tap.sh "${GITHUB_REF_NAME#v}"
139+ bash scripts/update-homebrew-tap.sh
Original file line number Diff line number Diff line change 11#! /usr/bin/env bash
22set -euo pipefail
33
4- VERSION=" $1 "
5-
6- if [ -z " $VERSION " ]; then
7- echo " VERSION argument is required"
8- exit 1
9- fi
10-
114if [ -z " ${GITHUB_TOKEN:- } " ]; then
125 echo " GITHUB_TOKEN is not set"
136 exit 1
147fi
15- TAG=" v${VERSION} "
16- curl -f -L " https://api.github.com/repos/milisp/codexia/releases/tags/${TAG} " > release.json
8+ curl -f -L \
9+ -H " Authorization: Bearer ${GITHUB_TOKEN} " \
10+ -H " Accept: application/vnd.github+json" \
11+ " https://api.github.com/repos/milisp/codexia/releases/latest" > release.json
1712RELEASE_JSON=" release.json"
1813
1914if [ ! -f " $RELEASE_JSON " ]; then
2015 echo " Error: $RELEASE_JSON not found. Please ensure it exists."
2116 exit 1
2217fi
2318
24- RELEASE_TAG=$( jq -r ' .tag_name' " $RELEASE_JSON " )
25- if [ " $RELEASE_TAG " != " $TAG " ]; then
26- echo " Error: fetched release tag ($RELEASE_TAG ) does not match expected tag ($TAG )"
27- exit 1
28- fi
19+ VERSION=$( jq -r ' .tag_name' " $RELEASE_JSON " )
2920
3021git clone https://x-access-token:${GITHUB_TOKEN} @github.com/milisp/homebrew-codexia.git
3122cd homebrew-codexia
You can’t perform that action at this time.
0 commit comments