miscutils/mkgmap

16 lines
277 B
Plaintext
Raw Normal View History

2022-06-08 06:07:41 -04:00
#!/bin/sh
[ -f $HOME/.mkgmap.head ] && cat $HOME/.mkgmap.head
for i in $(ls -r *.txt)
do
date=$(echo $i | sed 's/\(....\)\(..\)\(..\).*/[\1.\2.\3]/')
name=$(
sed -n -e '
/[^ ]/ {
s/^[ ]*//
p
q
}
b' $i)
printf "0%s %s\t%s\n" "$date" "$name" "$i"
done