2
我在bash編程中很糟糕。錯誤在哪裏?這裏是我的.profile文件:。配置文件:第31行:語法錯誤:文件意外結束
# WARNING: For help understanding this file, and before you try
# to change any of it, type "man .profile" and read carefully.
#
#
# Set command search rules
#
if [ -x /bin/showpath ] ; then
export PATH; PATH=`/bin/showpath $HOME/bin /u/cs350/sys161/bin /software/gnu/bin standard`
export PATH; PATH=`/bin/showpath usedby=user standard $HOME/bin`
#
# Find out what kind of terminal we are using
#
eval `setterm sytek:kd404 default:vc404`
#
# Set terminal-type dependent options (e.g. sysline or prompt string)
#
#HOMEHOST="<hostname>"
#HOMEUSER="<userid>"
#export HOMEHOST HOMEUSER
PS1="$ "
#
# Now do the usual signing on things
#
export MAIL; MAIL=${MAIL-"/usr/spool/mail/$USER"}
if [ -r /software/.admin/bins/bin/read_system_news ] ; then /software/.admin/bins/bin/read_system_news ; fi
EOF
奔跑穿過CSH一個bash或sh腳本是保證給你的錯誤。這只是一個巧合,你顯示的錯誤似乎是相關的。 – 2010-10-06 06:50:17
@丹尼斯:只有當你的bash腳本碰巧使用bash特定功能。 – codaddict 2010-10-06 13:13:17
不,csh使用括號'if(condition)' - 不是方括號。 – 2010-10-06 13:46:03