Live data from Hacker News

$ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

transfer.sh

31–40 of 125 posts

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#31
post #27

PS> cat myfile | out-string | iwr -Method Put -Uri https://transfer.sh/myfile.txt

  PS> Invoke-SSHCommand { cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt } -session 0
SSH.NET: https://sshnet.codeplex.com/

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#33
Idea where can such service be used for nefarious purposes:

  while true
  do 
    dt=$(date '+%d%m%Y%H:%M:%S');
    screencapture -x file$dt.png
    curl --upload-file ./file$dt.png https://transfer.sh/66nb8/capture$dt.png
    rm file$dt.png
    sleep 1
  done

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#34
post #9

Obligatory xkcd : https://xkcd.com/949/

Just drop it on one of the folders in your Dropbox that's also served by IIS on one of your boxen. Then simply link from the appropriate subdomain on your personal domain. Been doing this for 15 years, dunno why nobody else does.

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#35
post #24
post #16

I use sprunge [ http://sprunge.us/ ] for the exact same purpose. Normal usage: $ more c14.py | sprunge And it outputs: http://sprunge.us/eCeM The nice thing about sprunge is that you also have syntax highlighting: http://sprunge.us/eCeM?py Appending a ? will syntax highlight the text according to the lang. P.S. To use a pipe with sprunge, put an alias in your .zshrc / .bashrc: alias sprunge="curl -F 'sprunge= http://…

I think the newness about this is that they've released the code on github under MIT, so you can self-host the service if you want. I think none of the othe rprojects mentioned here have are opensource or have a slef-hosted version.

sprunge (apparently) is released under WTFPL, and the sources are here https://github.com/rupa/sprunge.

According to http://www.wtfpl.net/about/, the first rule (and the only rule) of WTFPL is:

0. You just DO WHAT THE FUCK YOU WANT TO.

So, I guess you can self host it (:

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#36
post #14

It'd be cool to have the ability to pipe stuff over the Internet from shell in real time like you would with SSH for instance. So I could do: A$ curl --upload-file - http://blah B$ curl http://blah/uYsfVX and see live stream of data on B.

It reminds me of that: http://klaig.blogspot.com/2012/08/skypipe-cloud-based-namepi...

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#37
post #17
post #11

Regarding their tagline: “ Easy file sharing from the command line ”, this is also possible with Yandex Disk¹ (specifically, the Linux version here²). It also has less limitations than transfer.sh, specifically: • 10 GB of space for free (with a 10 GB filesize limitation³) over transfer.sh’s 5 GB • no file expiration date, unlike transfer.sh’s 14-day expiration ―――――― ¹ — https://disk.yandex.com/ ² — https://repo.yan…

b2 also has 10GB for free. https://www.backblaze.com/b2/cloud-storage-pricing.html

I built an R library for working with the b2 API:

https://github.com/phillc73/backblazer

It's on CRAN too, but the GitHub version has some updates.

This library should allow complete interaction with b2 for uploading, downloading and manipulating files from within R.

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#38
post #7

What's the advantage of doing this instead of just using SCP or SFTP?

People who doesn't even know what a text shell is can just drag a file icon onto the page to upload. No accounts or passwords are involved at either end, so it's about as frictionless as possible.

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#39
post #14

It'd be cool to have the ability to pipe stuff over the Internet from shell in real time like you would with SSH for instance. So I could do: A$ curl --upload-file - http://blah B$ curl http://blah/uYsfVX and see live stream of data on B.

You can do that with netcat if either A or B are listening.

I do this fairly regularly.

    A$ tar cv * | nc -l -p 1234

    B$ nc a.example.net 1234 | tar xv
Or I might remove a 'v' and pipe through 'pv' to see the transfer rate and amount.

Re: $ cat ~/myfile | curl -X PUT --upload-file “-” https://transfer.sh/myfile.txt

#40

I always wonder how sites like these deal with stuff like potentially hosting child porn/other content that is illegal to possess. Does DCMA safe harbor stuff cover it? (don't see a DCMA notice on the site)

I believe that DMCA safe harbor applies. If they're notified that they're hosting such content, then they have to remove it.
Post reply on HN