Re: tramp ($Id: tramp.el,v 1.448 2001/02/18 10:37:36 grossjoh Exp $); End of file during parsing...

2001-03-01 Thread Paul Stevenson

K Grojohann writes:

 On 21 Feb 2001, Kai Grojohann wrote:

  I will have to reformulate the command to do:
  
  while read d; do
  
  done EOF

 I have now tried to do this, can you please test?  New version in
 CVS.  Holler if you want it via FTP.

Works beautifully, thanks.




tramp ($Id: tramp.el,v 1.448 2001/02/18 10:37:36 grossjoh Exp $); End of file during parsing...

2001-02-21 Thread Paul Stevenson


Enter your bug report in this message, including as much detail as you
possibly can about the problem, what you did to cause it and what the
local and remote machines are.

If you can give a simple set of instructions to make this bug happen
reliably, please include those.  Thank you for helping kill bugs in
TRAMP.
--bug report follows this line--

I try to get a file from a remote machine with ssh2.  ssh-agent is
such that I can do this transparently from the command line, but I get
'End of file during parsing'

Here is the debug buffer

# Opening connection for [EMAIL PROTECTED] using scp...
# Waiting 60s for shell or passwd prompt from csep1.phy.ornl.gov
Last login: Mon Feb 19 2001 08:55:27
No mail.

This is a Federal computer system and is the property of the United
States Government. It is for authorized use only. Users (authorized or
unauthorized) have no explicit or implicit expectation of privacy.

Any or all uses of this system and all files on this system may be
intercepted, monitored, recorded, copied, audited, inspected, and
disclosed to authorized site, Department of Energy, and law
enforcement personnel, as well as authorized officials of other
agencies, both domestic and foreign.  By using this system, the user
consents to such interception, monitoring, recording, copying,
auditing, inspection, and disclosure at the discretion of authorized
site or Department of Energy personnel.

Unauthorized or improper use of this system may result in
administrative disciplinary action and civil and criminal
penalties. By continuing to use this system you indicate your
awareness of and consent to these terms and conditions of use. LOG OFF
IMMEDIATELY if you do not agree to the conditions stated in this
warning.
[~] csep1 $ # Initializing remote shell
$ exec /bin/sh
# Waiting 30s for remote `/bin/sh' to come up...
exec /bin/sh
$ # Setting up remote shell environment
stty -echo
$ $ # Determining coding system
foo
bar
$ # Waiting 30s for `unset HISTFILE'
$ # Waiting 30s for `set +o vi +o emacs'
$ # Waiting 30s for `unset MAIL MAILCHECK MAILPATH'
$ $ PS1='
/
'; PS2=''; PS3=''
# Waiting for remote `/bin/sh' to come up...
# Waiting for remote `/bin/sh' to come up...done
$ echo ~root
~root
$ ( echo /bin;echo /usr/bin;echo /usr/sbin;echo /usr/local/bin;echo /usr/ccs/bin;echo 
/local/bin;echo /local/freeware/bin;echo /local/gnu/bin;echo /usr/freeware/bin;echo 
/usr/pkg/bin ) | while read d; do if test -x $d/ksh -a -f $d/ksh; then echo $d/ksh; 
break; fi; done
^D/bin/ksh
# Starting remote shell `^D/bin/ksh' for tilde expansion...
$ PS1='$ ' ; exec ^D/bin/ksh
/bin/sh: ^D^H^H/bin/ksh:  not found
$ /bin/sh: ^D^H^H/bin/ksh:  not found
$ echo hello
# Waiting for remote `^D/bin/ksh' to start up...
hello
# Waiting for remote `^D/bin/ksh' to start up...done
# Finding command to check if file exists
$ ls -d / ; echo tramp_exit_status $?
/
tramp_exit_status 0
$ ls -d /\ this\ file\ does\ not\ exist\  ; echo tramp_exit_status $?
ls: / this file does not exist : No such file or directory
tramp_exit_status 1
# Finding a suitable `ls' command
# Checking remote `/bin/ls' command for `-n' option
$ test -x /bin/ls ; echo tramp_exit_status $?
tramp_exit_status 0
# Testing remote command `/bin/ls' for -n...
$ /bin/ls -lnd / /dev/null 21 ; echo tramp_exit_status $?
tramp_exit_status 0
# Testing remote command `/bin/ls' for -n...okay
# Using remote command `/bin/ls' for getting directory listings
$ tramp_set_exit_status () {
return $1
}
$ ls -d /bin ; echo tramp_exit_status $?
/bin
tramp_exit_status 0
$ ( cd /bin ; echo tramp_exit_status $? )
tramp_exit_status 0
$ ls -d /usr/bin ; echo tramp_exit_status $?
/usr/bin
tramp_exit_status 0
$ ( cd /usr/bin ; echo tramp_exit_status $? )
tramp_exit_status 0
$ ls -d /usr/sbin ; echo tramp_exit_status $?
/usr/sbin
tramp_exit_status 0
$ ( cd /usr/sbin ; echo tramp_exit_status $? )
tramp_exit_status 0
$ ls -d /usr/local/bin ; echo tramp_exit_status $?
/usr/local/bin
tramp_exit_status 0
$ ( cd /usr/local/bin ; echo tramp_exit_status $? )
tramp_exit_status 0
$ ls -d /usr/ccs/bin ; echo tramp_exit_status $?
ls: /usr/ccs/bin: No such file or directory
tramp_exit_status 1
$ ls -d /local/bin ; echo tramp_exit_status $?
ls: /local/bin: No such file or directory
tramp_exit_status 1
$ ls -d /local/freeware/bin ; echo tramp_exit_status $?
ls: /local/freeware/bin: No such file or directory
tramp_exit_status 1
$ ls -d /local/gnu/bin ; echo tramp_exit_status $?
ls: /local/gnu/bin: No such file or directory
tramp_exit_status 1
$ ls -d /usr/freeware/bin ; echo tramp_exit_status $?
ls: /usr/freeware/bin: No such file or directory
tramp_exit_status 1
$ ls -d /usr/pkg/bin ; echo tramp_exit_status $?
/usr/pkg/bin
tramp_exit_status 0
$ ( cd /usr/pkg/bin ; echo tramp_exit_status $? )
tramp_exit_status 0
$ PATH=/bin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/pkg/bin; export PATH
$ LC_TIME=C; export LC_TIME; echo huhu
huhu
$ mesg n; echo huhu
huhu
$ biff n ; echo huhu
ksh: biff:  not found
huhu
$ unalias 

Re: tramp ($Id: tramp.el,v 1.448 2001/02/18 10:37:36 grossjoh Exp $); End of file during parsing...

2001-02-21 Thread Daniel Pittman

On Wed, 21 Feb 2001, Paul Stevenson wrote:

[...]

 I try to get a file from a remote machine with ssh2.  ssh-agent is
 such that I can do this transparently from the command line, but I get
 'End of file during parsing'

[...]

 $ ( echo /bin;echo /usr/bin;echo /usr/sbin;echo /usr/local/bin;echo
 /usr/ccs/bin;echo /local/bin;echo /local/freeware/bin;echo
 /local/gnu/bin;echo /usr/freeware/bin;echo /usr/pkg/bin ) | while read
 d; do if test -x $d/ksh -a -f $d/ksh; then echo $d/ksh; break; fi; done

TRAMP looks for a suitable remote shell.

 ^D/bin/ksh # Starting remote shell `^D/bin/ksh' for tilde

The remote system spits out some *very* odd characters. The '^D^H^H'
don't belong there.

This confuses TRAMP, which breaks in horrible ways as it tries to cope.

If you find out where those characters come from, things should improve.
I think.

Daniel

-- 
Advertising may be described as the science of arresting the human
intelligence long enough to get money from it.
-- Stephen Leacock




Re: tramp ($Id: tramp.el,v 1.448 2001/02/18 10:37:36 grossjoh Exp $); End of file during parsing...

2001-02-21 Thread Paul Stevenson

K Grojohann writes:

 On 21 Feb 2001, Paul Stevenson wrote:
 
  If I interactively type 'sh' and then paste the above long command,
  it truncates at about 190 characters.  Can this be relevant?
 
 Yes.  Shit.
 
 I will have to reformulate the command to do:
 
 while read d; do
 
 done EOF
 
 Then I send the directory names to the remote end, one dir per line,
 then I send EOF.
 
 Argh.
 
 Can you do this yourself?  I might not have time for a while now.
 
 kai

I'll give it a go.