Quickly sharing files over wifi

I sometimes find myself needing to transfer a file to someone at the office. It's a common scenario. To solve this problem, a few options present themselves. The easiest one, in my opinion, is to just serve the file in question through HTTP from my own machine on the local network. I then send the link to whoever needs it. If you think about it, you will realize that it has many advantages :

  • It's easy to setup
  • Everyone these days has an HTTP client on their computer
  • Files can be protected from prying eyes thanks to HTTP authorization
  • You can resume downloads
  • You can serve entire directories

It has, however, a few downsides :

  • The file is no longer available if the server is turned off
  • The client has to be on the same network
  • It's probably not the most secure solution out there

To use this method, I usually resort to python's built in HTTP server. It's only a matter of navigating to the directory you want to serve and running the python3 -m http.server command. The directory listing will then visible from http://your.ip:8000

For more advanced use cases, a beefier HTTP server would be more appropriate. Lighttpd should do the trick. But the above solution fits most of my use cases and I rarely find myself needing to reach out to better suited solutions.

Honorable mentions :

Sending it via slack

Pros : supports drag and drop

Cons : slow when the file is too big

Sending it via Airdrop

Pros : easy to use

Cons : works only across Macbooks

Configuring file sharing

Pros : is the right tool for the job

Cons : I can never get it to work, especially when it involves different operating systems

Putting it in a USB stick and physically giving it to the other person

Pros : gets the job done

Cons : necessitates walking

Sending it with a carrier pigeon

Pros : not having to walk over to the other person's desk with a USB stick in your hand

Cons : having to breed carrier pigeons in the office

Using smoke signals

Pros : is a literally battle tested technology

Cons : triggers smoke detectors

File transfer
Relevant XKCD

Commentaires

Posts les plus consultés de ce blog

Porting a Golang and Rust CLI tool to D

Decrypting .eslock files

Résoudre le problème de téléversement avec Arduino Nano sous Windows 7