How to transfer files from and to my SailfishOS device without developer mode enabled? [answered]
asked 2018-02-27 16:04:48 +0200
This post is a wiki. Anyone with karma >75 is welcome to improve it.
Since it is very simple to enable developer mode and use ssh swiss as swiss army knife for everything, it seems to me as rather hard task to upload my media files to Sailfish X device without this. What I found so far:
- MTP - it is read only on my Debian (may be it is RW on Windows, havn't tested)
- ssh - possible in developer mode only
- CIFS - N/A
- USB Mass storage - N/A
- switch device OFF, remove SD, put it to PC, etc ... - last resort :)
have I missed something?
Edit (@olf):
Bluetooth file transfer (flaky), with a file-manager via Cloud storage (e.g. CargoDock), but also by starting an FTP-server on the phone (FTP Server by dipesh in OpenRepos or various FTP servers under AlienDalvik from F-Droid, e.g. primitive ftpd), SendToPhone (by mikol in Jolla Store), FishNetMount (various protocols; by korppi in OpenRepos), HTTP share folder (by schturman in OpenRepos), Dukto (Android, Linux, Windows, MacOS, bbOS 10) etc.
But IMO one should use the best tool for this purpose (rsync), either at the GUI with "Simple & quick file backup" or alternatively at the CLI (but then needs "Developer mode" enabled) as user nemo (just examples, needs to be adapted for your use case):
rsync -vvhhe ssh Documents/myDoc.txt nemo@<IP address>:Documents/ # Omit the "e ssh", if you do not want to use encrypted transfers
or
rsync -auvvhhe ssh Documents nemo@<IP address>:Documents # See flags "a", "u" and others in rsync's man page.
To check that the data has been transferred and written correctly, one can use:
rsync -nc -auvvhhe ssh <src> <dest> | grep -vF " is uptodate" # Should result in *total: matches=0 hash_hits=0 false_alarms=0 data=0*
I use MTP (on Windows, yes it is RW).
Spam Hunter ( 2018-02-27 16:33:43 +0200 )editI use syncthing (syncdings on fdroid) and it's the best!
krisko ( 2018-02-27 16:59:47 +0200 )editHi, MTP works fine on Windows and on Ubuntu 16.04, in both directions. Keeping media files in an SD card is not a bad idea, as Sailfish apps (Gallery, Mediaplayer) will find them in there.
jovirkku ( 2018-02-27 17:15:22 +0200 )editIn my Debian MTP actually works alright, no complaints. You can also try FTP on PC and use the Midnight Commander built-in client to access it.
figgis-diggis ( 2018-02-27 20:50:36 +0200 )editMTP works just fine on my Ubuntu, so try to setup your Debian properly :)
coderus ( 2018-02-27 21:20:34 +0200 )edit