]> gitweb.michael.orlitzky.com - mutt.git/blob - mutt-launcher
mutt-launcher: whitespace.
[mutt.git] / mutt-launcher
1 #!/bin/sh
2 #
3 # This is a wrapper around the "mutt" executable that takes the number
4 # of columns and lines present in the terminal as its first and second
5 # arguments. This works around an issue where launching "mutt" right
6 # away in a brand-new terminal launches it before the COLUMNS and
7 # LINES variables are set, and thus before "tput" knows how wide the
8 # terminal is.
9 #
10 # You will have to manually compute the right number of columns/rows
11 # by launching a terminal of your preferred size/font and then using
12 # "tput cols" and "tput lines" to figure out how many columns/lines
13 # it has.
14 #
15 if [ $# -lt 2 ]; then
16 echo "Usage: mutt-launcher <ncols> <nrows> [other-args]"
17 exit 1
18 fi
19 export COLUMNS="${1}"
20 shift
21 export LINES="${1}"
22 shift
23
24 exec mutt "${@}"