Running SSHelper is a great way to access files on your phone. But completion of remote files (scp and rsync) using zsh doesn't work though. While using sshfs is a workaround but sometimes you just want to pull/push a quick file, it's not really satisfying.

Where lies the culprit, and how can I get file completion working properly via zsh?


1 Answer 1


The culprit is android's crippled ls command. Zsh's completion run ls -d1FL which /system/bin/ls doesn't understand.

A way to fix this is to edit /data/data/com.arachnoid.sshelper/home/.ssh/environment such that /data/user/0/com.arachnoid.sshelper/bin is the first entry in PATH. (SSHelper ships with a more complete ls)

Note that SSHelper might rewrite this file on updates?

  • 1
    Nice detail, thanks! Speaking of updates: if you use F-Droid, you can find the app in my repo (it uses the devs signature, so you can simply update what you got from there). And besides, as you've identified the culprit as the pre-installed ls command: was that the "stock" one, or would the ls provided by Busybox have the same limitation?
    – Izzy
    Commented Aug 22, 2017 at 10:18
  • 1
    busybox ls is sufficient I think. Ie. busybox ls supports at least some of the flags that the system doesn't.
    – olejorgenb
    Commented Aug 22, 2017 at 11:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .