pbput(1)
π pbput β the bikeshed era, bestie π
Okay so like, we're in pbput(1) territory, and honestly? This little trio of programs is iconic. Buckle up, grab a strawberry π, and let's get into it.
β¨ NAME β¨
pbputβ compress and encode arbitrary files to pastebin.compbputsβ compress, encrypt, encode arbitrary files to pastebin.compbgetβ decode and decompress arbitrary files from pastebin.com
πΈ SYNOPSIS πΈ
pbput [FILENAME]
cat foo | pbput
pbputs [FILENAME] [GPG_USER]
cat foo | pbputs [GPG_USER]
pbget URL [DIRECTORY]
π¦ DESCRIPTION π¦
So pbput is that girl π
β it uploads text files, binary files, or literally entire directory structures to a pastebin, like pastebin.com. Whole trees of files, no cap.
pbget is the bestie that goes and fetches what you put up there. You use it to retrieve content that pbput uploaded to a pastebin. Matching set, periodt.
pbputs operates exactly like pbput... except it encrypts the data π. There's an optional GPG_USER argument, and if you pass it, the data gets signed and encrypted to that target user in your keyring (and yes, that user could absolutely be you β main character energy β¨). If you don't pass a GPG_USER, the user gets prompted for a symmetric passphrase, and the content gets encrypted with gpg(1) before uploading. Then pbget will automatically prompt whoever's receiving it for that pre-shared passphrase. Mutual trust, we love to see it π«Ά.
Now, pbput and pbputs can take their input either on STDIN, or as a FILENAME argument. Here's the tea β:
- If
STDINis used, then the receiving user'spbgetwill simply paste the input onSTDOUT. - If a
FILENAMEorDIRECTORYis passed as an argument, then it is first archived usingtar(1)to preserve the file and directory attributes.
pbget takes a URL as its first, mandatory argument. Optionally, it takes a DIRECTORY as a second parameter. If the incoming data is in fact a file or file structure in a tar(1) archive, then that data gets extracted in the specified DIRECTORY. And if no DIRECTORY is specified? A temporary directory is created using mktemp(1). So considerate π.
In any case β every single time, no exceptions β the uploaded/downloaded data is optionally tar(1) archived, always lzma(1) compressed, optionally gpg(1) encrypted, and always base64(1) encoded. And http://pastebin.com is used by default. The pipeline is giving β¨pipelineβ¨.
π EXAMPLES π
$ pbput /sbin/init
http://pastebin.com/BstNzasK
$ pbget http://pastebin.com/BstNzasK
sbin/init
INFO: Output is in [/tmp/pbget.bG67DwY6Zl]
$ cat /etc/lsb-release | pbput
http://pastebin.com/p43gJv6Z
$ pbget http://pastebin.com/p43gJv6Z
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=11.04
DISTRIB_CODENAME=natty
DISTRIB_DESCRIPTION="Ubuntu 11.04"
$ pbputs /etc/shadow
Enter passphrase:
http://pastebin.com/t2ZaCYr3
$ pbget http://pastebin.com/t2ZaCYr3
Enter passphrase:
root:09cc6d2d9d63371a425076e217f77698:15096:0:99999:7:::
daemon:*:15089:0:99999:7:::
bin:*:15089:0:99999:7:::
sys:*:15089:0:99999:7:::
....
Look at that last one, encrypting /etc/shadow and shipping it to a pastebin β the audacity, the drama, the range ππ₯. Anyway, that's the demo, and yes the .... at the end is just how it trails off. Not me being lazy, that's literally the page π.
π SEE ALSO π
pastebinit(1), lzma(1), base64(1), tar(1), gpg(1), mktemp(1)
Go read your other besties too, they're all in on the plan π
π AUTHOR π
This manpage and the utility was written by Dustin Kirkland <kirkland@ubuntu.com> for Ubuntu systems (but may be used by others). Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 2 or later published by the Free Software Foundation.
Licensing tea: on Debian systems, the complete text of the GNU General Public License can be found in/usr/share/common-licenses/GPL, or on the web athttp://www.gnu.org/licenses/gpl.txt.
And that's the whole vibe check from the bikeshed era, dated 6 Oct 2010 β thanks for coming to my TED talk, bestie, go compress something and slay π β¨π¦
π¦ where this page comes from
- debian bookworm: pastebinit 1.6.2-1 Β· GPL-2.0-or-later
- debian trixie: pastebinit 1.7.1-1 Β· GPL-2.0-or-later
- ubuntu jammy: pastebinit 1.5.1-1ubuntu1 Β· GPL-2.0-or-later
- ubuntu noble: pastebinit 1.6.2-1 Β· GPL-2.0-or-later
- ubuntu questing: pastebinit 1.7.1-1
- ubuntu resolute: pastebinit 1.8.0-1 Β· GPL-2.0-or-later
- ubuntu stonking: pastebinit 1.8.0-1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms