I have connected a smartphone and would like to copy some file onto it using midnight commander. I've found out that the mount point is mtp://[usb:002,004]/Card/ however when I try to run cd mtp://[usb:002,004]/Card/ I get No such file or directory. How should I point to it in terminal?
Asked
Active
Viewed 7,461 times
6
Tomasz Kapłoński
- 173
1 Answers
8
I think this has two main problems:
It won't understand the path
mtp://[usb:001,009]/SD%20cardIt likely won't want to use
[,,,]etc in the path name - spaces may cause issues as well.
On my system, mtp://[usb:001,009]/SD card/ shows up as this in terminal:
/run/user/1000/gvfs/mtp:host=%5Busb%3A001%2C009%5D/SD card
So for your device you will likely have to do:
cd "/run/user/1000/gvfs/mtp:host=%5Busb%3A002%2C004%5D/"
Where:
- Its in quotes so it can do the name with the space.
- The
1000(probably) is User ID - you may have to replace it with${UID}(or just the value ofecho $UID). On some systems it may be the name of the user (soecho $USER). - The subdirectories of the mounted MTP device likely will be
phone(orInternal storage) andSD card(or justcard), depending on your setup.
Wilf
- 30,732