Files
openfoam/etc/config.csh/tcsh_completion
Mark Olesen 5ca19c2934 ENH: add tcsh completion functionality (issue #551)
- currently no cleanup of completions when deactivating an OpenFOAM
  tcsh environment

- tab completion with directories adds a space after the slash, which
  makes navigation a bit annoying.
2017-08-02 16:54:47 +02:00

18 lines
818 B
Bash

#----------------------------------*-sh-*--------------------------------------
# Tcsh completions for OpenFOAM applications
# Using bash_completion functions for the hard work
if ($?tcsh) then # tcsh only
if ( -f $WM_PROJECT_DIR/etc/config.sh/bash_completion \
&& -f $WM_PROJECT_DIR/etc/config.csh/complete) then
foreach appName (`sed -ne 's/^.*&& complete.* //p' $WM_PROJECT_DIR/etc/config.sh/bash_completion`)
# Pass explicitly
## complete $appName 'p,*,`bash $WM_PROJECT_DIR/etc/config.csh/complete '$appName' "${COMMAND_LINE}"`,'
# Pass via environment
complete $appName 'p,*,`bash $WM_PROJECT_DIR/etc/config.csh/complete '$appName'`,'
end
endif
endif
#------------------------------------------------------------------------------