How do I post of file to pastebin or similar service from the command line?

0

I want to be able to paste from the command line to pastebin (or similar), but it seems that pastebinit doesn't work anymore:

THIS API HAS BEEN DISABLED. Please use Pastebin's new API. http://pastebin.com/api

sorin

Posted 2012-12-18T11:06:43.190

Reputation: 9 439

1Simply use the example code from the new API in a PHP script (under "Creating A New Paste"). I just tried it and it worked right away. Or do you have any specific problems getting that to work for you? – slhck – 2012-12-18T11:14:43.397

Answers

0

You can. Use GitHub gist.

curl -X POST \--data-binary '{"files": {"file1.txt": {"content": "Hello, SO"}}}' \https://api.github.com/gists

kyle k

Posted 2012-12-18T11:06:43.190

Reputation: 111

{ "message": "Requires authentication", "documentation_url": "https://developer.github.com/v3/gists/#create-a-gist" }

– evandrix – 2019-01-08T20:16:48.703