fix(user:git-bk-find-file):Display commit hash correctly
authorSteven Baltakatei Sandoval <baltakatei@gmail.com>
Tue, 29 Aug 2023 04:55:05 +0000 (04:55 +0000)
committerSteven Baltakatei Sandoval <baltakatei@gmail.com>
Tue, 29 Aug 2023 04:55:05 +0000 (04:55 +0000)
- chore(prvt):Update private submodule

prvt
user/git-bk-find-file

diff --git a/prvt b/prvt
index fd2acc6f5569ae527fed7c60f32fe6c0653c82bb..2847991d9942f664a6a840575be8ad5d26ecc1f2 160000 (submodule)
--- a/prvt
+++ b/prvt
@@ -1 +1 @@
-Subproject commit fd2acc6f5569ae527fed7c60f32fe6c0653c82bb
+Subproject commit 2847991d9942f664a6a840575be8ad5d26ecc1f2
index f4ef58eb64e89f528c55d573009102517ad9a845..b1feb0d10662ef124b58b4f171ceeefebb964564 100755 (executable)
@@ -3,7 +3,7 @@
 # Usage: git-bk-find-file [string grep pattern]
 # Example git-bk-find-file '.txt$'
 # Ref/Attrib: albfan "How can I search Git branches for a file or directory?" https://stackoverflow.com/a/16868704/10850071
-# Version: 0.1.0
+# Version: 0.2.0
 # Depends: GNU bash v5.1.16, GNU parallel 20210822
 
 yell() { echo "$0: $*" >&2; } # print script path and all args to stderr
@@ -34,8 +34,8 @@ display_commit() {
         # Get commit timestamp
         time="$(git -c log.showSignature=false show -s --format=%cI "$commit")";
 
-        # Get last 8 chars of commit
-        short_commit="${commit:(-8)}";
+        # Get first 8 chars of commit
+        short_commit="${commit:0:8}";
 
         # Output results
         while read -r line; do