binana/script/sort-symbol-file

13 lines
241 B
Text
Raw Permalink Normal View History

2024-07-27 21:08:11 -04:00
#!/usr/bin/env bash
# this script just collects symbols into one file for convenience
if [ $# -eq 0 ]
then
echo "Select a file"
exit 1
fi
mv $1 "$1.bak"
awk '$2 = toupper($2)' "$1.bak" | awk 1 - | sort -k2 -t' ' > $1
rm "$1.bak"