I installed the tcsh package on Ubuntu 15.10 and the prompt differs depending on how I invoke tcsh.
First off, on Ubuntu 15.10, tcsh and csh really are the same executable:
$ cmp /bin/tcsh /bin/csh && echo 'same' || echo 'different' same $ /bin/tcsh hostname:/tmp> $ /bin/tcsh -f > Whereas with /bin/csh it ends with a percent sign
$ /bin/csh hostname:/tmp% $ /bin/csh -f % I haven't set a .cshrc or a .tcshrc file. Is tcsh inspecting the first element of argv to determine what to use as the final character of the prompt?
The /etc/csh.cshrc file does contain logic for changing the prompt if the program is invoked as tcsh, but it is not clear why setting the prompt in this way would change the last character from > to %. This file is also ignored if the -f flag is provided.
# /etc/csh.cshrc: system-wide .cshrc file for csh(1) and tcsh(1) if ($?tcsh && $?prompt) then bindkey "\e[1~" beginning-of-line # Home bindkey "\e[7~" beginning-of-line # Home rxvt bindkey "\e[2~" overwrite-mode # Ins bindkey "\e[3~" delete-char # Delete bindkey "\e[4~" end-of-line # End bindkey "\e[8~" end-of-line # End rxvt set autoexpand set autolist set prompt = "%U%m%u:%B%~%b%# " endif