DEV Community

loading...
Cover image for How to access android files from linux terminal

How to access android files from linux terminal

jmr_code_social profile image Jorge Marquez ・1 min read

Hi there,
If you ever wanted to know how to access our android phone files from terminal, without using any third party app and just with a USB cable and GNome, here is how:

We need to check the GNOME Virtual file system (gfvs) to see it is available.

run the following command:

ls /run/user/1000/gvfs/

You will get an Media Transfer Protocol (mtp), for more about this, check this link: MTP

'mtp:host=PHONE_MANUFACTURER_AND_MODEL'

Now use it as it would be any other directory on your system

cd /run/user/1000/gvfs/mtp:host=PHONE_MANUFACTURER_AND_MODEL

Done, you can access your phone directory and do whaterver you want.

Bye!

Discussion (0)

pic
Editor guide