BASE64(1)
π BASE64(1) β the girlboss guide to encoding β¨
okay so real talk, this is a page from the User Contributed Perl Documentation section of the manual, and it's literally just called BASE64(1). yes bestie, base64. the thing that turns your files into alphabet soup. she's iconic, she's useful, let's go π
β¨ NAME β¨
base64 β encode and decode base64 data π¦
like, that's it. that's her whole job. and she does it well.
πΈ SYNOPSIS πΈ
base64 [-dv] [-o FILE] [FILE]
short, sweet, slays every time. let's break the vibe down π
π«Ά DESCRIPTION π«Ά
π§ the encoding era (default mode)
so when you're encoding β which is the default mode, meaning you don't even gotta ask, she just does it β a binary file gets read in, and a base64 format file gets created. cute, right? β¨
and if you don't hand her an input file argument at all? or you pass - as the file? she just reads from stdin. no drama, no fuss. π«Ά
the base64 output contains 76 characters per line. every line. 76. periodt. π
and where does output go by default? stdout. obviously. β¨
π the decoding era
when you're decoding, the input file is expected to contain only valid base64 characters β and those are alphanumeric characters, plus +, plus /, plus =. that's the whole guest list, no plus-ones. π
spaces are ignored when decoding. so breathe, bestie, whitespace is fine π
β οΈ but listen β selecting a binary file as input will result in an error. like, it will genuinely not go well for you. this is the vibe check and the binary file is failing it π
π OPTIONS π
the following options are available, and yes, there are only three, she's low-maintenance:
-dβ decode data. literally the uno-reverse of the default mode π-o FILEβ write output to the specifiedFILE. where you tell her to drop the goods π-vβ print version number and exit. she'll tell you who she is, then she's gone πβ¨
π BUGS π
okay so here's the tea, and it's giving "i love her but" β
- no option exists for wrapping encoded base64 output at different column widths. so you're getting 76 characters per line and that's the whole menu. she said this is the width. π
- it might be desirable to ignore unrecognised input characters when decoding. key word: might. this version of
base64has no option for relaxing the input validation. strict queen. no exceptions, no mercy, no exceptions-to-the-exceptions π
ngl these are real limitations, not vibes-based ones β don't go looking for a flag that isn't there π
π AUTHOR π
written by Michael Mikonos. thank you for your service, king π«‘β¨
π COPYRIGHT π
Copyright (c) 2023 Michael Mikonos.
this code is licensed under the Artistic License 2. π¨
okay that's the whole page, you're officially base64 literate, go encode something and feel something πβ¨π¦
signing off from perl v5.42.2, dated 2026-02-15, in the BASE64(1) section β mwah, ily, see you in the group chat ππ
π¦ where this page comes from
- alpine 3.24: perl-power-tools-doc 1.053-r1 Β· GPL-2.0-or-later AND Artistic-1.0-Perl AND Artistic-2.0 AND BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms