Skip to content

Commit

Permalink
init: complete existing files on Tcsh completion
Browse files Browse the repository at this point in the history
Fixes #523
  • Loading branch information
xdelaruelle committed Feb 15, 2024
1 parent c6a72dd commit 9ae9c40
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions NEWS.rst
Expand Up @@ -151,6 +151,8 @@ Modules 5.4.0 (not yet released)
* Add ``--ignore`` option to :mfcmd:`source-sh` modulefile command to define
shell elements changed by shell script that should be ignored. (fix issue
#503)
* Init: Improve Tcsh shell completion script to complete against existing
files when pattern starts with ``/``, ``.`` or ``~/``. (fix issue #523)


.. _5.3 release notes:
Expand Down
3 changes: 2 additions & 1 deletion init/tcsh_completion.in
Expand Up @@ -29,7 +29,8 @@ alias _module_not_yet_loaded '\\

alias _module_modulepath 'echo ${MODULEPATH} | sed '"'"'s/:/\n/g;'"'"' '

complete module 'n/help/`_module_avail`/' \
complete module 'C,/*,f,' 'C,.*,f,' 'C,~/*,f,' \
'n/help/`_module_avail`/' \
'n/add/`_module_not_yet_loaded; echo "@comp_load_opts@"`/' \
'n/load/`_module_not_yet_loaded; echo "@comp_load_opts@"`/' \
'n/add-any/`_module_not_yet_loaded; echo "@comp_load_opts@"`/' \
Expand Down

0 comments on commit 9ae9c40

Please sign in to comment.