summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/common/gt8
-rwxr-xr-xbin/extra/clock4
2 files changed, 7 insertions, 5 deletions
diff --git a/bin/common/gt b/bin/common/gt
index 53d2cab..c679b23 100755
--- a/bin/common/gt
+++ b/bin/common/gt
@@ -5,7 +5,6 @@
# dependencies:
# - git
# - $EDITOR: -e
-# - herbe (optional): -s
repos=$HOME/sync/share/git-track.txt
# prevent file not found errors
@@ -47,7 +46,8 @@ status() {
>&2 printf '\r\033[0K'
status="$(git status --porcelain 2> /dev/null | awk '{print $1}' | uniq | tr -d '\n')"
- remote="$(git branch -v 2>/dev/null | sed 's/ahead/↑/;s/behind/↓/;s/[^↓↑]*//g')"
+ remote="$(git branch -v 2>/dev/null |
+ sed '/^*/!d;s/ahead/↑/;s/behind/↓/;s/[^↓↑]*//g')"
printf '%s %s %s\n' "$repo_pretty" "$status" "$remote"
done < "$repos"
@@ -116,6 +116,6 @@ fi
if [ "$f_status" ]
then
status
- which herbe > /dev/null 2>&1 &&
- eval "herbe $(status | sed 's/"/\"/g;s/.*/"&"/' | tr '\n' ' ')" &
fi
+
+# eval "herbe $(status | sed 's/"/\"/g;s/.*/"&"/' | tr '\n' ' ')"
diff --git a/bin/extra/clock b/bin/extra/clock
index fdffae0..bd6efd2 100755
--- a/bin/extra/clock
+++ b/bin/extra/clock
@@ -7,7 +7,8 @@ then
printf 'start,end,message\n' > "$clocks"
fi
-if [ "$1" = "-c" ]
+# print clocks file prettily
+if [ "$1" = "-p" ]
then
# empty
[ "$(wc -l < "$clocks")" -eq 1 ] && exit
@@ -23,6 +24,7 @@ then
exit
fi
+# edit clocks file in $EDITOR
if [ "$1" = "-e" ]
then
$EDITOR "$clocks"