More advanced o command that opens multiple files
Use a little script for `o` instead of a simple alias to xdg-open. This way multiple files can be opened.
This commit is contained in:
parent
262341bc00
commit
029c467a6f
|
@ -0,0 +1,18 @@
|
|||
#!/bin/bash
|
||||
|
||||
show_help() {
|
||||
echo "Usage: $0 [OPTION] [FILE]..."
|
||||
echo "Open the provided FILEs using xdg-open."
|
||||
echo
|
||||
echo "Options:"
|
||||
echo " -h, --help Display this help menu."
|
||||
exit 0
|
||||
}
|
||||
|
||||
if [ "$1" == "--help" ] || [ "$1" == "-h" ] || [ "$#" -eq 0 ]; then
|
||||
show_help
|
||||
fi
|
||||
|
||||
for var in "$@"; do
|
||||
xdg-open "$var" &
|
||||
done
|
|
@ -162,6 +162,7 @@ then
|
|||
sudo bash -c "$(declare -f linker); linker \"$dotfiles/Scripts/scrotMenu.sh\" '/bin/scrotMenu.sh'"
|
||||
sudo bash -c "$(declare -f linker); linker \"$dotfiles/Scripts/monitorMenu.sh\" '/bin/monitorMenu.sh'"
|
||||
linker "$dotfiles/Scripts/wwan.sh" ~/bin/wwan.sh
|
||||
linker "$dotfiles/Scripts/o" ~/bin/o
|
||||
fi
|
||||
|
||||
## WM
|
||||
|
|
|
@ -19,7 +19,6 @@ alias md='mkdir -p'
|
|||
alias l='ls -lah'
|
||||
alias tree='tree -a'
|
||||
alias c='clear'
|
||||
alias o='xdg-open'
|
||||
alias g='git'
|
||||
alias copy='xclip'
|
||||
alias copyc='xclip -selection clipboard'
|
||||
|
|
Loading…
Reference in New Issue