archwiki script improvement
This commit is contained in:
parent
160500ab1d
commit
57f2b1100d
@ -9,7 +9,7 @@ set -e
|
|||||||
DOC_DIR="/usr/share/doc/arch-wiki/html/en/"
|
DOC_DIR="/usr/share/doc/arch-wiki/html/en/"
|
||||||
|
|
||||||
cd "$DOC_DIR"
|
cd "$DOC_DIR"
|
||||||
selected=$(find -type f | cut -c3- | rev | cut -c6- | rev | tr _ ' ' | fzf -q "$1")
|
selected=$(find . -type f | cut -c3- | rev | cut -c6- | rev | tr _ ' ' | fzf -q "$1")
|
||||||
selected_file=$(echo "$selected" | tr ' ' _ | awk -v var="$DOC_DIR" '{print var $0 ".html"}')
|
selected_file=$(echo "$selected" | tr ' ' _ | awk -v var="$DOC_DIR" '{print var $0 ".html"}')
|
||||||
xdg-open "$selected_file"
|
xdg-open "$selected_file"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user