home/git: add tmcommit script
This commit is contained in:
parent
40d5a8af88
commit
b3e782d716
@ -262,6 +262,14 @@ in
|
||||
runtimeInputs = with pkgs; [ cfg.package coreutils ];
|
||||
text = lib.fileContents ./scripts/git-tcommit.sh;
|
||||
})
|
||||
(pkgs.writeShellApplication {
|
||||
name = "git-tmcommit";
|
||||
runtimeInputs = with pkgs; [ cfg.package coreutils ];
|
||||
text = lib.pipe ./scripts/git-tcommit.sh [
|
||||
lib.fileContents
|
||||
(builtins.replaceStrings ["hours" "tcommit"] ["minutes" "tmcommit"])
|
||||
];
|
||||
})
|
||||
(pkgs.writeShellApplication {
|
||||
name = "git-switch-interactive";
|
||||
runtimeInputs = with pkgs; [ cfg.package fzf gnused coreutils ];
|
||||
|
@ -1,5 +1,10 @@
|
||||
set -euo pipefail
|
||||
|
||||
if [[ $# -lt 1 ]]; then
|
||||
echo "Usage: git tcommit [-]<hours>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
HOUR_SHIFT="$1"
|
||||
shift
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user