Live data from Hacker News

How to copy a file between devices? (2022)

grdw.nl

111–120 of 354 posts

Re: How to copy a file between devices? (2022)

#113

Been using KDE Connect for years and it can do exactly that, along with clipboard sharing, SMS, and device notifications. https://kdeconnect.kde.org/

I really wish this was the One True Way, but unfortunately I couldn't get this working. Installed fine but then, nothing.

Re: How to copy a file between devices? (2022)

#114

Any hackers left here? Why no one mentions netcat? # send cat file | nc -l -p 8888 # receive nc IP-OF-SENDER 8888 > file this works as long as both computers are connected to the same network, for example the internet

There is also:

    python -m http.server
Which tends to be my go-to solution for file transfer between devices, it shares the current directory over HTTP. Not perfect, since HTTP makes downloading directories rather cumbersome, but at least every device that can open a website can download stuff.

Re: How to copy a file between devices? (2022)

#115

Any hackers left here? Why no one mentions netcat? # send cat file | nc -l -p 8888 # receive nc IP-OF-SENDER 8888 > file this works as long as both computers are connected to the same network, for example the internet

Because there are no terminals on phones (by default).

Re: How to copy a file between devices? (2022)

#116

Writing code is fun, but I can't find much of a downside with Bluetooth here. "You can accidentally turn it on" (fair, I guess?) "and it drains battery like crazy" (it shouldn't unless you have a very buggy device) don't seem like that bad compared to Yet Another File Sharing App. I remember way back in the Android 4 era, my phone and my tablet both supported some "standard" form of WiFi Direct. It worked intuitively…

No no, file sharing is privacy! Not allowed. Also both SMB implementations are "let's implement a protocol and add security later" nightmare.

> file sharing is privacy

I think the worse blocker is _piracy_. The copyright predators are terrified about people sharing files locally.

Re: How to copy a file between devices? (2022)

#117

I setup Samba share on my LAN. It works well enough for my purposes. It's not super smooth as not every app let's me open a file directly from the network and I need to make a copy first.

Fun fact: While most people think Samba as LAN-only thing, it actually works "fine" over internet too. For example sysinternals suite is available that way: https://learn.microsoft.com/en-us/sysinternals/#sysinternals...

Re: How to copy a file between devices? (2022)

#118

Earlier quoted context omitted.

If only we had something like AirDrop that reliably worked cross-platform. Proximity-based sharing just makes significantly more sense than uploading files to some server miles away, then immediately redownloading them back when the computer was two feet away from you the whole time.

Maybe LocalSend? https://localsend.org/ Windows, Linux, Android, iOS and macOS. Seems quite cross-platform. Can confirm it works smoothly for Linux and Android at the very least.

Seconded for LocalSend.

Works a treat for me.

Re: How to copy a file between devices? (2022)

#119
post #102

Here's a thought: This article is exploring the wrong problem. The filesystem where my files reside should already be a fully-distributed filesystem covering all the devices I own, right from the moment I buy and enroll them. With that precondition, my file is already where I need, and any physical bit shuffling is just a detail managed by the OS, using whatever connectivity is already available (or prompting me to "…

Isn't that exactly the model of Gdrive/OneDrive/DropBox etc? Except they might not do any LAN transfer optimizations, but that is minor implementation detail

edit: apparently at least Dropbox has had LAN sync for nearly a decade: https://dropbox.tech/infrastructure/inside-lan-sync

Re: How to copy a file between devices? (2022)

#120

Why don't we just put SSH scp on all devices?

SSH requires to have shell access on the receiving end, that renders it unusable in most situations. Rsync can in theory do anonymous file offerings, but it's not a shell one-liner to get it up and running either.
Post reply on HN