summaryrefslogtreecommitdiff
path: root/home/xyz/.local/bin/o
diff options
context:
space:
mode:
authorXiao Pan <gky44px1999@gmail.com>2023-10-25 06:45:08 +0000
committerXiao Pan <gky44px1999@gmail.com>2023-10-25 06:45:08 +0000
commite4db0b25bf6540386e737594a47cb92a83c0cbea (patch)
tree70f85967663aa539fabe40e40803fa638acfae00 /home/xyz/.local/bin/o
parent12bda1ac3390f2d16a401d895faf0ef2418f874c (diff)
update
Diffstat (limited to 'home/xyz/.local/bin/o')
-rwxr-xr-xhome/xyz/.local/bin/o2
1 files changed, 2 insertions, 0 deletions
diff --git a/home/xyz/.local/bin/o b/home/xyz/.local/bin/o
index d70a6d76..8fb066c7 100755
--- a/home/xyz/.local/bin/o
+++ b/home/xyz/.local/bin/o
@@ -13,6 +13,8 @@
# using `>&-` or `2>&-` doesn't completely close mpv's output when run sth. like `o mpv file.mkv`
# base on above observations, I choose to use `>/dev/null 2>&1` instead
+# need ; before } when it is in the same line as { ? https://www.shellcheck.net/wiki/SC1056
+
if [ $# -eq 1 ] && [ -e "$1" ] && { ! [ -x "$1" ] || [ -d "$1" ];}; then
case "$1" in
# libreoffice, please don't let firefox eat your shit