mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 11:40:14 +01:00
Fix the jj_push.sh script to work on macOS (#7820)
It had a few subtle GNU extensions in it that didn't work on macOS. There are simple portable alternatives so it was easy to adapt. Assisted-by: Antigravity with Gemini
This commit is contained in:
+2
-2
@@ -56,8 +56,8 @@ REMOTE="$(sed -n 's/^Changes to push to \(.*\):$/\1/p' <<<"$PLAN")"
|
|||||||
|
|
||||||
# Each updated bookmark or tag reports the commit it moves to. Deletions have no
|
# Each updated bookmark or tag reports the commit it moves to. Deletions have no
|
||||||
# such commit, and send nothing to check.
|
# such commit, and send nothing to check.
|
||||||
TARGETS="$(sed -n 's/^ \(bookmark\|tag\): .* to \([0-9a-f]\{8,\}\)\]$/\2/p' <<<"$PLAN" |
|
TARGETS="$(sed -E -n 's/^ (bookmark|tag): .* to ([0-9a-f]{8,})\]$/\2/p' <<<"$PLAN" |
|
||||||
paste -sd '|')"
|
paste -sd '|' -)"
|
||||||
|
|
||||||
# Nothing to check, so just push.
|
# Nothing to check, so just push.
|
||||||
if [[ -z "$REMOTE" || -z "$TARGETS" ]]; then
|
if [[ -z "$REMOTE" || -z "$TARGETS" ]]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user