banner - Man Page
prints a short string to the console in very large letters
Examples (TL;DR)
- Print the text message as a large banner (quotes are optional):
banner "Hello World"
- Use a banner [w]idth of 50 characters:
banner -w 50 "Hello World"
- Read text from
stdin
:banner
Synopsis
banner string
Description
This is a classic-style banner program similar to the one found in Solaris or AIX in the late 1990s. It prints a short string to the console in very large letters.
Banners that do not fit in the terminal will be truncated. If $COLUMNS is exported in the environment, it is taken to be the width of the terminal. If $COLUMNS is not exported, and TIOCGWINSZ is available on the platform, then its idea of the terminal size is used. Otherwise, a terminal width of 80 characters is assumed.
Usage is straightforward. For instance, a single word is printed like this:
> banner ken
# # ####### # #
# # # ## #
# # # # # #
### ##### # # #
# # # # # #
# # # # ##
# # ####### # #
Multiple arguments are printed on separate lines:
> banner one two
####### # # #######
# # ## # #
# # # # # #
# # # # # #####
# # # # # #
# # # ## #
####### # # #######
####### # # #######
# # # # # #
# # # # # #
# # # # # #
# # # # # #
# # # # # #
# ## ## #######
To get a single long line containing whitespace, you must quote the string:
> banner "one two"
####### # # ####### ####### # # #######
# # ## # # # # # # # #
# # # # # # # # # # # #
# # # # # ##### # # # # # #
# # # # # # # # # # # #
# # # ## # # # # # # #
####### # # ####### # ## ## #######
Compatibility
From time to time, people assert that this program is buggy because it doesn't do something that some other banner implementation does. The behavior of the program is based on what I saw on Solaris and AIX systems at the time I wrote it in the late 1990s. I make no claims that the behavior is identical to that of any other contemporary system, especially any non-free system that I may or may not have access to.
If you don't like the behavior, you can either submit a patch, or you can use an alternative program such as figlet. I am always happy to accept patches, and I promise to integrate patches promptly if provided. So far, no one who's complained has bothered to provide any patches, so the behavior remains the same.
Author
Written by Kenneth J. Pronovici <pronovic@ieee.org>.
Copyright
Copyright (c) 2000-2004,2007,2013,2014,2020,2024 Kenneth J. Pronovici
This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.