From 028ab301fe80c9ed872fe8ba4be2819648e30d97 Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Wed, 6 Jan 2016 19:15:10 +0800 Subject: Add fish & redshift configs; Update gpg configs; Add mutt scripts --- .mutt/excel2text.sh | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100755 .mutt/excel2text.sh (limited to '.mutt/excel2text.sh') diff --git a/.mutt/excel2text.sh b/.mutt/excel2text.sh new file mode 100755 index 0000000..c3d0f14 --- /dev/null +++ b/.mutt/excel2text.sh @@ -0,0 +1,31 @@ +#!/bin/sh +# +# excel2text - convert MS Excel files to ASCII text +# +# Written by Gary Johnson . +# +# Modification History: +# 2003-02-19 +# Changed the name xlHtml to xlhtml to match the xlhtml-0.5 +# release. + +prog=${0##*/} + +if [ $# -ne 1 ] +then + echo "Usage: $prog file" >&2 + exit 2 +fi + +xlhtml -te "$1" | +perl -pe 's/>-{21,}
tags so + # that these lines adapt to the + # width of the cell. "21" is a + # value that works for the + # tables I'm sent. +w3m -dump -T text/html | +perl -pe ' + s/\xa0/ /gs; # Change A0 spaces to ASCII + # spaces. +' -- cgit v1.2.2