wput: The same, just in reverse

You might remember wget from last week — the omnipresent hyperflexible download tool that doubles (and triples) as a site crawler, mirror utility and download manager.

What would be great is if there was an opposite tool, one that followed much of the same structure and flag options as wget, but — wrap your head around this one — uploaded things, instead of downloading them!

Well, believe it or not, such a tool exists. And as luck would have it, it’s named … wput!

kmandla@6m47421: ~$ wput --help
Usage: wput [options] [file]... [url]...
  url        ftp://[username[:password]@]hostname[:port][/[path/][file]]

Startup:
  -V, --version         Display the version of wput and exit.
  -h, --help            Print this help-screen
  -b, --background      go to background after startup

Logging and input file:
  -o,  --output-file=FILE      log messages to FILE
  -a,  --append-output=FILE    append log messages to FILE
  -q,  --quiet                 quiet (no output)
  -v,  --verbose               be verbose
...

No screenshot this time, because no matter how clever or convenient wput is, I would still need a destination for my upload example. And as far as I know, there aren’t many sites that offer free, anonymous, one-time FTP uploads. What’s that about?! O_o

No matter. If you’re used to the style and arrangement of wget, you’ll appreciate that some of the controls are similar. The -q, -v, and -a flags carry the same meaning to wput as wget, and I see a few more that look the same.

Of course, a lot of them are also different, which can’t be avoided. For example, the -nc flag in wget, which stood for “no-clobber” and prevented re-downloading and overwriting files that appeared locally, is instead “no-continue” for wput … as in, don’t resume a partially uploaded file.

Like I said, there’s no way around some of those. But if you’re accustomed to wget’s way of doing things, wput might feel natural.

It looks like wput hasn’t seen many updates in the past few years, which you can interpret as feature-completeness, or just a drift toward complacency. It doesn’t bother me much, mostly because I don’t think FTP hasn’t changed much either. I would be surprised if wput hadn’t kept up with FTP. 🙄

So there it is, your reverse-gear wget. Now if only I had a spare computer around here, to set up an FTP server and actually try it out. … :\

One thought on “wput: The same, just in reverse

  1. ap0calypse

    I still prefer SCP 😉

    But good to know, that this exists. I used a FTP-push in one of my projects, maybe I can replace it with wput (I used lftp for this task).

Comments are closed.