]> gitweb.fluxo.info Git - scripts.git/commitdiff
Feat: show: fixes
authorSilvio Rhatto <rhatto@riseup.net>
Mon, 2 Nov 2020 21:39:13 +0000 (18:39 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Mon, 2 Nov 2020 21:39:13 +0000 (18:39 -0300)
show

diff --git a/show b/show
index a2f717955e9146d1763aefe881f326dc91258777..5dffe02b28c60e3271647c2daf1108efe2632e7c 100755 (executable)
--- a/show
+++ b/show
@@ -13,7 +13,7 @@ MAX_AGE="86400"
 
 # Update the filelist
 function __update_filelist {
-  find $DOCS -not -path '*.git*' > $FILELIST
+  find $DOCS -not -path '*.git*' > $LIST
 }
 
 # Check
@@ -26,7 +26,7 @@ elif [ ! -d "$DOCS" ]; then
 fi
 
 # Check for filelist
-if [ ! -e "$FILELIST" ]; then
+if [ ! -e "$LIST" ]; then
   __update_filelist
   CHANGED="`date +%s`"
 else
@@ -40,4 +40,4 @@ fi
 
 # Dispatch
 #find $DOCS -iname "*$ITEM*" | head -1 | while read entry; do xdg-open "$entry"; done
-grep -- "$ITEM" $LIST | while read entry; do xdg-open "$entry"; done
+cd $DOC && grep -- "$ITEM" $LIST | while read entry; do xdg-open "$entry"; done