diff options
| author | Shohei YOSHIDA <syohex@gmail.com> | 2022-12-23 16:46:30 +0900 |
|---|---|---|
| committer | Shohei YOSHIDA <syohex@gmail.com> | 2022-12-23 16:46:30 +0900 |
| commit | 7aba5946ca28eef92c040ca083ff39e217a8da2b (patch) | |
| tree | 2b40a03a548d2cf114a80169d8cfd14f35b62781 /src/_virtualbox | |
| parent | Merge pull request #963 from zsh-users/add-mediumio (diff) | |
| download | zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.tar zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.tar.gz zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.tar.bz2 zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.tar.lz zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.tar.xz zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.tar.zst zsh-completions-7aba5946ca28eef92c040ca083ff39e217a8da2b.zip | |
Add cloudprofile subcommand completion
Diffstat (limited to 'src/_virtualbox')
| -rw-r--r-- | src/_virtualbox | 40 |
1 files changed, 38 insertions, 2 deletions
diff --git a/src/_virtualbox b/src/_virtualbox index 6d47d47..cac34bb 100644 --- a/src/_virtualbox +++ b/src/_virtualbox @@ -104,7 +104,7 @@ _vboxmanage() { # TODO ;; (cloudprofile) - # TODO + _vboxmanage_cloudprofile && ret=0 ;; (import) _arguments \ @@ -441,7 +441,7 @@ _vboxmanage_encryptvm() { (( $+functions[_vboxmanage_encryptvm_setencryption] )) || _vboxmanage_encryptvm_setencryption() { - _arguments -C \ + _arguments \ '--cipher[specify the new cipher for encryption of the VM]: :(AES-128 AES-256)' \ '--new-password[specify the new password for encryption of the VM]: :_files' \ '--new-password-id[specify the new ID for the password for encryption of the VM]:id' \ @@ -455,6 +455,42 @@ _vboxmanage_encryptvm_addpassword() { '--new-password-id[specify the new ID for the password for encryption of the VM]:id' } +(( $+functions[_vboxmanage_cloudprofile] )) || +_vboxmanage_cloudprofile() { + local ret=1 + + _arguments -C \ + '1: :(add update delete show)' \ + '*:: :->arg' \ + && ret=0 + + case $state in + (arg) + case $words[1] in + (add|update) + _arguments \ + '--provider=[Short cloud provider name]:provider' \ + '--profile=[Cloud profile name]:profile' \ + '--clouduser=[The name which fully identifies the user in the specified cloud provider]:user' \ + '--fingerprint=[Fingerprint for the key pair being used]:finger_print' \ + '--keyfile=[Full path and filename of the private key]: :_files' \ + '--passphrase=[Passphrase used for the key, if it is encrypted]:pass' \ + '--tenancy=[ID of your tenancy]:tenancy' \ + '--compartment=[ID of your compartment]:compartment' \ + '--region=[region name]:region' && ret=0 + ;; + (*) + _arguments \ + '--provider=[Short cloud provider name]:provider' \ + '--profile=[Cloud profile name]:profile' + ;; + esac + ;; + esac + + return $ret +} + (( $+functions[_vboxmanage_bandwidthctl] )) || _vboxmanage_bandwidthctl() { local ret=1 |
