diff --git a/prev/any.sh b/prev/any.sh index 62bef44..3710657 100644 --- a/prev/any.sh +++ b/prev/any.sh @@ -1,5 +1,5 @@ if exists exiftool; then - exiftool "$f" || true + exiftool -- "$f" || true else - cat "$f" + cat < "$f" fi diff --git a/prev/cat.sh b/prev/cat.sh index 926d339..f58e669 100644 --- a/prev/cat.sh +++ b/prev/cat.sh @@ -1 +1 @@ -cat "$f" +cat < "$f" diff --git a/prev/jq.sh b/prev/jq.sh index cd63650..dce679c 100644 --- a/prev/jq.sh +++ b/prev/jq.sh @@ -1 +1 @@ -jq -C . "$f" +jq -C . < "$f" diff --git a/prev/ls.sh b/prev/ls.sh index 4681bd1..2ac401d 100644 --- a/prev/ls.sh +++ b/prev/ls.sh @@ -1 +1 @@ -ls --color --group-directories-first "$f" +ls --color --group-directories-first -- "$f" diff --git a/prev/mdcat.sh b/prev/mdcat.sh index 665333d..e86f565 100644 --- a/prev/mdcat.sh +++ b/prev/mdcat.sh @@ -1 +1 @@ -mdcat --columns "$w" "$f" +mdcat --columns "$w" -- "$f" diff --git a/prev/odt.sh b/prev/odt.sh index a7dbe6b..854b203 100644 --- a/prev/odt.sh +++ b/prev/odt.sh @@ -4,11 +4,12 @@ office() { # File produced by libreoffice jpg="$(printf '%s\n' "$f" | sed 's|^.*/||; s|\..*$||')" - libreoffice \ - --headless \ - --convert-to jpg "$f" \ - --outdir "$cache_d" >/dev/null && - mv "$cache_d/$jpg.jpg" "$cache_f" + libreoffice \ + --headless \ + --convert-to jpg \ + --outdir "$cache_d" \ + "$f" >/dev/null && + mv -- "$cache_d/$jpg.jpg" "$cache_f" } convert_and_show_image office diff --git a/prev/source_highlight.sh b/prev/source_highlight.sh index 7dfb8a5..57b0a1e 100644 --- a/prev/source_highlight.sh +++ b/prev/source_highlight.sh @@ -1,3 +1,4 @@ -source-highlight \ - --tab=4 --out-format=esc \ - --style=esc256.style --failsafe -i "$f" +source-highlight \ + --tab=4 --out-format=esc \ + --style=esc256.style --failsafe -i \ + -- "$f"