File: update-upstream-branch.sh

package info (click to toggle)
golang-context 1.1-3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster
  • size: 104 kB
  • sloc: sh: 94; makefile: 2
file content (16 lines) | stat: -rwxr-xr-x 344 bytes parent folder | download | duplicates (41)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/bash
set -e

dir="$(dirname "$(readlink -f "$BASH_SOURCE")")"
"$dir/setup-upstream-remote.sh"

( set -x; git fetch -q upstream master )
( set -x; git update-ref refs/heads/upstream FETCH_HEAD )

echo
echo 'local "upstream" branch updated'
echo
echo 'use the following to push it:'
echo
echo '  git push -f origin upstream:upstream'
echo