From 57e3f2b5b2cb3c0730e81d42b5f741a05aedd667 Mon Sep 17 00:00:00 2001 From: Simon 'corecode' Schubert Date: Wed, 30 Sep 2009 15:45:15 +0200 Subject: [PATCH] Import tcsh-6.17.00 --- contrib/tcsh-6/README | 2 +- contrib/tcsh-6/complete.tcsh | 104 +++-- contrib/tcsh-6/config.rpath | 571 ++++++++++++++++++++++++ contrib/tcsh-6/config_f.h | 6 +- contrib/tcsh-6/ed.chared.c | 52 ++- contrib/tcsh-6/ed.decls.h | 4 +- contrib/tcsh-6/ed.h | 7 +- contrib/tcsh-6/ed.inputl.c | 147 ++++--- contrib/tcsh-6/ed.screen.c | 10 +- contrib/tcsh-6/ed.term.h | 4 +- contrib/tcsh-6/ed.xmap.c | 14 +- contrib/tcsh-6/glob.c | 4 +- contrib/tcsh-6/patchlevel.h | 6 +- contrib/tcsh-6/sh.c | 76 ++-- contrib/tcsh-6/sh.char.c | 209 +-------- contrib/tcsh-6/sh.char.h | 46 +- contrib/tcsh-6/sh.decls.h | 5 +- contrib/tcsh-6/sh.dir.c | 16 +- contrib/tcsh-6/sh.dol.c | 148 ++++--- contrib/tcsh-6/sh.err.c | 23 +- contrib/tcsh-6/sh.exec.c | 11 +- contrib/tcsh-6/sh.exp.c | 123 ++++-- contrib/tcsh-6/sh.file.c | 12 +- contrib/tcsh-6/sh.func.c | 208 +++++++-- contrib/tcsh-6/sh.glob.c | 9 +- contrib/tcsh-6/sh.h | 28 +- contrib/tcsh-6/sh.lex.c | 19 +- contrib/tcsh-6/sh.proc.c | 73 ++-- contrib/tcsh-6/sh.proc.h | 6 +- contrib/tcsh-6/sh.sem.c | 25 +- contrib/tcsh-6/sh.set.c | 22 +- contrib/tcsh-6/tc.bind.c | 44 +- contrib/tcsh-6/tc.const.c | 19 +- contrib/tcsh-6/tc.decls.h | 8 +- contrib/tcsh-6/tc.func.c | 24 +- contrib/tcsh-6/tc.os.h | 9 +- contrib/tcsh-6/tc.sig.h | 4 +- contrib/tcsh-6/tc.str.c | 43 +- contrib/tcsh-6/tcsh.man | 41 +- contrib/tcsh-6/tcsh.vcproj | 827 +++++++++++++++++++++++++++++++++++ contrib/tcsh-6/tw.color.c | 5 +- contrib/tcsh-6/tw.comp.c | 6 +- contrib/tcsh-6/tw.parse.c | 6 +- 43 files changed, 2343 insertions(+), 683 deletions(-) create mode 100644 contrib/tcsh-6/config.rpath create mode 100644 contrib/tcsh-6/tcsh.vcproj diff --git a/contrib/tcsh-6/README b/contrib/tcsh-6/README index 9648c27871..ae06b57b2e 100644 --- a/contrib/tcsh-6/README +++ b/contrib/tcsh-6/README @@ -1,4 +1,4 @@ -This is tcsh version 6.15. Tcsh is a version of the Berkeley +This is tcsh version 6.17.00. Tcsh is a version of the Berkeley C-Shell, with the addition of: a command line editor, command and file name completion, listing, etc. and a bunch of small additions to the shell itself. diff --git a/contrib/tcsh-6/complete.tcsh b/contrib/tcsh-6/complete.tcsh index 42edcbd620..4e13bf8833 100644 --- a/contrib/tcsh-6/complete.tcsh +++ b/contrib/tcsh-6/complete.tcsh @@ -1,5 +1,5 @@ # -# $tcsh: complete.tcsh,v 1.47 2006/03/02 18:46:44 christos Exp $ +# $tcsh: complete.tcsh,v 1.51 2007/10/01 21:51:59 christos Exp $ # example file using the new completion code # # Debian GNU/Linux @@ -38,18 +38,18 @@ endif if ($?_complete) then set noglob if ( ! $?hosts ) set hosts - foreach f ($HOME/.hosts /usr/local/etc/csh.hosts $HOME/.rhosts /etc/hosts.equiv) - if ( -r $f ) then - set hosts = ($hosts `grep -v "+" $f | grep -E -v "^#" | tr -s " " " " | cut -f 1`) + foreach f ("$HOME/.hosts" /usr/local/etc/csh.hosts "$HOME/.rhosts" /etc/hosts.equiv) + if ( -r "$f" ) then + set hosts = ($hosts `grep -v "+" "$f" | grep -E -v "^#" | tr -s " " " " | cut -f 1`) endif end - if ( -r $HOME/.netrc ) then - set f=`awk '/machine/ { print $2 }' < $HOME/.netrc` >& /dev/null + if ( -r "$HOME/.netrc" ) then + set f=`awk '/machine/ { print $2 }' < "$HOME/.netrc"` >& /dev/null set hosts=($hosts $f) endif - if ( -r $HOME/.ssh/known_hosts ) then - set f=`cat $HOME/.ssh/known_hosts | cut -f 1 -d \ ` >& /dev/null - set f=`cat $HOME/.ssh/known_hosts | cut -f 1 -d \ | sed -e 's/,/ /g'` >& /dev/null + if ( -r "$HOME/.ssh/known_hosts" ) then + set f=`cat "$HOME/.ssh/known_hosts" | cut -f 1 -d \ ` >& /dev/null + set f=`cat "$HOME/.ssh/known_hosts" | cut -f 1 -d \ | sed -e 's/,/ /g'` >& /dev/null set hosts=($hosts $f) endif unset f @@ -224,7 +224,7 @@ if ($?_complete) then # these should be merged with the MH completion hacks below - jgotts complete {refile,sprev,snext,scan,pick,rmm,inc,folder,show} \ - c@+@F:$HOME/Mail/@ + "c@+@F:$HOME/Mail/@" # these and interrupt handling from Jaap Vermeulen complete {rexec,rxexec,rxterm,rmterm} \ @@ -286,7 +286,7 @@ if ($?_complete) then complete setenv 'p/1/e/' 'c/*:/f/' # these and method of setting hosts from Kimmo Suominen - if ( -f $HOME/.mh_profile && -x "`which folders`" ) then + if ( -f "$HOME/.mh_profile" && -x "`which folders`" ) then if ( ! $?FOLDERS ) setenv FOLDERS "`folders -fast -recurse`" if ( ! $?MHA ) setenv MHA "`ali | sed -e '/^ /d' -e 's/:.*//'`" @@ -505,6 +505,19 @@ if ($?_complete) then logout rdiff release remove rtag status tag unedit \ update watch watchers)/' 'n/-a/(edit unedit commit \ all none)/' 'n/watch/(on off add remove)/' + complete svn 'C@file:///@`'"${HOME}/etc/tcsh/complete.d/svn"'`@@' \ + 'n@ls@(file:/// svn+ssh:// svn://)@@' \ + 'n@help@(add blame cat checkout \ + cleanup commit copy delete export help \ + import info list ls lock log merge mkdir \ + move propdel propedit propget proplist \ + propset resolved revert status switch unlock \ + update)@' 'p@1@(add blame cat checkout \ + cleanup commit copy delete export help \ + import info list ls lock log merge mkdir \ + move propdel propedit propget proplist \ + propset resolved revert status switch unlock \ + update)@' complete cxx 'p/*/f:*.{c++,cxx,c,cc,C,cpp}/' complete detex 'p/*/f:*.tex/' complete edquota 'n/*/u/' @@ -591,14 +604,14 @@ if ($?_complete) then flush-logs flush-status flush-tables flush-privileges \ kill password ping processlist reload refresh \ shutdown status variables version)/' - complete mutt c@-f=@F:${HOME}/Mail/@ \ + complete mutt "c@-f=@F:${HOME}/Mail/@" \ n/-a/f/ \ n/-F/f/ n/-H/f/ \ n/-s/x:''/ \ n/-e/x:''/ \ - n@-b@'`cat ${HOME}/.muttrc-alias | awk '"'"'{print $2 }'"'"\`@ \ - n@-c@'`cat ${HOME}/.muttrc-alias | awk '"'"'{print $2 }'"'"\`@ \ - n@*@'`cat ${HOME}/.muttrc-alias | awk '"'"'{print $2 }'"'"\`@ + n@-b@'`cat "${HOME}/.muttrc-alias" | awk '"'"'{print $2 }'"'"\`@ \ + n@-c@'`cat "${HOME}/.muttrc-alias" | awk '"'"'{print $2 }'"'"\`@ \ + n@*@'`cat "${HOME}/.muttrc-alias" | awk '"'"'{print $2 }'"'"\`@ complete ndc 'n/*/(status dumpdb reload stats trace notrace \ querylog start stop restart )/' if ($?traditional_complete) then @@ -711,14 +724,15 @@ if ($?_complete) then complete unsetenv n/*/e/ set _maildir = /var/mail - if (-r $HOME/.mailrc) then + if (-r "$HOME/.mailrc") then complete mail c/-/"(e i f n s u v)"/ c/*@/\$hosts/ \ - c@+@F:$HOME/Mail@ C@[./\$~]@f@ n/-s/x:''/ \ + "c@+@F:$HOME/Mail@" C@[./\$~]@f@ n/-s/x:''/ \ n@-u@T:$_maildir@ n/-f/f/ \ - n@*@'`sed -n s/alias//p $HOME/.mailrc | tr -s " " " " | cut -f 2`'@ + n@*@'`sed -n s/alias//p "$HOME/.mailrc" | \ + tr -s " " " " | cut -f 2`'@ else complete mail c/-/"(e i f n s u v)"/ c/*@/\$hosts/ \ - c@+@F:$HOME/Mail@ C@[./\$~]@f@ n/-s/x:''/ \ + "c@+@F:$HOME/Mail@" C@[./\$~]@f@ n/-s/x:''/ \ n@-u@T:$_maildir@ n/-f/f/ n/*/u/ endif unset _maildir @@ -1029,23 +1043,41 @@ n@public@'`[ -r /usr/man/manp ]&& \ls -1 /usr/man/manp | sed s%\\.p.\*\$%%`'@ \ N/{-C,--directory}/'`\ls $:-1`'/ \ n/-[0-7]/"(l m h)"/ - # Linux filesystems - complete mount c/-/"(a f F h l n o r s t U v V w)"/ n/-[hV]/n/ \ - n/-o/x:''/ n/-t/x:''/ \ - n/-L/x:'