DannyBen/completely

View on GitHub
lib/completely/templates/tester-template.erb

Summary

Maintainability
Test Coverage
#!/usr/bin/env bash
if [[ -n $ZSH_VERSION ]]; then
  autoload -U +X bashcompinit && bashcompinit
  autoload -U +X compinit && compinit
fi

# === COMPLETION SCRIPT START ===

<%= script || %Q[source "#{absolute_script_path}"] %>

# === COMPLETION SCRIPT END ===

COMP_WORDS=( <%= compline %> )
COMP_LINE="<%= compline %>"
COMP_POINT=${#COMP_LINE}
COMP_CWORD=<%= cword %>

<%= function_name %>
for suggestion in "${COMPREPLY[@]}"; do
  echo "$suggestion"
done