From d5cca214e586f6d91080340a607ad94e3f241c7c Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Thu, 1 Sep 2022 14:54:15 -0400 Subject: fix working with repositories with different default branch names --- bin/git/git-default-branch | 4 ++++ 1 file changed, 4 insertions(+) create mode 100755 bin/git/git-default-branch (limited to 'bin') diff --git a/bin/git/git-default-branch b/bin/git/git-default-branch new file mode 100755 index 0000000..90e225f --- /dev/null +++ b/bin/git/git-default-branch @@ -0,0 +1,4 @@ +#!/bin/sh +set -eu + +git symbolic-ref refs/remotes/origin/HEAD | sed 's/.*\///' -- cgit v1.2.3-54-g00ecf