Files
BrowserOS/scripts/update-submodule.sh
2025-11-07 09:21:11 -08:00

16 lines
427 B
Bash

#!/usr/bin/env bash
set -euo pipefail
DIR="packages/browseros-agent"
BRANCH="${1:-main}"
git -C "$DIR" fetch origin "$BRANCH" --tags
git -C "$DIR" checkout -q "$BRANCH"
git -C "$DIR" pull -q --ff-only origin "$BRANCH"
NEW_SHA=$(git -C "$DIR" rev-parse --short HEAD)
git add "$DIR"
git commit -m "chore: sync packages/browseros-agent submodule (to $NEW_SHA)" || { echo "No changes"; exit 0; }
echo "Bumped $DIR to $NEW_SHA"