#compdef mix #autoload # Elixir mix zsh completion local -a _1st_arguments _1st_arguments=( mix # Run the default task (current: mix run) mix archive # List all archives mix archive.build # Archive this project into a .ez file mix archive.install # Install an archive locally mix archive.uninstall # Uninstall archives mix clean # Delete generated application files mix cmd # Executes the given command mix compile # Compile source files mix compile.protocols # Consolidates all protocols in all paths mix deps # List dependencies and their status mix deps.clean # Remove the given dependencies' files mix deps.compile # Compile dependencies mix deps.get # Get all out of date dependencies mix deps.unlock # Unlock the given dependencies mix deps.update # Update the given dependencies mix do # Executes the tasks separated by comma mix escript.build # Builds an escript for the project mix help # Print help information for tasks mix hex.config # Read or update hex config mix hex.docs # Publish docs for package mix hex.info # Print hex information mix hex.key # Hex API key tasks mix hex.owner # Hex package ownership tasks mix hex.publish # Publish a new package version mix hex.search # Search for package names mix hex.user # Hex user tasks mix loadconfig # Loads and persists the given configuration mix local # List local tasks mix local.hex # Install hex locally mix local.rebar # Install rebar locally mix new # Create a new Elixir project mix run # Run the given file or expression mix test # Run a project's tests iex -S mix # Start IEx and run the default task ) __task_list () { local expl declare -a tasks tasks=(archive clean compile deps deps.clean deps.compile deps.get deps.unlock deps.update do escriptize help local local.install local.rebar local.uninstall new run test) _wanted tasks expl 'help' compadd $tasks } local expl local curcontext="$curcontext" state line typeset -A opt_args _arguments -C \ ':command:->command' \ '*::options:->options' case $state in (command) _describe -t commands "mix subcommand" _1st_arguments return ;; (options) case $line[1] in (help) _arguments ':feature:__task_list' esac ;; esac