ASA(1)

πŸ“¦ version 1.053, in alpine 3.24

πŸ’… ASA(1) β€” asa, bestie πŸ’–

okay so this is asa(1) from the User Contributed Perl Documentation section, and it's literally the carriag-control decoder of your dreams ✨


✨ NAME ✨

asa β€” interpret ASA/FORTRAN carriage-controls πŸš‚πŸ’¨


🌸 SYNOPSIS 🌸

asa [filename ...]

like, that's it. that's the whole vibe. you just hand it filenames and she goes πŸ”₯


πŸ¦‹ DESCRIPTION πŸ¦‹

okay so picture this: traditional FORTRAN programs put carriage-control characters in the first columns of their output πŸ‘€ and those got interpreted by older lineprinters according to the ASA vertical format control standard β€” and yes, ASA was the American Standards Association, which is now ANSI, iykyk πŸŽ€

under this standard, the first character of each printable record (line) determines vertical spacing, like this:

  blank    carriage return 0           two carriage returns 1
  Formfeed +           overprint -           three carriage returns
  (IBM extension)

(read the pairs out of those columns: blank = carriage return, 0 = two carriage returns, 1 = three carriage returns, + = Formfeed, and - = overprint β€” that last one's the IBM extension πŸ’…)

all other characters are discarded πŸ—‘οΈ and empty lines behave as though they have a leading blank, periodt.

asa interprets these characters. that's the whole job. she's an icon, she's a legend, she's the main character πŸ‘‘


πŸŽ€ EXIT VALUES πŸŽ€

  • 0 β€” normal exit, we love a clean getaway 🫢
  • 1 β€” inability to write on stdout or to read an input file 😭
  • 2 β€” bad argument πŸ™ˆ

these exit status values were chosen from MKS toolkit ngl πŸ’œ


🌈 AUTHOR 🌈

Jeffrey S. Haemer 🫑✨ (we stan)


πŸ’€ BUGS πŸ’€

okay so currently, asa just looks at the readability of its input files at startup time. it should really do it a file at a time, but that makes the code look gross 😭 fr fr, the author said it, not me.

the carriage-control - is an IBM extension. perhaps the default should ignore it, and there should be a -i option to interpret it πŸ‘€ (that's a maybe, bestie, not a promise)


πŸ‘‘ SEE ALSO πŸ‘‘

  • Communications of the ACM, Vol 7, No. 10, p. 606, October 1964. πŸ“š
  • NWG/RFC 189, Appendix C πŸ¦‹

go forth and decode those carriage controls, bestie. the lineprinters believe in you πŸ’–βœ¨

mwah πŸ’‹ β€” this has been perl v5.42.2, dated 2026-02-15, signing off for ASA(1) πŸŽ€πŸ«Ά

πŸ“¦ where this page comes from