关于ksh中的。。。我不知道这个是啥。。。(

echo $PWD

实际上打出的是命令evn输出的结果。

env:Parses environment variables stored in configuration files

Example:

LC_MONETARY=en_CA.UTF-8
M2=/usr/local/apache-maven/apache-maven-3.0/bin
TERM=xterm
SHELL=/bin/sh
SSH_CLIENT=172.28.72.21 58689 22
LC_NUMERIC=en_CA.UTF-8
OLDPWD=**
SSH_TTY=/dev/pts/18
USER=**
PATH=.:/usr/local/bin:/opt/CollabNet_Subversion/bin:/usr/local/apache-maven/apache-maven-3.0/bin:/opt/CruiseControl/apache-ant-1.7.0/bin:/usr/local/abinitio-V3-0-2/bin:/usr/bin:/usr/java/bin
MAIL=/var/mail/EME/store
_=/usr/bin/env

instanceHome=`pwd`
echo $instanceHome

这样可以将某命令的输出结果付给一个变量。另一个例子:

instanceHome=`ls -al /ts/home/**

echo $instanceHome

注意``是~下面的那个`

你可能感兴趣的:(user,ssh,Path,variables)