#!/usr/bin/ksh # # Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T # All Rights Reserved # Copyright (c) 1988, 2011, Oracle and/or its affiliates. All rights reserved. # compress - compress the spell program log H_SPELL=${H_SPELL:-$HOME/.spellhist} trap 'rm -f /usr/tmp/spellhist;exit' 1 2 3 15 echo "COMPRESSED `date`" > /usr/tmp/spellhist grep -v ' ' $H_SPELL | sort -fud >> /usr/tmp/spellhist cp /usr/tmp/spellhist $H_SPELL rm -f /usr/tmp/spellhist