mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-03-20 03:13:33 +01:00
add fastboot plugin
This commit is contained in:
parent
140034605e
commit
d95248e9cb
2 changed files with 43 additions and 0 deletions
8
plugins/fastboot/README.md
Normal file
8
plugins/fastboot/README.md
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
# fastboot autocomplete plugin
|
||||
|
||||
* Adds autocomplete options for all fastboot commands.
|
||||
|
||||
|
||||
## Requirements
|
||||
|
||||
In order to make this work, you will need to have the Android fastboot tools set up in your path.
|
||||
35
plugins/fastboot/_fastboot
Normal file
35
plugins/fastboot/_fastboot
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
#compdef fastboot
|
||||
#autoload
|
||||
|
||||
# in order to make this work, you will need to have the android fastboot tools
|
||||
|
||||
# fastboot zsh completion, based on homebrew completion
|
||||
|
||||
local -a _1st_arguments
|
||||
_1st_arguments=(
|
||||
'update:reflash device from update.zip'
|
||||
'flashall:flash boot, system, vendor and if found recovery'
|
||||
'flash:<partition> [ <filename> ] write a file to a flash partition'
|
||||
'erase:<partition> erase a flash partition'
|
||||
'format:[:[<fs type>][:[<size>]] <partition> format a flash partition'
|
||||
'getvar:<variable> display a bootloader variable'
|
||||
'boot:<kernel> [ <ramdisk> [ <second> ] ] download and boot kernel'
|
||||
'devices:list all connected devices'
|
||||
'continue:continue with autoboot'
|
||||
'reboot:reboot device normally'
|
||||
'reboot-bootloader:reboot device into bootloader'
|
||||
'help:show this help message'
|
||||
)
|
||||
|
||||
local expl
|
||||
local -a pkgs installed_pkgs
|
||||
|
||||
_arguments \
|
||||
'*:: :->subcmds' && return 0
|
||||
|
||||
if (( CURRENT == 1 )); then
|
||||
_describe -t commands "fastboot subcommand" _1st_arguments
|
||||
return
|
||||
fi
|
||||
|
||||
_files
|
||||
Loading…
Add table
Add a link
Reference in a new issue