mirror of
https://github.com/junegunn/fzf.git
synced 2025-11-18 08:13:40 -05:00
Changed cask to --cask
60
Examples.md
60
Examples.md
@@ -1030,23 +1030,23 @@ bcp() {
|
||||
```sh
|
||||
# Install or open the webpage for the selected application
|
||||
# using brew cask search as input source
|
||||
# and display a info quickview window for the currently marked application
|
||||
# and display a info quickview window for the currently marked application
|
||||
install() {
|
||||
local token
|
||||
token=$(brew search --casks | fzf-tmux --query="$1" +m --preview 'brew cask info {}')
|
||||
|
||||
if [ "x$token" != "x" ]
|
||||
then
|
||||
token=$(brew search --casks "$1" | fzf-tmux --query="$1" +m --preview 'brew info {}')
|
||||
|
||||
if [ "x$token" != "x" ]
|
||||
then
|
||||
echo "(I)nstall or open the (h)omepage of $token"
|
||||
read input
|
||||
if [ $input = "i" ] || [ $input = "I" ]; then
|
||||
brew cask install $token
|
||||
fi
|
||||
if [ $input = "h" ] || [ $input = "H" ]; then
|
||||
brew cask home $token
|
||||
fi
|
||||
fi
|
||||
}
|
||||
read input
|
||||
if [ $input = "i" ] || [ $input = "I" ]; then
|
||||
brew install --cask $token
|
||||
fi
|
||||
if [ $input = "h" ] || [ $input = "H" ]; then
|
||||
brew home $token
|
||||
fi
|
||||
fi
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
@@ -1054,22 +1054,22 @@ install() {
|
||||
# Uninstall or open the webpage for the selected application
|
||||
# using brew list as input source (all brew cask installed applications)
|
||||
# and display a info quickview window for the currently marked application
|
||||
uninstall() {
|
||||
local token
|
||||
token=$(brew cask list | fzf-tmux --query="$1" +m --preview 'brew cask info {}')
|
||||
|
||||
if [ "x$token" != "x" ]
|
||||
then
|
||||
echo "(U)ninstall or open the (h)omepage of $token"
|
||||
read input
|
||||
if [ $input = "u" ] || [ $input = "U" ]; then
|
||||
brew cask uninstall $token
|
||||
fi
|
||||
if [ $input = "h" ] || [ $token = "h" ]; then
|
||||
brew cask home $token
|
||||
fi
|
||||
fi
|
||||
}
|
||||
uninstall() {
|
||||
local token
|
||||
token=$(brew list --casks | fzf-tmux --query="$1" +m --preview 'brew info {}')
|
||||
|
||||
if [ "x$token" != "x" ]
|
||||
then
|
||||
echo "(U)ninstall or open the (h)omepae of $token"
|
||||
read input
|
||||
if [ $input = "u" ] || [ $input = "U" ]; then
|
||||
brew uninstall --cask $token
|
||||
fi
|
||||
if [ $input = "h" ] || [ $token = "h" ]; then
|
||||
brew home $token
|
||||
fi
|
||||
fi
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user