[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: Directory name to variable (dired?)
From: |
Drew Adams |
Subject: |
RE: Directory name to variable (dired?) |
Date: |
Sun, 7 Oct 2018 23:02:44 +0000 (UTC) |
> Is there a function that returns a directory and full path
> so that it could be assigned to a variable?
>
> Ideally, dired would be a great place to start, as the directory
> path is at the top of the screen.
In Dired, `M-0 w' invokes command `dired-copy-filename-as-kill'
with prefix arg 0, which copies the absolute name of the file
named on the current line.
Non-interactively, (dired-copy-filename-as-kill 0) does the
same thing.
Then (setq foo (current-kill 0)) sets variable `foo' to a string
with that absolute file name.
- Directory name to variable (dired?), Tim Johnson, 2018/10/07
- RE: Directory name to variable (dired?),
Drew Adams <=
- Re: Directory name to variable (dired?), Tim Johnson, 2018/10/07
- RE: Directory name to variable (dired?), Drew Adams, 2018/10/07
- Re: Directory name to variable (dired?), Tim Johnson, 2018/10/07
- RE: Directory name to variable (dired?), Drew Adams, 2018/10/07
- Re: Directory name to variable (dired?), Tim Johnson, 2018/10/08
- Re: Directory name to variable (dired?), Tim Johnson, 2018/10/08
- Re: Directory name to variable (dired?), Noam Postavsky, 2018/10/08
- RE: Directory name to variable (dired?), Drew Adams, 2018/10/08
- Re: Directory name to variable (dired?), Stefan Monnier, 2018/10/08
- Re: Directory name to variable (dired?), Tim Johnson, 2018/10/08