All pastes #538421 Raw Edit

Stuff

public text v1 · immutable
·published 2007-06-05 00:53 UTC
rendered paste body
#!/bin/bash
set -x

MAPDIR=/home/akligman/tmp/df

# figure out which map is the newest.
NEWEST=`ls -tr ${MAPDIR}/local_map-1-* | tail -1`

# remove all the maps that aren't the newest
MAPS=( `echo ${MAPDIR}/local_map-1-*` )
for M in ${MAPS}; do
	if [ ${M} != ${NEWEST} ]; then
		echo removing ${M}

		# uncomment to actually remove the map
		# rm ${M}
	fi
done

# display the newest map
gthumb ${NEWEST}