#!/bin/sh

# inspired by Steve Kinzler's align script - see http://kinzler.com/me/align/

# requires tab-delimited input, output aligned by padding with spaces

# -a    Column alignment codes:
#
#         l left
#         c center
#         r right
#         n numeric (align on decimal point)
#         N numeric (decimal parts zero-padded)
#
# -g    Spacing between columns
# -h    Indent before columns

if [ "$#" -gt 0 ] && [ "$*" = "-" ]
then
  transmute -align -h 2 -g 4 -a l
else
  transmute -align "$@"
fi
