[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to apply (multi file) patches conveniently
From: |
Michael Heerdegen |
Subject: |
Re: How to apply (multi file) patches conveniently |
Date: |
Wed, 08 Feb 2017 23:34:50 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) |
Thien-Thi Nguyen <ttn@gnu.org> writes:
> () Michael Heerdegen <michael_heerdegen@web.de>
> () Tue, 07 Feb 2017 21:22:30 +0100
>
> (let* ((insert-default-directory nil)
> (input (read-directory-name
> (format "Dir (default %s): "
> (or source-directory
> default-directory)))))
>
> Should this be moved into the ‘interactive’ form?
Yes, that would be appropriate. Well... this snipped was quickly
written, I posted it just for reference. But it would be better indeed.
>
> (if (string= input "")
> (expand-file-name (or source-directory
> default-directory))
> input))
>
> You can probably call ‘read-directory-name’ w/ some combination
> of DIR, DEFAULT-DIRNAME and INITIAL args to have it produce the
> same result.
Hmm, I avoided INITIAL because I prefer to start with an empty
minibuffer.
> Thien-Thi Nguyen -----------------------------------------------
> (defun responsep (query)
> (pcase (context query)
> (`(technical mailing-list) t)
^
You can use just a quote here instead of backquote, but it doesn't make
a difference when you run that code ;-)
Regards,
Michael.
- Re: How to apply (multi file) patches conveniently, (continued)
Re: How to apply (multi file) patches conveniently, Michael Heerdegen, 2017/02/07
Re: How to apply (multi file) patches conveniently, Thien-Thi Nguyen, 2017/02/08
Re: How to apply (multi file) patches conveniently,
Michael Heerdegen <=
Re: How to apply (multi file) patches conveniently, Thien-Thi Nguyen, 2017/02/09
Re: How to apply (multi file) patches conveniently, Stefan Monnier, 2017/02/07