From: Philip Kaludercic <philipk@posteo.net>
To: Joseph Turner <joseph@breatheoutbreathe.in>
Cc: 63336@debbugs.gnu.org
Subject: bug#63336: [PATCH] package-vc: Process :make and :shell-command spec args
Date: Sat, 13 May 2023 17:18:24 +0000 [thread overview]
Message-ID: <87r0rk880v.fsf@posteo.net> (raw)
In-Reply-To: <877ctghey0.fsf@posteo.net> (Philip Kaludercic's message of "Wed, 10 May 2023 06:35:03 +0000")
ping?
Philip Kaludercic <philipk@posteo.net> writes:
> Joseph Turner <joseph@breatheoutbreathe.in> writes:
>
>>>> +(defun package-vc--make (pkg-spec dir)
>>>> + "Process :make and :shell-command spec arguments."
>>>> + (let ((target (plist-get pkg-spec :make))
>>>> + (cmd (plist-get pkg-spec :shell-command)))
>>>> + (when (or cmd target)
>>>> + (with-current-buffer (get-buffer-create " *package-vc make*")
>>> ^
>>> should the package name
>>> be mentioned here?
>>
>> I like this idea, but IIUC package-vc--make would then need to take an
>> extra arg, since pkg-spec doesn't contain the :name of the package. We
>> could also add :name to the pkg-spec plist?
>
> I wouldn't be in favour of that, I think that passing the name as a
> separate argument would be a better solution.
>
>> For comparison, package-vc--build-documentation creates a buffer called
>> " *package-vc doc*" without the package name.
>
> The difference I see here is that documentation usually builds fine,
> while :make or :shell-command have a higher chance of failing because
> some software is missing, especially if people don't use :make the way
> it is used on the ELPA server but to build external dependencies (I'm
> thinking of mail clients like notmuch)
>
>>>> + target (buffer-name)))))))
>>>> +
>>>> (declare-function org-export-to-file "ox" (backend file))
>>>>
>>>> (defun package-vc--build-documentation (pkg-desc file)
>>>> @@ -486,6 +515,9 @@ documentation and marking the package as installed."
>>>> ;; Generate package file
>>>> (package-vc--generate-description-file pkg-desc pkg-file)
>>>>
>>>> + ;; Process :make and :shell-command arguments before building documentation
>>>> + (when package-vc-process-make (package-vc--make pkg-spec pkg-dir))
>>>
>>> Wasn't the plan to allow `package-vc-process-make' to either be a
>>> generic "build-anything" or a selective listing of packages where we
>>> allow :make and :shell-command to be executed?
>>
>> Let me know if the attached commit accomplishes what you had in mind.
>
> Yes, that (or rather the newest version from a different message) looks good.
>
>>>> +
>>>> ;; Detect a manual
>>>> (when (executable-find "install-info")
>>>> (dolist (doc-file (ensure-list (plist-get pkg-spec :doc)))
>>>
>>> Otherwise this looks good, but I haven't tried it out yet.
>>
>> I fixed up a couple other issues:
>>
>> - removed unnecessary dir arg to package-vc--make
>> - added function arg to the docstring for package-vc--make
>>
>> I'm not sure if the customization type for package-vc-process-make is
>> correct. Please double check that.
>>
>> Also, should users be able to run :make and :shell-command args defined
>> in a spec passed into package-vc-install?
>
> Yes, is that currently not supported?
>
>> Best,
>>
>> Joseph
prev parent reply other threads:[~2023-05-13 17:18 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-06 20:39 bug#63336: [PATCH] package-vc: Process :make and :shell-command spec args Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-07 9:03 ` Philip Kaludercic
2023-05-07 18:47 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-08 8:42 ` Ruijie Yu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-08 19:38 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-09 0:03 ` Richard Stallman
2023-05-10 6:35 ` Philip Kaludercic
2023-05-11 1:37 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-14 7:44 ` Philip Kaludercic
2023-05-14 8:08 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-14 19:30 ` Philip Kaludercic
2023-05-14 23:01 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-15 9:12 ` Philip Kaludercic
2023-05-15 19:03 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-16 19:29 ` Philip Kaludercic
2023-05-16 21:08 ` Joseph Turner via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-05-17 14:07 ` Philip Kaludercic
2023-05-13 17:18 ` Philip Kaludercic [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r0rk880v.fsf@posteo.net \
--to=philipk@posteo.net \
--cc=63336@debbugs.gnu.org \
--cc=joseph@breatheoutbreathe.in \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.