dotfiles/.local/bin/scripts/git-ln

6 lines
246 B
Text
Raw Normal View History

2021-09-21 20:51:19 +00:00
#!/bin/bash
2021-07-13 12:14:58 +02:00
set -o pipefail
2021-07-05 19:59:15 +02:00
upCount=$(git rev-list --count HEAD...@{push} 2>/dev/null)
2021-07-20 17:21:27 +02:00
count=$(expr ${upCount:-0} + 3 \& ${upCount:-0} \> 3 \| 6)
git --no-pager lo -$count --color=always --graph HEAD @{upstream} | head -9 || git --no-pager lo -7