unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Loading local .emacs from remote machine
@ 2003-02-03 17:56 gebser
  0 siblings, 0 replies; 24+ messages in thread
From: gebser @ 2003-02-03 17:56 UTC (permalink / raw)



Yep, this is a weird question and normally I'd say it's not possible to 
do, but emacs already does so much stuff which would be inconceivable 
for a normal app that I have to ask:

I'm using X via ssh to open emacs on a remote machine but which pops
open a frame on my local box.  This is extremely cool, but how can I
have it load my local ".emacs" file when it does?


tia,
ken

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
       [not found] <mailman.1346.1044295047.21513.help-gnu-emacs@gnu.org>
@ 2003-02-03 23:45 ` Kevin Rodgers
  2003-02-04  1:08   ` gebser
  2003-02-04  6:39 ` Kai Großjohann
  1 sibling, 1 reply; 24+ messages in thread
From: Kevin Rodgers @ 2003-02-03 23:45 UTC (permalink / raw)


gebser@ameritech.net wrote:

> I'm using X via ssh to open emacs on a remote machine but which pops
> open a frame on my local box.  This is extremely cool, but how can I
> have it load my local ".emacs" file when it does?

Why not use NFS to share your home directory on both machines?


-- 
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;">Kevin Rodgers</a>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-03 23:45 ` Loading local .emacs from remote machine Kevin Rodgers
@ 2003-02-04  1:08   ` gebser
  2003-02-05 16:33     ` bigfaceworm
  0 siblings, 1 reply; 24+ messages in thread
From: gebser @ 2003-02-04  1:08 UTC (permalink / raw)
  Cc: help-gnu-emacs


Kevin,

That's an idea, good for a lot of situations.  This is a client's
machine though and so in this instance it would be a little too
intrusive-- he doesn't have NFS running on his box and I wouldn't feel
comfortable starting it up and running it there.  

My first thought was simply to edit my own (local) ".emacs" and putting
it on his machine (as, say, .emacs-ken, then doing "emacs -t
.emacs-ken").  I was looking for something even simpler and more
discrete than that.  (Sheesh, I'm a lazy SOB.)


Thanks for the suggestion,
ken

Kevin Rodgers at 16:45 (UTC-0700) on Mon, 3 Feb 2003 said:

= gebser@ameritech.net wrote:
= 
= > I'm using X via ssh to open emacs on a remote machine but which pops
= > open a frame on my local box.  This is extremely cool, but how can I
= > have it load my local ".emacs" file when it does?
= 
= Why not use NFS to share your home directory on both machines?
= 
= 
= 

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
       [not found] <mailman.1346.1044295047.21513.help-gnu-emacs@gnu.org>
  2003-02-03 23:45 ` Loading local .emacs from remote machine Kevin Rodgers
@ 2003-02-04  6:39 ` Kai Großjohann
  2003-02-04 16:35   ` gebser
  2003-02-06  7:44   ` Mac
  1 sibling, 2 replies; 24+ messages in thread
From: Kai Großjohann @ 2003-02-04  6:39 UTC (permalink / raw)


gebser@ameritech.net writes:

> I'm using X via ssh to open emacs on a remote machine but which pops
> open a frame on my local box.  This is extremely cool, but how can I
> have it load my local ".emacs" file when it does?

Try M-x load-file RET /user@host:/path/to/.emacs RET.  This logs into
host via ftp.  Then there is Tramp which allows you to use ssh
instead of ftp.  (Warning: I started Tramp.)

I think what I would do is to set up a CVS repository and put my dot
files in there, then write a Makefile that sets up symlinks from
$HOME to the locations in the CVS repository.  (That's actually what
I did.)  Then it becomes easy to access your dot files from anywhere,
and also the modifications will propagate if you check in on your
main machine and regularly update on the clients (or client's).
-- 
A turnip curses Elvis

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-04  6:39 ` Kai Großjohann
@ 2003-02-04 16:35   ` gebser
  2003-02-04 17:30     ` Kai Großjohann
  2003-02-06  7:44   ` Mac
  1 sibling, 1 reply; 24+ messages in thread
From: gebser @ 2003-02-04 16:35 UTC (permalink / raw)
  Cc: help-gnu-emacs


I've heard about tramp and would like to try it.  I'm using emacs
v.20.7.1 and "C-h a tramp" says no matches for 'tramp'.  I searched
Redhat's site for an RPM and find none. (I've done a few tgz installs in
the past.  These of course don't get registered in the rpm database and
this sometimes comes back to bite me.)  But what the heck.  I download
the 2002-02-17 (most recent stable) version from sourceforge and examine
it for install instructions.  None there, though there's makefiles.  
They're not particularly revelatory to me, so I do another search and
find <http://www.nongnu.org/tramp/>.

There I find and get tramp-2.0.28.tar.gz (dated 23-Dec-2002), untar it
into /usr/share/emacs/site-lisp, creating the files in a subdir of
site-lisp called tramp-2.0.28.  Then I go to
/usr/share/emacs/site-lisp/tramp-2.0.28/ and run "make EMACS=emacs all"
to create the *.elc files.  From this I get some error messages at the 
end like:

==============================================================
...
test -d ../info || mkdir ../info
makeinfo --footnote-style=end --no-split -o ../info/tramp tramp.texi
tramp.texi:66: Unknown command `copying'.
tramp.texi:88: Unmatched `@end'.
tramp.texi:143: Unknown command `insertcopying'.
makeinfo: Removing output file `../info/tramp' due to errors; use 
--force to preserve.
make[1]: *** [tramp] Error 2
make[1]: Leaving directory 
`/usr/share/emacs/site-lisp/tramp-2.0.28/texi'
make: *** [all] Error 2
==============================================================

When I open the directory 
"/usr/share/emacs/site-lisp/tramp-2.0.28/texi", put the cursor on 
tramp.texi, and press "L", I get "Failed to load 1 of 1 file-- type ? 
for details ((tramp.texi)).  

Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]".

But moving along...

I add:

(add-to-list 'load-path "/usr/share/emacs/site-lisp/tramp/lisp/")
(require 'tramp)

to my .emacs, create a symlink from tramp-2.0.28 to tramp, and do "C-x 
C-e" at the ends of the above two lines.  Fine.

Then I skip the next part about using the install-info command to add
the directory to the search path for Info (since the info file wasn't
created).  And that's about all there is to the install section of 
<http://www.nongnu.org/tramp/>.  

Then I skip the configuration section and just down to "Using tramp"  
just to test it out.  Doing "C-x C-f Return /userid@1.2.3.4:/etc/foo"  
prompts me for the password (which I successfully enter), but then hangs
for minutes (seemingly permanently) with "tramp: 'Setting shell prompt"  
in the minibuffer.  Hmmm....

I've ssh'd and scp'd to and from this site before many times, so that's 
not the deal.  The prompt on the remote system is of the form 
"userid@hostname:/path/to/file # " and maybe this has tramp baffled.  
Doing C-g finally gets me control of emacs again.

So then to help tramp recognize the shell prompt, I add this to-- and
try a few variations of it in-- ".emacs":

(add-to-list 'tramp-shell-prompt-pattern 
'("[-,0-9,A-Z,a-z]+\@[-,0-9,A-Z,a-z]+\:[-,0-9,A-Z,a-z,/]+\ \[#$]\ "))

(all on one line).  None have worked; trying to load it I get "Wrong
type argument: listp ..."

I have to say, Kai, I loved using your ange-ftp, and eventually hope to 
use tramp some day.  Maybe today isn't the day.


But, thanks,
ken


Kai Großjohann at 07:39 (UTC+0100) on Tue, 4 Feb 2003 said:

= gebser@ameritech.net writes:
= 
= > I'm using X via ssh to open emacs on a remote machine but which pops
= > open a frame on my local box.  This is extremely cool, but how can I
= > have it load my local ".emacs" file when it does?
= 
= Try M-x load-file RET /user@host:/path/to/.emacs RET.  This logs into
= host via ftp.  Then there is Tramp which allows you to use ssh
= instead of ftp.  (Warning: I started Tramp.)
= 
= I think what I would do is to set up a CVS repository and put my dot
= files in there, then write a Makefile that sets up symlinks from
= $HOME to the locations in the CVS repository.  (That's actually what
= I did.)  Then it becomes easy to access your dot files from anywhere,
= and also the modifications will propagate if you check in on your
= main machine and regularly update on the clients (or client's).
= 

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-04 16:35   ` gebser
@ 2003-02-04 17:30     ` Kai Großjohann
  2003-02-04 21:51       ` gebser
  0 siblings, 1 reply; 24+ messages in thread
From: Kai Großjohann @ 2003-02-04 17:30 UTC (permalink / raw)
  Cc: help-gnu-emacs

gebser@ameritech.net writes:

> There I find and get tramp-2.0.28.tar.gz (dated 23-Dec-2002), untar it
> into /usr/share/emacs/site-lisp, creating the files in a subdir of
> site-lisp called tramp-2.0.28.  Then I go to
> /usr/share/emacs/site-lisp/tramp-2.0.28/ and run "make EMACS=emacs all"
> to create the *.elc files.  From this I get some error messages at the 
> end like:
>
> ==============================================================
> ...
> test -d ../info || mkdir ../info
> makeinfo --footnote-style=end --no-split -o ../info/tramp tramp.texi
> tramp.texi:66: Unknown command `copying'.
> tramp.texi:88: Unmatched `@end'.
> tramp.texi:143: Unknown command `insertcopying'.
> makeinfo: Removing output file `../info/tramp' due to errors; use 
> --force to preserve.
> make[1]: *** [tramp] Error 2
> make[1]: Leaving directory 
> `/usr/share/emacs/site-lisp/tramp-2.0.28/texi'
> make: *** [all] Error 2
> ==============================================================

Tramp requires Texinfo 4.2 to build the info files, 4.1 is too old.
The new command `copying' makes sure that the copying information
comes out in all formats of the document (previous Texinfo documents
missed the copying information in the HTML format).

I didn't try to fix it because it was a somewhat political decision
to use the new Texinfo version.  (Maybe I would have refrained from
the command had I known what it entails...  Maybe I should make some
backward compatibility hack.)

> When I open the directory 
> "/usr/share/emacs/site-lisp/tramp-2.0.28/texi", put the cursor on 
> tramp.texi, and press "L", I get "Failed to load 1 of 1 file-- type ? 
> for details ((tramp.texi)).  

`L' is for Lisp files (*.el), not Texinfo files (*.texi).

> Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]".

I think it's M-x texinfo-format-buffer RET...

> But moving along...

Wow, very persevering.

> I add:
>
> (add-to-list 'load-path "/usr/share/emacs/site-lisp/tramp/lisp/")
> (require 'tramp)
>
> to my .emacs, create a symlink from tramp-2.0.28 to tramp, and do "C-x 
> C-e" at the ends of the above two lines.  Fine.

Yes, that's the right thing to do.

It would be nice to have proper build scripts, but given that Tramp is
included in both Emacs and XEmacs, my motivation for making proper
build scripts was so-so.  And also, it's enough to frob load-path,
basically.

> Then I skip the next part about using the install-info command to add
> the directory to the search path for Info (since the info file wasn't
> created).  And that's about all there is to the install section of 
> <http://www.nongnu.org/tramp/>.  
>
> Then I skip the configuration section and just down to "Using tramp"  
> just to test it out.  Doing "C-x C-f Return /userid@1.2.3.4:/etc/foo"  
> prompts me for the password (which I successfully enter), but then hangs
> for minutes (seemingly permanently) with "tramp: 'Setting shell prompt"  
> in the minibuffer.  Hmmm....
>
> I've ssh'd and scp'd to and from this site before many times, so that's 
> not the deal.  The prompt on the remote system is of the form 
> "userid@hostname:/path/to/file # " and maybe this has tramp baffled.  
> Doing C-g finally gets me control of emacs again.

Yes, I also guess that the shell prompt wasn't recognized.  Lessee
now, what is the default value of tramp-shell-prompt-pattern?  Hm.
It should have matched this prompt.

So I'm somewhat confused.

Could you put (setq tramp-verbose 10) and (setq tramp-debug-buffer t)
in ~/.emacs and try again and show me the *tramp/foo* buffer in
addition to the *debug tramp/foo* buffer?

Also, it would be good to do M-x toggle-debug-on-quit RET before
trying, then C-g will give you a backtrace.  Please send it, too.

Oh, and removing tramp.elc before starting Emacs will give a prettier
backtrace.

> So then to help tramp recognize the shell prompt, I add this to-- and
> try a few variations of it in-- ".emacs":
>
> (add-to-list 'tramp-shell-prompt-pattern 
> '("[-,0-9,A-Z,a-z]+\@[-,0-9,A-Z,a-z]+\:[-,0-9,A-Z,a-z,/]+\ \[#$]\ "))
>
> (all on one line).  None have worked; trying to load it I get "Wrong
> type argument: listp ..."

The regexp syntax is weird.  For instance, [a-z,A-Z] matches
lowercase letters and uppercase letters and the comma...

But the main problem is that tramp-shell-prompt-pattern is not
supposed to be a list.  It's supposed to be a string.

> I have to say, Kai, I loved using your ange-ftp, and eventually hope to 
> use tramp some day.  Maybe today isn't the day.

I didn't write Ange-FTP, that was done by Ange (Andy Norman, I
believe) initially.  Afterwords, others have made changes, of course,
but I wasn't among them as I recall.

So much trouble you had, I'm sorry for this.
-- 
A turnip curses Elvis

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-04 17:30     ` Kai Großjohann
@ 2003-02-04 21:51       ` gebser
  0 siblings, 0 replies; 24+ messages in thread
From: gebser @ 2003-02-04 21:51 UTC (permalink / raw)
  Cc: gebser


Kai,

Thanks for the feedback.

I looked around and it seems I'd have to upgrade to RH 8.0 to be able to use
texinfo 4.2; it would require upgrading some other more central system files.
I'd like to have the info files, but today isn't the day for me to do a full
upgrade.  But maybe we can still get tramp working.  (See below.)

Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:

= gebser@ameritech.net writes:
= 
= >...
= > ...
= 
= Tramp requires Texinfo 4.2 to build the info files, 4.1 is too old.
= The new command `copying' makes sure that the copying information
= comes out in all formats of the document (previous Texinfo documents
= missed the copying information in the HTML format).
= 
= I didn't try to fix it because it was a somewhat political decision
= to use the new Texinfo version.  (Maybe I would have refrained from
= the command had I known what it entails...  Maybe I should make some
= backward compatibility hack.)

This would help out those of us who don't upgrade with each new version 
that comes out.  I know a lot of people still on rh 7.2.

= 
= > When I open the directory 
= > "/usr/share/emacs/site-lisp/tramp-2.0.28/texi", put the cursor on 
= > tramp.texi, and press "L", I get "Failed to load 1 of 1 file-- type ? 
= > for details ((tramp.texi)).  
= 
= `L' is for Lisp files (*.el), not Texinfo files (*.texi).

I was following the documentation.  What would be the way to load a 
*.texi file?

= 
= > Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]".
= 
= I think it's M-x texinfo-format-buffer RET...

Again, the command I used was directly from the docs.


= 
= > But moving along...
= 
= Wow, very persevering.

People say that....  Well, they don't give me a "Wow", but yeah.  :)


= ...
= 
= It would be nice to have proper build scripts, but given that Tramp is
= included in both Emacs and XEmacs, my motivation for making proper
= build scripts was so-so.  And also, it's enough to frob load-path,
= basically.
= 
= > Then I skip the next part about using the install-info command to add
= > the directory to the search path for Info (since the info file wasn't
= > created).  And that's about all there is to the install section of 
= > <http://www.nongnu.org/tramp/>.  

This is where I was reading the aforementioned docs. 


= >
= > Then I skip the configuration section and just down to "Using tramp"  
= > just to test it out.  Doing "C-x C-f Return /userid@1.2.3.4:/etc/foo"  
= > prompts me for the password (which I successfully enter), but then hangs
= > for minutes (seemingly permanently) with "tramp: 'Setting shell prompt"  
= > in the minibuffer.  Hmmm....
= >
= > I've ssh'd and scp'd to and from this site before many times, so that's 
= > not the deal.  The prompt on the remote system is of the form 
= > "userid@hostname:/path/to/file # " and maybe this has tramp baffled.  
= > Doing C-g finally gets me control of emacs again.
= 
= Yes, I also guess that the shell prompt wasn't recognized.  Lessee
= now, what is the default value of tramp-shell-prompt-pattern?  Hm.
= It should have matched this prompt.
= 
= So I'm somewhat confused.

I don't know enough about this even to be confused....  8\


= 
= Could you put (setq tramp-verbose 10) and (setq tramp-debug-buffer t)
= in ~/.emacs and try again and show me the *tramp/foo* buffer in
= addition to the *debug tramp/foo* buffer?
= 
= Also, it would be good to do M-x toggle-debug-on-quit RET before
= trying, then C-g will give you a backtrace.  Please send it, too.
= 
= Oh, and removing tramp.elc before starting Emacs will give a prettier
= backtrace.

Did all this.  Then tried to open a file on the same machine as before.

The output of *Backtrace*:

===============================================================
Signaling: (quit)
  accept-process-output(#<process *tramp/nil ken@fencefarm*> 1)
  tramp-wait-for-output()
  tramp-open-connection-setup-interactive-shell(#<process *tramp/nil 
ken@fencefarm*> nil nil "ken" "fencefarm")
  tramp-open-connection-rsh(nil nil "ken" "fencefarm")
  tramp-maybe-open-connection(nil nil "ken" "fencefarm")
  tramp-send-command(nil nil "ken" "fencefarm" "( test -d /etc/hosts 
2>/dev/null; echo tramp_exit_status $? )")
  tramp-send-command-and-check(nil nil "ken" "fencefarm" "test -d 
/etc/hosts" t)
  tramp-handle-file-directory-p("/ken@fencefarm:/etc/hosts")
  apply(tramp-handle-file-directory-p "/ken@fencefarm:/etc/hosts")
  tramp-file-name-handler(file-directory-p "/ken@fencefarm:/etc/hosts")
  file-directory-p("/ken@fencefarm:/etc/hosts")
  find-file-noselect("/ken@fencefarm:/etc/hosts" nil nil 1)
  find-file("/ken@fencefarm:/etc/hosts" 1)
* call-interactively(find-file)
============================================================


Here's *tramp/nil ken@fencefarm*:

============================================================

> > 
///»¢ò ;Öv­ 	éüž­
Read from remote host fencefarm: Connection reset by peer
Connection to fencefarm closed.

Process *tramp/nil root@fencefarm* exited abnormally with code 255

============================================================


And here's *debug tramp/nil ken@fencefarm*

============================================================

# Opening connection for ken@fencefarm using nil...
# Waiting for prompts from remote shell
# Waiting 60s for prompt from remote shell
# Looking for regexp "^.*\([pP]assword\|passphrase.*\):
# Looking for regexp ".*ogin: *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell
# Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell
# Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell
# Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell
# Looking for regexp "^.*\([pP]assword\|passphrase.*\):
# Sending password
# Looking for regexp ".*ogin: *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell
# Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell
# Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell
# Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell
# Looking for regexp "^.*\([pP]assword\|passphrase.*\):
# Looking for regexp ".*ogin: *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell
# Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell
# Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell
# Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell
# Looking for regexp "^.*\([pP]assword\|passphrase.*\):
# Looking for regexp ".*ogin: *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Looking for regexp "^.*\(Connection \(closed\|refused\)\|Host key verification failed\.\|Login \(Incorrect\|incorrect\)\|Name or service not known\|Permission denied\.\|Sorry, try again\.\).*\|^.*\(Received signal [0-9]+\).*" from remote shell
# Looking for regexp "\(Are you sure you want to continue connecting (yes/no)\?\)\s-*" from remote shell
# Looking for regexp "\(Store key in cache\? (y/n)\)\s-*" from remote shell
# Looking for regexp "\(TERM = (.*)\|Terminal type\? \[.*\]\)\s-*" from remote shell
# Looking for regexp "^.*\([pP]assword\|passphrase.*\):
# Looking for regexp ".*ogin: *" from remote shell
# Looking for regexp "^[^#$%>
]*[#$%>] *" from remote shell
# Found remote shell prompt.
# Initializing remote shell
$ exec env PS1='$ ' /bin/sh
# Waiting 30s for remote `/bin/sh' to come up...
exec env 'PS1=$ ' /bin/sh
$ # Setting up remote shell environment
stty -inlcr -echo kill '^U'
$ $ # Determining coding system
foo
bar
$ # Waiting 30s for `HISTFILE=$HOME/.tramp_history; HISTSIZE=1'
$ # Waiting 30s for `set +o vi +o emacs'
$ # Waiting 30s for `unset MAIL MAILCHECK MAILPATH'
$ # Waiting 30s for `unset CDPATH'
$ # Setting shell prompt
$ PS1='
///»¢ò ;Y\x02Öv­ 	éüž­
'; PS2=''; PS3=''
 
============================================================

Here's what as ssh login from the command prompt looks like:

================================================================
$ ssh ken@fencefarm
ken@fencefarm's password: 
Last login: Tue Feb  4 16:20:15 2003 from adsl-65-43-213-[...]
================================================================


= > ...
= > '("[-,0-9,A-Z,a-z]+\@[-,0-9,A-Z,a-z]+\:[-,0-9,A-Z,a-z,/]+\ \[#$]\ "))
= >
= > (all on one line).  None have worked; trying to load it I get "Wrong
= > type argument: listp ..."
= 
= The regexp syntax is weird.  For instance, [a-z,A-Z] matches
= lowercase letters and uppercase letters and the comma...
= 
= But the main problem is that tramp-shell-prompt-pattern is not
= supposed to be a list.  It's supposed to be a string.

A string in elisp must be some really strange thing.

(add-to-list 'tramp-shell-prompt-pattern "abc")

also gives the same error.  It seems that everything and anything I put into
the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
it so's to do some helpful work on emacs.  Several times I've tried to do
simple things in elisp, following books and tutorials, but never had any
progress with it.  Maybe I need to be dyslexic.  :)

= 
= ...


Thanks again for the assistance.
ken

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
       [not found] <mailman.1406.1044395706.21513.help-gnu-emacs@gnu.org>
@ 2003-02-04 23:30 ` Kevin Rodgers
  2003-02-05  0:38   ` gebser
  2003-02-05 12:51 ` Kai Großjohann
  1 sibling, 1 reply; 24+ messages in thread
From: Kevin Rodgers @ 2003-02-04 23:30 UTC (permalink / raw)


gebser@ameritech.net wrote:

> Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
> = But the main problem is that tramp-shell-prompt-pattern is not
> = supposed to be a list.  It's supposed to be a string.
> 
> A string in elisp must be some really strange thing.
> 
> (add-to-list 'tramp-shell-prompt-pattern "abc")
> 
> also gives the same error.  It seems that everything and anything I put into
> the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
> it so's to do some helpful work on emacs.  Several times I've tried to do
> simple things in elisp, following books and tutorials, but never had any
> progress with it.  Maybe I need to be dyslexic.  :)

Emacs Lisp is not Tcl, and a string is not a list.

(setq tramp-shell-prompt-pattern
      (concat tramp-shell-prompt-pattern "\\|abc"))


-- 
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;">Kevin Rodgers</a>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-04 23:30 ` Kevin Rodgers
@ 2003-02-05  0:38   ` gebser
  2003-02-05  0:50     ` David Kastrup
  2003-02-05 12:37     ` gebser
  0 siblings, 2 replies; 24+ messages in thread
From: gebser @ 2003-02-05  0:38 UTC (permalink / raw)


Kevin Rodgers at 16:30 (UTC-0700) on Tue, 4 Feb 2003 said:

= gebser@ameritech.net wrote:
= 
= > Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
= > = But the main problem is that tramp-shell-prompt-pattern is not
= > = supposed to be a list.  It's supposed to be a string.
= > 
= > A string in elisp must be some really strange thing.
= > 
= > (add-to-list 'tramp-shell-prompt-pattern "abc")
= > 
= > also gives the same error.  It seems that everything and anything I put into
= > the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
= > it so's to do some helpful work on emacs.  Several times I've tried to do
= > simple things in elisp, following books and tutorials, but never had any
= > progress with it.  Maybe I need to be dyslexic.  :)
= 
= Emacs Lisp is not Tcl, and a string is not a list.

No argument here.  I'd even add that Emacs lisp isn't C, C++, java,
pascal, html, sh, bash, or perl.  But all these and many others have
pretty much the same syntax for a string.  You can go pretty far in any
of those-- at least assign a value to a variable-- just by knowing that
a string is zero or more characters enclosed in double quotes.

Anyone have a similarly easy recipe for a string is in elisp?

= 
= (setq tramp-shell-prompt-pattern
=       (concat tramp-shell-prompt-pattern "\\|abc"))
= 
= 
= 

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05  0:38   ` gebser
@ 2003-02-05  0:50     ` David Kastrup
  2003-02-05 12:45       ` gebser
  2003-02-05 12:37     ` gebser
  1 sibling, 1 reply; 24+ messages in thread
From: David Kastrup @ 2003-02-05  0:50 UTC (permalink / raw)


gebser@ameritech.net writes:

> Kevin Rodgers at 16:30 (UTC-0700) on Tue, 4 Feb 2003 said:
> 
> = gebser@ameritech.net wrote:
> = 
> = > Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
> = > = But the main problem is that tramp-shell-prompt-pattern is not
> = > = supposed to be a list.  It's supposed to be a string.
> = > 
> = > A string in elisp must be some really strange thing.
> = > 
> = > (add-to-list 'tramp-shell-prompt-pattern "abc")
> = > 
> = > also gives the same error.  It seems that everything and anything I put into
> = > the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
> = > it so's to do some helpful work on emacs.  Several times I've tried to do
> = > simple things in elisp, following books and tutorials, but never had any
> = > progress with it.  Maybe I need to be dyslexic.  :)
> = 
> = Emacs Lisp is not Tcl, and a string is not a list.
> 
> No argument here.  I'd even add that Emacs lisp isn't C, C++, java,
> pascal, html, sh, bash, or perl.  But all these and many others have
> pretty much the same syntax for a string.  You can go pretty far in any
> of those-- at least assign a value to a variable-- just by knowing that
> a string is zero or more characters enclosed in double quotes.
> 
> Anyone have a similarly easy recipe for a string is in elisp?

Pretty much the same.  Which is why you should not be using
add-to-list on a string.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05  0:38   ` gebser
  2003-02-05  0:50     ` David Kastrup
@ 2003-02-05 12:37     ` gebser
  1 sibling, 0 replies; 24+ messages in thread
From: gebser @ 2003-02-05 12:37 UTC (permalink / raw)


gebser@Ameritech.Net at 19:38 (UTC-0500) on Tue, 4 Feb 2003 said:

= Kevin Rodgers at 16:30 (UTC-0700) on Tue, 4 Feb 2003 said:
= 
= = gebser@ameritech.net wrote:
= = 
= = > Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
= = > = But the main problem is that tramp-shell-prompt-pattern is not
= = > = supposed to be a list.  It's supposed to be a string.
= = > 
= = > A string in elisp must be some really strange thing.
= = > 
= = > (add-to-list 'tramp-shell-prompt-pattern "abc")
= = > 
= = > also gives the same error.  It seems that everything and anything I put into
= = > the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
= = > it so's to do some helpful work on emacs.  Several times I've tried to do
= = > simple things in elisp, following books and tutorials, but never had any
= = > progress with it.  Maybe I need to be dyslexic.  :)
= = 
= = Emacs Lisp is not Tcl, and a string is not a list.
= 
= No argument here.  I'd even add that Emacs lisp isn't C, C++, java,
= pascal, html, sh, bash, or perl.  But all these and many others have
= pretty much the same syntax for a string.  You can go pretty far in any
= of those-- at least assign a value to a variable-- just by knowing that
= a string is zero or more characters enclosed in double quotes.
= 
= Anyone have a similarly easy recipe for a string is in elisp?
= 
= = 
= = (setq tramp-shell-prompt-pattern
= =       (concat tramp-shell-prompt-pattern "\\|abc"))
= = 

Kevin,

Thanks for the suggestion.  I see you are using "concat" to concatenate
to the given regexp and this works fine.  Thanks.

I'm seeing that what you really intended to say was that we should 
eschew

(add-to-list 'tramp-shell-prompt-pattern .....)

for

(setq tramp-shell-prompt-pattern
      (concat tramp-shell-prompt-pattern "\\|REGEXP")

and that our Wendung to an ontology of the string would be pertinent 
elsewhere.

Perhaps some of these conclusions could be added to the documentation on
tramp to assist others coming later.


Thanks again.
ken

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05  0:50     ` David Kastrup
@ 2003-02-05 12:45       ` gebser
  0 siblings, 0 replies; 24+ messages in thread
From: gebser @ 2003-02-05 12:45 UTC (permalink / raw)


David Kastrup at 01:50 (UTC+0100) on 5 Feb 2003 said:

= gebser@ameritech.net writes:
= 
= > Kevin Rodgers at 16:30 (UTC-0700) on Tue, 4 Feb 2003 said:
= > 
= > = gebser@ameritech.net wrote:
= > = 
= > = > Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
= > = > = But the main problem is that tramp-shell-prompt-pattern is not
= > = > = supposed to be a list.  It's supposed to be a string.
= > = > 
= > = > A string in elisp must be some really strange thing.
= > = > 
= > = > (add-to-list 'tramp-shell-prompt-pattern "abc")
= > = > 
= > = > also gives the same error.  It seems that everything and anything I put into
= > = > the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
= > = > it so's to do some helpful work on emacs.  Several times I've tried to do
= > = > simple things in elisp, following books and tutorials, but never had any
= > = > progress with it.  Maybe I need to be dyslexic.  :)
= > = 
= > = Emacs Lisp is not Tcl, and a string is not a list.
= > 
= > No argument here.  I'd even add that Emacs lisp isn't C, C++, java,
= > pascal, html, sh, bash, or perl.  But all these and many others have
= > pretty much the same syntax for a string.  You can go pretty far in any
= > of those-- at least assign a value to a variable-- just by knowing that
= > a string is zero or more characters enclosed in double quotes.
= > 
= > Anyone have a similarly easy recipe for a string is in elisp?
= 
= Pretty much the same.  Which is why you should not be using
= add-to-list on a string.

Thanks.

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
       [not found] <mailman.1406.1044395706.21513.help-gnu-emacs@gnu.org>
  2003-02-04 23:30 ` Kevin Rodgers
@ 2003-02-05 12:51 ` Kai Großjohann
  2003-02-05 15:17   ` gebser
  1 sibling, 1 reply; 24+ messages in thread
From: Kai Großjohann @ 2003-02-05 12:51 UTC (permalink / raw)


gebser@ameritech.net writes:

> Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
>
> I was following the documentation.  What would be the way to load a 
> *.texi file?

It doesn't make sense to "load" a *.texi file.  You can convert it to
info format with M-x texinfo-format-buffer RET or with the external
makeinfo program.  (Though the latter doesn't work in this case, of
course...)

After this, you'll have *.info files which you can look at with C-u
C-h i.

Where in the documentation did you find instructions to load the
*.texi files?  I couldn't see it.  I want to correct it...

> = > Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]".
> = 
> = I think it's M-x texinfo-format-buffer RET...
>
> Again, the command I used was directly from the docs.

Got to look at the docs again, to correct them.  [time passes]  Ah,
found it, and corrected it.

> = Yes, I also guess that the shell prompt wasn't recognized.  Lessee
> = now, what is the default value of tramp-shell-prompt-pattern?  Hm.
> = It should have matched this prompt.
> = 
> = So I'm somewhat confused.
>
> I don't know enough about this even to be confused....  8\
>
>
> = 
> = Could you put (setq tramp-verbose 10) and (setq tramp-debug-buffer t)
> = in ~/.emacs and try again and show me the *tramp/foo* buffer in
> = addition to the *debug tramp/foo* buffer?
> = 
> = Also, it would be good to do M-x toggle-debug-on-quit RET before
> = trying, then C-g will give you a backtrace.  Please send it, too.
> = 
> = Oh, and removing tramp.elc before starting Emacs will give a prettier
> = backtrace.
>
> Did all this.  Then tried to open a file on the same machine as before.

> $ # Setting shell prompt
> $ PS1='
> ///»¢ò ;YÖv­ 	éü­
> '; PS2=''; PS3=''

Now we're talking!  It's the bogus md5 invocation.  Whee.  I believe
this is fixed in the development sources already, so let me put out a
new version.

You could fetch the CVS version to test it, if you like.

> A string in elisp must be some really strange thing.
>
> (add-to-list 'tramp-shell-prompt-pattern "abc")
>
> also gives the same error.  It seems that everything and anything I put into
> the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
> it so's to do some helpful work on emacs.  Several times I've tried to do
> simple things in elisp, following books and tutorials, but never had any
> progress with it.  Maybe I need to be dyslexic.  :)

In Lisp, a general type is sequence.  Lists are one subtype of
sequence, and vectors are another.  Strings are vectors of characters.

add-to-list can only add to lists, not to arbitrary sequences.

Does this make sense?

-- 
A turnip curses Elvis

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05 12:51 ` Kai Großjohann
@ 2003-02-05 15:17   ` gebser
  2003-02-05 16:04     ` David Kastrup
  2003-02-05 17:06     ` Kevin Rodgers
  0 siblings, 2 replies; 24+ messages in thread
From: gebser @ 2003-02-05 15:17 UTC (permalink / raw)


Kai Großjohann at 13:51 (UTC+0100) on Wed, 5 Feb 2003 said:

= gebser@ameritech.net writes:
= 
= > Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
= >
= > I was following the documentation.  What would be the way to load a 
= > *.texi file?
= 
= It doesn't make sense to "load" a *.texi file.  You can convert it to
= info format with M-x texinfo-format-buffer RET or with the external
= makeinfo program.  (Though the latter doesn't work in this case, of
= course...)

Hmmm....  I loaded tramp.texi into a buffer, then did "M-x
texinfo-format-buffer RET" and it halted midway with the cursor on a
line saying "@macro trampver{}" and with the comment "@macro is not
handled by texinfo".


= 
= After this, you'll have *.info files which you can look at with C-u
= C-h i.

Did this and was prompted in the minibuffer for a filename (with the
current .../tramp/texi/ directory provided.  I looked at the directory
listing and found tramp.info, tramp.info-1, and tramp.info-2 and quite
arbitrarily picked tramp.info-1.  This then brings up the info file and
it seems to work.  I did the same again, but this time specifying
tramp.info-- this wasn't so good.  Hitting SPACE would page down fine,
but if I hit 'm' I was prompted for a menu item, then typed in the first
few chars of "Inst", hit TAB, it completed to "Installation"
successfully, but then when I hit ENTER, it beeped and said in the
minibuffer "No such anchor in tag table or node in tag table or file:
Installation".  Didn't have this problem with tramp.info-1.


= 
= Where in the documentation did you find instructions to load the
= *.texi files?  I couldn't see it.  I want to correct it...

It's on the web at <http://www.nongnu.org/tramp/> under
"Node:Installation".  The tramp tarball I got didn't have any
installation instructions.  Well, not until just now when, with your 
help, I got a working info file... sort of.

If, from the command line, I do "info tramp", info comes up, but says 
"No menu item `tramp' in node `(dir)Top'".

If you first warn installer-wannabees to use 'q' to quit/exit "info", 
you could hip them to the install instructions by having them or 
something run "cd ./texi; info --file tramp.info-1 --node Installation", 
this to bring up your instructions.

= 
= > = > Subsequently doing "M-x makeinfo-buffer" yeilds "[No match]".
= > = 
= > = I think it's M-x texinfo-format-buffer RET...
= >
= > Again, the command I used was directly from the docs.
= 
= Got to look at the docs again, to correct them.  [time passes]  Ah,
= found it, and corrected it.

The webpage still says:

"Something similar can be done to create the info manual. Just change to
directory ~/emacs/tramp/texi and load the tramp.texi file in Emacs. Then
press M-x makeinfo-buffer <RET> to generate tramp.info."

This is the "Tramp Manual" at <http://www.nongnu.org/tramp/>.


= ...
= >...
= > = 
= > = Could you put (setq tramp-verbose 10) and (setq tramp-debug-buffer t)
= > = in ~/.emacs and try again and show me the *tramp/foo* buffer in
= > = addition to the *debug tramp/foo* buffer?
= > = 
= > = Also, it would be good to do M-x toggle-debug-on-quit RET before
= > = trying, then C-g will give you a backtrace.  Please send it, too.
= > = 
= > = Oh, and removing tramp.elc before starting Emacs will give a prettier
= > = backtrace.
= >
= > Did all this.  Then tried to open a file on the same machine as before.
= 
= > $ # Setting shell prompt
= > $ PS1='
= > ///»¢ò ;YÖv­ 	éü­
= > '; PS2=''; PS3=''
= 
= Now we're talking!  It's the bogus md5 invocation.  Whee.  I believe
= this is fixed in the development sources already, so let me put out a
= new version.

Cool!  I really like progress.


= 
= You could fetch the CVS version to test it, if you like.
= 
= > A string in elisp must be some really strange thing.
= >
= > (add-to-list 'tramp-shell-prompt-pattern "abc")
= >
= > also gives the same error.  It seems that everything and anything I put into
= > the third arg is a listp.  It's a shame elisp is so obtuse.  I'd like to learn
= > it so's to do some helpful work on emacs.  Several times I've tried to do
= > simple things in elisp, following books and tutorials, but never had any
= > progress with it.  Maybe I need to be dyslexic.  :)
= 
= In Lisp, a general type is sequence.  Lists are one subtype of
= sequence, and vectors are another.  Strings are vectors of characters.
= 
= add-to-list can only add to lists, not to arbitrary sequences.
= 
= Does this make sense?

Yes, thanks much.  It's not enough for me write all those gorgeous
emacs apps I've been hankering to do, but, as said, I like progress.

I think I remember reading in a book or two that every|some (?) data
type(s) in elisp contain(s) an element (including perhaps null... or
nil... I forget, except there's a difference... I think) *and* the
implication of a subsequent such element-- hence, a sequence.

That a string is a vector of characters (delimited by double quotes,
yes?) is simple enough.  Is it also possible to have a list of
characters?  If not, why not?  If so, how would it be structurally or
functionally different or handled differently from a string?


Kai, thanks for your help and for the work you've done on this package.  
Much appreciated.

Regards,
ken

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05 15:17   ` gebser
@ 2003-02-05 16:04     ` David Kastrup
  2003-02-05 17:06     ` Kevin Rodgers
  1 sibling, 0 replies; 24+ messages in thread
From: David Kastrup @ 2003-02-05 16:04 UTC (permalink / raw)


gebser@ameritech.net writes:

> = > A string in elisp must be some really strange thing.
> = >
> = > (add-to-list 'tramp-shell-prompt-pattern "abc")
> = >

> = In Lisp, a general type is sequence.  Lists are one subtype of
> = sequence, and vectors are another.  Strings are vectors of characters.
> = 
> = add-to-list can only add to lists, not to arbitrary sequences.
> = 
> = Does this make sense?
> 
> Yes, thanks much.  It's not enough for me write all those gorgeous
> emacs apps I've been hankering to do, but, as said, I like progress.
> 
> I think I remember reading in a book or two that every|some (?) data
> type(s) in elisp contain(s) an element (including perhaps null... or
> nil... I forget, except there's a difference... I think) *and* the
> implication of a subsequent such element-- hence, a sequence.
> 
> That a string is a vector of characters (delimited by double quotes,
> yes?)

A string is basically a vector of characters.  It is not delimited by
double quotes: that is just the input/output syntax of strings, not
the strings themselves.  Strings are not exactly the same as vectors
of characters although very much behaving like the same and allowing
the same access methods: they have different I/O syntax, they can
represent only representable characters (and not key combinations like
M-x), they can carry text properties.

> is simple enough.  Is it also possible to have a list of characters?

Yes.

> If not, why not?  If so, how would it be structurally or
> functionally different or handled differently from a string?

Read the Elisp manual if you are interested in the Elisp data
structures.  No sense in retyping it here.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-04  1:08   ` gebser
@ 2003-02-05 16:33     ` bigfaceworm
  2003-02-05 19:09       ` gebser
  2003-02-07 22:12       ` Brian Palmer
  0 siblings, 2 replies; 24+ messages in thread
From: bigfaceworm @ 2003-02-05 16:33 UTC (permalink / raw)


gebser@ameritech.net wrote in message news:<Pine.LNX.4.44.0302031943250.16795-100000@heidegger.mousecar.net>...
> 
> My first thought was simply to edit my own (local) ".emacs" and putting
> it on his machine (as, say, .emacs-ken, then doing "emacs -t
> .emacs-ken").  I was looking for something even simpler and more
> discrete than that.  (Sheesh, I'm a lazy SOB.)

I remember playing around with this.  My issue was that
the color changes my .emacs set up wouldn't come into effect
if I manually loaded the .emacs.  But this .emacs (on the remote
machine) seemed to work just fine:


(eval-after-load 'dot-emacs
  (load-file "/bigfaceworm@localmachine.com:/path/to/bigfaceworm/.emacs"))

(provide 'dot-emacs)


hth,

BFW

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05 15:17   ` gebser
  2003-02-05 16:04     ` David Kastrup
@ 2003-02-05 17:06     ` Kevin Rodgers
  1 sibling, 0 replies; 24+ messages in thread
From: Kevin Rodgers @ 2003-02-05 17:06 UTC (permalink / raw)


mil_DocOutAbsgebser@ameritech.net wrote:

> Kai Großjohann at 13:51 (UTC+0100) on Wed, 5 Feb 2003 said:
> 
> = gebser@ameritech.net writes:
> = 
> = > Kai Großjohann at 18:30 (UTC+0100) on Tue, 4 Feb 2003 said:
> = >
> = > I was following the documentation.  What would be the way to load a 
> = > *.texi file?
> = 
> = It doesn't make sense to "load" a *.texi file.  You can convert it to
> = info format with M-x texinfo-format-buffer RET or with the external
> = makeinfo program.  (Though the latter doesn't work in this case, of
> = course...)
> 
> Hmmm....  I loaded tramp.texi into a buffer, then did "M-x
> texinfo-format-buffer RET" and it halted midway with the cursor on a
> line saying "@macro trampver{}" and with the comment "@macro is not
> handled by texinfo".


In Emacs terminology, you visited the file in a buffer (via `find-file').
The term "load" specifically means to load an Emacs Lisp source (.el) or
byte-compiled (.elc) file.


-- 
<a href="mailto:&lt;kevin.rodgers&#64;ihs.com&gt;">Kevin Rodgers</a>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05 16:33     ` bigfaceworm
@ 2003-02-05 19:09       ` gebser
  2003-02-07 22:12       ` Brian Palmer
  1 sibling, 0 replies; 24+ messages in thread
From: gebser @ 2003-02-05 19:09 UTC (permalink / raw)
  Cc: help-gnu-emacs


Thanks much, BFW,

That's what I was first looking for.

ken

bigfaceworm at 08:33 (UTC-0800) on 5 Feb 2003 said:

= gebser@ameritech.net wrote in message news:<Pine.LNX.4.44.0302031943250.16795-100000@heidegger.mousecar.net>...
= > 
= > My first thought was simply to edit my own (local) ".emacs" and putting
= > it on his machine (as, say, .emacs-ken, then doing "emacs -t
= > .emacs-ken").  I was looking for something even simpler and more
= > discrete than that.  (Sheesh, I'm a lazy SOB.)
= 
= I remember playing around with this.  My issue was that
= the color changes my .emacs set up wouldn't come into effect
= if I manually loaded the .emacs.  But this .emacs (on the remote
= machine) seemed to work just fine:
= 
= 
= (eval-after-load 'dot-emacs
=   (load-file "/bigfaceworm@localmachine.com:/path/to/bigfaceworm/.emacs"))
= 
= (provide 'dot-emacs)
= 
= 
= hth,
= 
= BFW
= _______________________________________________
= Help-gnu-emacs mailing list
= Help-gnu-emacs@gnu.org
= http://mail.gnu.org/mailman/listinfo/help-gnu-emacs
= 

-- 
Happy Gui-Wei 4700

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-04  6:39 ` Kai Großjohann
  2003-02-04 16:35   ` gebser
@ 2003-02-06  7:44   ` Mac
  2003-02-06 13:42     ` Kai Großjohann
  1 sibling, 1 reply; 24+ messages in thread
From: Mac @ 2003-02-06  7:44 UTC (permalink / raw)


En dag, närmare bestämt 2003-02-04, plitade Kai Großjohann ner:

> gebser@ameritech.net writes:
> 
>> I'm using X via ssh to open emacs on a remote machine but which
>> pops open a frame on my local box.  This is extremely cool, but how
>> can I have it load my local ".emacs" file when it does?
> 
> Try M-x load-file RET /user@host:/path/to/.emacs RET.  This logs
> into host via ftp.  Then there is Tramp which allows you to use ssh
> instead of ftp.  (Warning: I started Tramp.)
> 
> I think what I would do is to set up a CVS repository and put my dot
> files in there, then write a Makefile that sets up symlinks from
> $HOME to the locations in the CVS repository. 

Could anyone elaborate on which files the Makefile actually would
create links to.

I don't get it, but I really like the described end result. 

> (That's actually what I did.)  Then it becomes easy to access your
> dot files from anywhere, and also the modifications will propagate
> if you check in on your main machine and regularly update on the
> clients (or client's).

/mac

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-06  7:44   ` Mac
@ 2003-02-06 13:42     ` Kai Großjohann
  2003-02-06 14:06       ` Glenn Morris
  0 siblings, 1 reply; 24+ messages in thread
From: Kai Großjohann @ 2003-02-06 13:42 UTC (permalink / raw)


Mac <oonplnhd02@sneakemail.com> writes:

> En dag, närmare bestämt 2003-02-04, plitade Kai Großjohann ner:
>
>> I think what I would do is to set up a CVS repository and put my dot
>> files in there, then write a Makefile that sets up symlinks from
>> $HOME to the locations in the CVS repository. 
>
> Could anyone elaborate on which files the Makefile actually would
> create links to.
>
> I don't get it, but I really like the described end result. 

Let's say you have a CVS work directory ~/work/dotfiles for your,
well, dot files.  Then you'd create two files .emacs and Makefile
there and Makefile would look like this:

install:
        ( cd $HOME; ln -s work/dotfiles/.emacs )

After this, wherever you go, just

    mkdir ~/work
    cd ~/work
    cvs -d $YOUR_REPOSITORY co dotfiles
    cd dotfiles
    make install

The above is for a fresh account.  After you've done it once, just

    cd ~/work/dotfiles
    cvs up -dP
    make install

if the repository has changed.
-- 
A turnip curses Elvis

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-06 13:42     ` Kai Großjohann
@ 2003-02-06 14:06       ` Glenn Morris
  2003-02-06 15:12         ` Kai Großjohann
  0 siblings, 1 reply; 24+ messages in thread
From: Glenn Morris @ 2003-02-06 14:06 UTC (permalink / raw)


Kai Großjohann wrote:

> Let's say you have a CVS work directory ~/work/dotfiles for your,
> well, dot files.  Then you'd create two files .emacs and Makefile
> there and Makefile would look like this:
>
> install:
>         ( cd $HOME; ln -s work/dotfiles/.emacs )
>
> After this, wherever you go, just
>
>     mkdir ~/work
>     cd ~/work
>     cvs -d $YOUR_REPOSITORY co dotfiles
>     cd dotfiles
>     make install
>
> The above is for a fresh account.  After you've done it once, just
>
>     cd ~/work/dotfiles
>     cvs up -dP
>     make install

This sounds like a nice idea, but surely there is some faffing about
to be done with regards to authentication? In which case, does it
really gain you much over just

scp user@remotehost:.emacs ./

?

I suppose it does if you have a lot of config files you want to copy.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-06 14:06       ` Glenn Morris
@ 2003-02-06 15:12         ` Kai Großjohann
  2003-02-06 15:42           ` Glenn Morris
  0 siblings, 1 reply; 24+ messages in thread
From: Kai Großjohann @ 2003-02-06 15:12 UTC (permalink / raw)


Glenn Morris <gmorris+news@ast.cam.ac.uk> writes:

> This sounds like a nice idea, but surely there is some faffing about
> to be done with regards to authentication?

cvs can use ssh to connect to the remote host.  Then the faffing is
the same for scp and cvs.

export CVS_RSH=ssh
cvs -d :ext:user@host:/path/to/directory co bla

> In which case, does it really gain you much over just scp
> user@remotehost:.emacs ./ ?
>
> I suppose it does if you have a lot of config files you want to copy.

You can edit wherever you like and then commit.  You don't have to
think about which is the master copy.  Using the scp method means
that you always have to be careful where you edit the config file (if
you have more than 2 machines at least), and if you happen to edit it
on two hosts at the same time, you're screwed.

With cvs, no such problem.  Just edit, and if you remember, do "cvs
commit".  If you don't remember today, tomorrow is early enough.
-- 
A turnip curses Elvis

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-06 15:12         ` Kai Großjohann
@ 2003-02-06 15:42           ` Glenn Morris
  0 siblings, 0 replies; 24+ messages in thread
From: Glenn Morris @ 2003-02-06 15:42 UTC (permalink / raw)



Kai Großjohann wrote:

> You can edit wherever you like and then commit.  You don't have to
> think about which is the master copy.  Using the scp method means
> that you always have to be careful where you edit the config file (if
> you have more than 2 machines at least), and if you happen to edit it
> on two hosts at the same time, you're screwed.
>
> With cvs, no such problem.  Just edit, and if you remember, do "cvs
> commit".  If you don't remember today, tomorrow is early enough.

Mmm... sounds nice. I think you've convinced me to give it a go.

Thanks!

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: Loading local .emacs from remote machine
  2003-02-05 16:33     ` bigfaceworm
  2003-02-05 19:09       ` gebser
@ 2003-02-07 22:12       ` Brian Palmer
  1 sibling, 0 replies; 24+ messages in thread
From: Brian Palmer @ 2003-02-07 22:12 UTC (permalink / raw)


bigfaceworm@hotmail.com (bigfaceworm) writes:

> gebser@ameritech.net wrote in message news:<Pine.LNX.4.44.0302031943250.16795-100000@heidegger.mousecar.net>...
> > 
> > My first thought was simply to edit my own (local) ".emacs" and putting
> > it on his machine (as, say, .emacs-ken, then doing "emacs -t
> > .emacs-ken").  I was looking for something even simpler and more
> > discrete than that.  (Sheesh, I'm a lazy SOB.)
> 
> I remember playing around with this.  My issue was that
> the color changes my .emacs set up wouldn't come into effect
> if I manually loaded the .emacs.  But this .emacs (on the remote
> machine) seemed to work just fine:
> 
> 
> (eval-after-load 'dot-emacs
>   (load-file "/bigfaceworm@localmachine.com:/path/to/bigfaceworm/.emacs"))

Unless I'm missing something, that should be
(eval-after-load 'dot-emacs
  '(load-file
    "/bigfaceworm@localmachine.com:/path/to/bigfaceworm/.emacs")) 

if you actually want to not load the file until after the provide. 


-- 
If you want divine justice, die.
                  -- Nick Seldon 

^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2003-02-07 22:12 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.1346.1044295047.21513.help-gnu-emacs@gnu.org>
2003-02-03 23:45 ` Loading local .emacs from remote machine Kevin Rodgers
2003-02-04  1:08   ` gebser
2003-02-05 16:33     ` bigfaceworm
2003-02-05 19:09       ` gebser
2003-02-07 22:12       ` Brian Palmer
2003-02-04  6:39 ` Kai Großjohann
2003-02-04 16:35   ` gebser
2003-02-04 17:30     ` Kai Großjohann
2003-02-04 21:51       ` gebser
2003-02-06  7:44   ` Mac
2003-02-06 13:42     ` Kai Großjohann
2003-02-06 14:06       ` Glenn Morris
2003-02-06 15:12         ` Kai Großjohann
2003-02-06 15:42           ` Glenn Morris
     [not found] <mailman.1406.1044395706.21513.help-gnu-emacs@gnu.org>
2003-02-04 23:30 ` Kevin Rodgers
2003-02-05  0:38   ` gebser
2003-02-05  0:50     ` David Kastrup
2003-02-05 12:45       ` gebser
2003-02-05 12:37     ` gebser
2003-02-05 12:51 ` Kai Großjohann
2003-02-05 15:17   ` gebser
2003-02-05 16:04     ` David Kastrup
2003-02-05 17:06     ` Kevin Rodgers
2003-02-03 17:56 gebser

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).