[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[h-e-w] sending filenames from command-line
From: |
rob . davenport |
Subject: |
[h-e-w] sending filenames from command-line |
Date: |
Tue, 6 Jun 2006 17:08:28 -0400 |
I'm trying to write a DOSKEY macro such that from a CMD.EXE window I can
say:
C:\>dired path
and the macro will invoke gnudoit (or gnuclientw with the -e option) to
get Emacs to
load dired on the specified path.
This is what I started with:
(I'm using the 23.0.0.1 ntemacs.sourceforge.net build and it's gnuclient
which
supports the -s and -e parameters)
dired=c:\sys\emacs\bin\gnuclientw.exe -sqe "(progn (raise-frame) (dired
(\"%CD%\")))"
BUT, of course the expansion of %CD% in the command prompt results in
stuff with
backslashes:
c:\sys\emacs\lisp
which, when passed to Emacs get cooked and ends up like "c: ys^[macs:isp".
I thought "I need to do an 'expand-file-name' or
'convert-standard-filename' or something
like that around the %CD%". I found a quick "convert backslashes to
forward slashes"
function and tried that, but nothing I've tried has worked - probably
because the string
is getting cooked before the elisp expression is evaluated. Is there some
way to better
quote it in the doskey macro to protect it from cooking until the elisp
can be evaluated?
Thanks,
Rob Davenport
- [h-e-w] sending filenames from command-line,
rob . davenport <=