From: Ant via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: 64303@debbugs.gnu.org
Subject: bug#64303: 30.0.50; Android build: use Activities as a way to interact with emacsclient?
Date: Mon, 26 Jun 2023 16:21:52 +0000 [thread overview]
Message-ID: <4f26284b-7435-7fb1-425b-b50cb886a07a@pm.me> (raw)
The EmacsActivity.java and EmacsOpenActivity.java files show that it is
possible to pass argument by means of Android Activities. Furthermore,
EmacsOpenActivity (the file that handles Emacs selection in "Open
With..." dialogs) does use emacsclient (or its equivalent
libemacsclient.so) in order to reuse the same Emacs instance and frame.
It is possible to manually invoke Android Activities (with custom
parameters) by means of the
command "am" in
the adb shell, the command "am" in the Termux shell or also by means of
some Androids applications like ActivityManager
(https://github.com/sdex/ActivityManager) that also allows to make
shortcuts out of them.
It could be an idea to "generalize" EmacsOpenActivity and to have an
activity that allows to insert custom parameters that would be fed to
libemacsclient. EmacsActivity.java already does something similar, by
means of the extra argument "org.gnus.emacs.STARTUP_ARGUMENT".
One use case would be, trivially, to have a shortcut for
org-capture or some other org-protocol.
I'm not an Android guru myself and so I don't know whether this is a good
idea or not, security-wise. Also, I don't know if this is just an hack
that won't last too long anyway.
I'd like to know your opinions in this regard. Thank you in advance!
next reply other threads:[~2023-06-26 16:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-26 16:21 Ant via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2023-06-27 0:42 ` bug#64303: 30.0.50; Android build: use Activities as a way to interact with emacsclient? Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-06-29 9:22 ` Ant via Bug reports for GNU Emacs, the Swiss army knife of text editors
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=4f26284b-7435-7fb1-425b-b50cb886a07a@pm.me \
--to=bug-gnu-emacs@gnu.org \
--cc=64303@debbugs.gnu.org \
--cc=n58r@pm.me \
/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.