Closed jeremyb31 closed 6 years ago
Temporary workarounds to use termbin.com instead These methods are just temporary till a fix comes along or gist-paste gets removed in favour of pastebinit which wasn't installed by default for me.
Method 1 (recommended):
echo "alias pastebin='nc termbin.com 9999'" >> ~/.bash_aliases && source ~/.bashrc
This will create/add a 'pastebin' alias command to your bash_aliases file for just your user and is my recommended way, does not affect system installed programs as far as I can tell.
To remove it, open up ~/.bash_aliases in your favourite text editor and remove the line "alias pastebin='nc termbin.com 9999'" and save the file (If it's the only line in this file, file is safe to remove). You may need to log out and log back in for the changes to take place.
Backup for Method 2 (optional but you know you should do it):
backup: sudo mv /usr/bin/pastebin /usr/bin/pastebin.bak
to restore: sudo mv /usr/bin/pastebin.bak /usr/bin/pastebin
Method 2 (could break things):
sudo echo "nc termbin.com 9999" > /usr/bin/pastebin && sudo chmod +x /usr/bin/pastebin
(Please note I have not looked at how System Info (cinnamon-settings info) may take advantage of using pastebin or any other programs that may rely on it. Could cause those programs to not work as intended)
Both methods will achieve commands like this to work, user alias has higher priority:
inxi -Fxxxzrc0 | pastebin
You will receive a link generated from termbin.com instead of gist.github.com which no longer allows anonymous posts and requires you to log in.
I do have another Method, which you install pastebinit and then modify a line in /usr/bin/pastebin to use that instead of gist-paste. This could be considered a fix however but pastebinit will be required for pastebin to work. This may solve other application issues too.
https://blog.github.com/2018-02-18-deprecation-notice-removing-anonymous-gist-creation/ Any user using pastebin command receives the following in terminal
Error: Got Net::HTTPUnprocessableEntity from gist: {"message":"Validation Failed","errors":[{"resource":"Gist","code":"missing_field","field":"user"}],"documentation_url":"https://developer.github.com/v3/gists/#create-a-gist"}
User can only use gist.github.com after logging in usinggist-paste --login
and entering their github username/password