ssh - Cygwin inherits environment variables from Windows sometimes -



ssh - Cygwin inherits environment variables from Windows sometimes -

if set environment variable cvsroot in windows , give value cvsserver:/home/cvs, if then

1) open windows cmd shell , "echo %cvsroot%", "cvsserver:home/cvs"

2) open cygwin bash shell , "echo $cvsroot", "cvsserver:home/cvs"

3) linux, ssh machine , "echo $cvsroot", nothing.

if want ssh session have value cvsroot, need insert .bashrc.

is there can done ssh session inherits environment variable windows?

edit:

4) linux, do

ssh machine "printenv cvsroot"

with environment variable set in .bashrc, nothing. @ interactive prompt, variable value, way gives nothing.

i found nice solution here: http://www.smithii.com/node/44

it looks scheme variable in registry , sets variables in session opened via ssh.

then, phone call little piece of script ssh client (while connecting cygwin server), this: ssh $windowsuser@$windowsbuildserver "source /etc/profile ; echo $cvsroot "

windows ssh cygwin environment-variables

Comments

Popular posts from this blog

iphone - Dismissing a UIAlertView -

intellij idea - Update external libraries with intelij and java -

javascript - send data from a new window to previous window in php -