Sha256: dc775e5a283c5c220becdcadb0f251772a090a689d7e57b50c3aabeb1d99fdc9

Contents?: true

Size: 632 Bytes

Versions: 1

Compression:

Stored size: 632 Bytes

Contents

_fastlane_complete() {
  COMPREPLY=()
  local word="${COMP_WORDS[COMP_CWORD]}"
  local completions=""

  # look for Fastfile either in this directory or fastlane/ then grab the lane names
  if [[ -e "Fastfile" ]]; then
    file="Fastfile"
  elif [[ -e "fastlane/Fastfile" ]]; then
    file="fastlane/Fastfile"
  elif [[ -e ".fastlane/Fastfile" ]] then
    file=".fastlane/Fastfile"
  fi

  # parse 'beta' out of 'lane :beta do', etc
  completions=`cat $file | grep "^\s*lane \:" | awk -F ':' '{print $2}' | awk -F ' ' '{print $1}'`

  COMPREPLY=( $(compgen -W "$completions" -- "$word") )
}

complete -F _fastlane_complete fastlane

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
fastlane-1.82.0 lib/assets/completions/completion.bash