From: Michael Albinus via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Maxim Cournoyer <maxim.cournoyer@gmail.com>
Cc: 68227@debbugs.gnu.org
Subject: bug#68227: 29.1; [tramp] adb stopped working (after upgrade from Emacs 28 to 29?)
Date: Mon, 08 Jan 2024 12:48:53 +0100 [thread overview]
Message-ID: <874jfoavve.fsf@gmx.de> (raw)
In-Reply-To: <87jzor6nhk.fsf@gmail.com> (Maxim Cournoyer's message of "Tue, 02 Jan 2024 23:37:43 -0500")
Maxim Cournoyer <maxim.cournoyer@gmail.com> writes:
> Hello,
Hi Maxim,
> I have an old Android 6 (!) phone to which I used to be able to copy
> files to/from via TRAMP and its adb support, by visiting the '/adb::'
> file.
>
> It doesn't work anymore: visiting '/adb::' prompts with "File /adb::/ is
> read-only on disk. Make buffer read-only, too? (y or n)" and if I
> answer "y" an empty buffer is displayed.
>
> I think the main change has been upgrading from Emacs 28 to Emacs 29
> since I last used that. The software on the phone hasn't budged (you
> can thank HTC for that ^^').
>
> The *tramp/adb * buffer has the following text:
>
> ls: Unknown option '-1'. Aborting.
>
> which seems like an important clue. Looking at tramp-adb.el in git
> blame, there does *not* seem to have been a recent change to the "ls"
> command arguments that would explain that new failure.
>
> Using adb directly, I can see:
>
> $ adb devices
> List of devices attached
> HT7281601342 device
>
>
> From an 'adb shell' session:
>
> shell@htc_alpine_dugl:/ $ ls -1
> ls: Unknown option '-1'. Aborting.
I've checked the tramp-adb.el versions integrated into Emacs 28 and
29. The relevant function is identitical:
--8<---------------cut here---------------start------------->8---
(defun tramp-adb-get-ls-command (vec)
"Determine `ls' command and its arguments."
(with-tramp-connection-property vec "ls"
(tramp-message vec 5 "Finding a suitable `ls' command")
(cond
;; Support Android derived systems where "ls" command is provided
;; by GNU Coreutils. Force "ls" to print one column and set
;; time-style to imitate other "ls" flavors.
((tramp-adb-send-command-and-check
vec (concat "ls --time-style=long-iso "
(tramp-get-remote-null-device vec)))
"ls -1 --time-style=long-iso")
;; Can't disable coloring explicitly for toybox ls command. We
;; also must force "ls" to print just one column.
((tramp-adb-send-command-and-check vec "toybox") "ls -1")
;; On CyanogenMod based system BusyBox is used and "ls" output
;; coloring is enabled by default. So we try to disable it when
;; possible.
((tramp-adb-send-command-and-check
vec (concat "ls --color=never -al " (tramp-get-remote-null-device vec)))
"ls --color=never")
(t "ls"))))
--8<---------------cut here---------------end--------------->8---
So there is no reason to behave differently. However, the result of this
function is cached. There might be something unstale. Could you, pls,
try to test w/o cached properties? That is, call
--8<---------------cut here---------------start------------->8---
# emacs -Q /adb::
--8<---------------cut here---------------end--------------->8---
Best regards, Michael.
next prev parent reply other threads:[~2024-01-08 11:48 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-03 4:37 bug#68227: 29.1; [tramp] adb stopped working (after upgrade from Emacs 28 to 29?) Maxim Cournoyer
2024-01-08 11:48 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2024-01-09 3:37 ` Maxim Cournoyer
2024-01-09 9:31 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-17 12:44 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-17 22:10 ` Maxim Cournoyer
2024-01-18 7:46 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-19 4:40 ` Maxim Cournoyer
2024-01-19 10:31 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-01-28 17:18 ` Michael Albinus via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-02-04 11:13 ` Michael Albinus 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=874jfoavve.fsf@gmx.de \
--to=bug-gnu-emacs@gnu.org \
--cc=68227@debbugs.gnu.org \
--cc=maxim.cournoyer@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 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.