mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2024-12-25 15:58:57 +01:00
Fix regex for optional http(s), and variable reference inside osascript.
This commit is contained in:
parent
cff228e342
commit
5cd7ad38cb
@ -7,8 +7,8 @@ droplr() {
|
||||
return 1
|
||||
fi
|
||||
|
||||
if [[ "$1" =~ ^http[|s]:// ]]; then
|
||||
osascript -e "tell app 'Droplr' to shorten '$1'"
|
||||
if [[ "$1" =~ ^https?:// ]]; then
|
||||
osascript -e 'tell app "Droplr" to shorten "'"$1"'"'
|
||||
else
|
||||
open -ga /Applications/Droplr.app "$1"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user