From: Lars Ingebrigtsen <larsi@gnus.org>
To: Michael Albinus <michael.albinus@gmx.de>
Cc: Gustavo Barros <gusbrs.2016@gmail.com>, 57856@debbugs.gnu.org
Subject: bug#57856: 28.2; bookmark context strings in encrypted files
Date: Mon, 19 Sep 2022 09:42:44 +0200 [thread overview]
Message-ID: <87leqfzu6j.fsf@gnus.org> (raw)
In-Reply-To: <87mtaxx8s7.fsf@gmx.de> (Michael Albinus's message of "Sun, 18 Sep 2022 12:43:20 +0200")
Michael Albinus <michael.albinus@gmx.de> writes:
>> Right... switching off bookmark context lines would go into
>> `epa-file-insert-file-contents' in the gpg case, I think -- where would
>> we do that in the Tramp case?
>
> There is `tramp-handle-insert-file-contents'. Since this is used for
> several Tramp backends, we need a check, whether Tramp encryption is
> active. Something like
>
> (when (tramp-crypt-file-name-p filename)
> ...)
>
> OTOH, this would expose the "tramp-crypt-" namespace to tramp.el. Hmm,
> maybe I will adapt the solution, but you could start with this.
Looking at how to integrate this (which is always iffy when we're
dealing with several packages), I think this has to be done the other
way. That is, `bookmark-make-record' has to check whether the file is
encrypted or not, becaues `*insert-file-contents' might not have been
run at all (if this is a new encrypted file, for instance).
So `tramp-crypt-file-name-p' is perfect for that, but there doesn't seem
to be any `epa-file-name-p' (or something equivalent)? Hm... OK, that
was trivial to add, so I've now done it this way in Emacs 29.
next prev parent reply other threads:[~2022-09-19 7:42 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-16 11:08 bug#57856: 28.2; bookmark context strings in encrypted files Gustavo Barros
2022-09-16 12:07 ` Lars Ingebrigtsen
2022-09-16 12:30 ` Gustavo Barros
2022-09-16 13:01 ` Lars Ingebrigtsen
2022-09-16 13:18 ` Michael Albinus
2022-09-18 10:19 ` Lars Ingebrigtsen
2022-09-18 10:43 ` Michael Albinus
2022-09-19 7:42 ` Lars Ingebrigtsen [this message]
2022-09-19 9:00 ` Michael Albinus
2022-09-19 12:03 ` Lars Ingebrigtsen
2022-09-19 12:16 ` Michael Albinus
2022-09-19 12:34 ` Lars Ingebrigtsen
2022-09-19 13:03 ` Michael Albinus
2022-09-19 18:44 ` Lars Ingebrigtsen
2022-09-20 14:49 ` Michael Albinus
2022-09-20 14:53 ` Lars Ingebrigtsen
2022-09-20 15:00 ` Michael Albinus
2022-09-20 15:03 ` Gustavo Barros
2022-09-20 16:19 ` Michael Albinus
2022-09-19 11:13 ` Gustavo Barros
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87leqfzu6j.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=57856@debbugs.gnu.org \
--cc=gusbrs.2016@gmail.com \
--cc=michael.albinus@gmx.de \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
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).