Updated with pod v0.32 commands.

Removed podfile-info command.
Added lib command.
This commit is contained in:
Jozef Izso 2014-05-03 21:15:29 +02:00
commit b77ad0eca4

View file

@ -3,12 +3,12 @@
# ----------------------------------------------------------------------------- # -----------------------------------------------------------------------------
# FILE: _pod # FILE: _pod
# DESCRIPTION: Cocoapods (0.27.1) autocomplete plugin for Oh-My-Zsh # DESCRIPTION: Cocoapods (0.32.1) autocomplete plugin for Oh-My-Zsh
# http://cocoapods.org # http://cocoapods.org
# AUTHOR: Alexandre Joly (alexandre.joly@mekanics.ch) # AUTHOR: Alexandre Joly (alexandre.joly@mekanics.ch)
# GITHUB: https://github.com/mekanics # GITHUB: https://github.com/mekanics
# TWITTER: @jolyAlexandre # TWITTER: @jolyAlexandre
# VERSION: 0.0.3 # VERSION: 0.0.4
# LICENSE: MIT # LICENSE: MIT
# ----------------------------------------------------------------------------- # -----------------------------------------------------------------------------
@ -18,9 +18,9 @@ _1st_arguments=(
'init:Generate a Podfile for the current directory' 'init:Generate a Podfile for the current directory'
'install:Install project dependencies' 'install:Install project dependencies'
'ipc:Inter-process communication' 'ipc:Inter-process communication'
'lib:Develop pods'
'list:List pods' 'list:List pods'
'outdated:Show outdated project dependencies' 'outdated:Show outdated project dependencies'
'podfile-info:Shows information on installed Pods'
'push:Push new specifications to a spec-repo' 'push:Push new specifications to a spec-repo'
'repo:Manage spec-repositories' 'repo:Manage spec-repositories'
'search:Searches for pods' 'search:Searches for pods'
@ -55,6 +55,12 @@ _ipc_arguments=(
'update-search-index:Updates the search index' 'update-search-index:Updates the search index'
) )
local -a _lib_arguments
_lib_arguments=(
'create:Creates a new Pod'
'lint:Validates a Pod'
)
local -a _list_arguments local -a _list_arguments
_list_arguments=( _list_arguments=(
'new:Lists pods introduced in the master spec-repo since the last check' 'new:Lists pods introduced in the master spec-repo since the last check'
@ -64,7 +70,7 @@ local -a _inherited_options
_inherited_options=( _inherited_options=(
'(--silent)--silent[Show nothing]' \ '(--silent)--silent[Show nothing]' \
'(--version)--version[Show the version of CocoaPods]' \ '(--version)--version[Show the version of CocoaPods]' \
'(--no-color)--no-color[Show output without color]' \ '(--no-ansi)--no-ansi[Show output without ANSI codes]' \
'(--verbose)--verbose[Show more debugging information]' \ '(--verbose)--verbose[Show more debugging information]' \
'(--help)--help[Show help banner of specified command]' '(--help)--help[Show help banner of specified command]'
) )
@ -101,13 +107,6 @@ _list_options=(
'(--update)--update[Run `pod repo update` before listing]' '(--update)--update[Run `pod repo update` before listing]'
) )
local -a _podfile_info_options
_podfile_info_options=(
'(--all)--all[Show information about all Pods with dependencies that are used in a project]' \
'(--md)--md[Output information in Markdown format]' \
'*:script or directory:_files'
)
local -a _push_options local -a _push_options
_push_options=( _push_options=(
'(--allow-warnings)--allow-warnings[Allows pushing even if there are warnings]' \ '(--allow-warnings)--allow-warnings[Allows pushing even if there are warnings]' \
@ -154,7 +153,7 @@ __first_command_list ()
local expl local expl
declare -a tasks declare -a tasks
tasks=(install ipc list outdated podfile-info push repo search setup spec update) tasks=(init install ipc lib list outdated push repo search setup spec try update)
_wanted tasks expl 'help' compadd $tasks _wanted tasks expl 'help' compadd $tasks
} }
@ -278,6 +277,28 @@ __pod-ipc() {
esac esac
} }
__pod-lib() {
local curcontext="$curcontext" state line
typeset -A opt_args
_arguments -C \
':command:->command' \
'*::options:->options'
case $state in
(command)
_describe -t commands "pod lib" _lib_arguments
return
;;
(options)
_arguments -C \
$_inherited_options
return
;;
esac
}
__pod-list() { __pod-list() {
local curcontext="$curcontext" state line local curcontext="$curcontext" state line
typeset -A opt_args typeset -A opt_args
@ -344,6 +365,10 @@ case $state in
__pod-ipc __pod-ipc
;; ;;
(lib)
__pod-lib
;;
(list) (list)
__pod-list __pod-list
;; ;;
@ -372,12 +397,6 @@ case $state in
$_search_options $_search_options
;; ;;
(podfile-info)
_arguments \
$_inherited_options \
$_podfile_info_options
;;
(setup) (setup)
_arguments \ _arguments \
$_inherited_options \ $_inherited_options \