On 08 Jan 2000, Harry Putnam <[EMAIL PROTECTED]> wrote:

[...]

> I want to use ssh scp rsync.  

Do you want to use scp(1) or rsync(1) to transfer the files? They both
do the same thing in the end (rsync is actually no faster, as I
understand it)

> I don't see any "ssh" on the alist and scp appears as scp scp1 scp2. 
> I'm running ssh-1.2.26 so apparently scp2 is not for me, however do I
> need both scp scp1
> 
> I've chosen scp &  rsync  <== is this correct?

That sounds like the list of supported methods that you have been
editing. That one you don't actually need to touch unless you want to
add a new method...

What you want to set is `rcp-default-method', indicating the preferred
method from that alist to use.

In your case that would be `scp' to use scp(1) for transfers or `rsync'
if you prefer to use rsync to transfer files.


> Reading the comments:
> ;; The out-of-band methods require that you can log in to the remote
> ;; system without having to enter a password.  This is because the
> ;; standard program "rcp" does not query for a password but just fails
> ;; if entering a password is necessary.
> 
> This sounds as if I have wasted my time with rcp.el since every
> machine I want to connect to asks for a password, and apparently scp
> is an out-of-band method.

Yes, it is. When rcp.el connects to a remote machine, it uses ssh(1),
rsh(1) or something like that. You can use uuencode or base64 encoding
and transfer files directly through that connection (`inline' methods)
or you can copy them separately (`out-of-band' methods).

Using scp(1) or rsync(1) to transfer the files is out of band (and often
faster :)

> So assuming I've misread something or else the package would be fairly
> useless to most people.

Nope. If you used the rsh(1)/rcp(1) combination, no password, very
useful. If you want to use ssh(1) only, you should get passworded at
connect time and be able to use the `inline' methods to transfer files.

Personally, the `scp' method suits me. I run the ssh-agent and that has
my identity available to it, allowing me to authenticate to remote
machines without a password.

So, your choices (presuming that you want ssh security) are:
 * Use an `inline' transfer method
 * Use an `out-of-band' transfer method and ssh-agent(1)



> Taking these steps to get started:
> 
> Reading comments:
> 
> ;;
> ;; Usage is also simple: it's just like ange-ftp, but uses a different
> ;; syntax for the remote file names.  The syntax used is as follows:
> ;;
> ;; /r@METHOD:USER@HOST:FILENAME
> 
> This claims to be "just" like ange-ftp but looks considerably
> different to me.

That comment is a tad out of date now. It is similar, sort of, to the
syntax used for efs.el and ange-ftp.el.

I am going to use efs.el from now on (for brevity) but all the comments
about it apply equally to ange-ftp.el. 

> I never have used ange-ftp like that but like below:
> /reader@HOST:/path/file  or
> /ftp@HOST:/path/file
> 
> So what role does the lowercase "r" play ... What goes in METHOD?

That might actually be shown better as:

    /r[@<method>]:[<user>@]<host>:<filename>

The method and user arguments are optional. If you don't specify a
method then the value specified in `rcp-default-method' is used.

If you don't specify a user value then your current login name is
specified. Explicitly, by the way, so if your .ssh/config specifies the
names to use when logging in remotely, they will be ignored.[1]

> Trying the above syntax like:
> 
> /s@scp:reader@<HOST>:/home/reader/.emacs
> 
> Give me no usefull behaviour at all.  Instead I get a silly prompt
> that askes for a password for "s@scp"

Indeed. You have not get the package installed correctly, I fear. This
is the most stunningly nonintuitive feature of the package.

You must make *certain* that you have done `(require 'ange-ftp)'
*before* you load `rcp.el'.

Without that the two packages will fight over who controls the paths and
you will get the behavior that you see.

So, in your .emacs, make sure that you have `(require 'rcp)' /after/
`(require 'ange-ftp)'. Make sure that you *do* have the require for
ange-ftp as well...

> Message buffer shows ange-ftp being loaded instead of rcp:
> 
> Loading ange-ftp...
> Loading ange-ftp...done
> Password for s@scp: 
> 
> Since this is billed as being "simple" apparently I am a dunce.

Well, no. The comment is wrong. Well, not strictly wrong, simply using a
definition of simple that might be used in the context of `Yeah,
climbing that mountain was simple compared to Everest' ;)

> Further first use notes:
> 
> The info file looks as if it is designed to become part of info-dir by
> being catenated into it when the path to rcp texi is given to emacs.

Yup.

[... info path ...]

> That is the correct path, but no info page is available at C-h i m rcp
> <RET>. Is one expected to hand edit "dir" to get this to display? Or
> is it supposed to just happen?

I guess that emacs does not rebuild out-of-date `dir' files by default.
Have a look at the variable `Info-auto-generate-directory' and see what
it is set to.

I suspect that it will be `never'. If so, setting it to something more
useful like `if-outdated' or `always' should improve things.

> Reading now with info reader and `info -f rcp.info'

`C-u C-h i' should prompt you for a path and allow you to point at the
info file even if it's not in the `dir'.

        Daniel


Footnotes: 
[1]  This /is/ an issue with the package, not yet addressed.

-- 
Lispers are among the best grads of the Sweep-It-Under-Someone-Else's-Carpet
School of Simulated Simplicity.  [Was that sufficiently incendiary?  :-)]
        -- Larry Wall in <[EMAIL PROTECTED]>

Reply via email to