Skip to content

Commit 4593df9

Browse files
committed
Displays sorted log file
1 parent 4b65849 commit 4593df9

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

scripts/sort-log-file.sh

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
#!/bin/bash
2+
3+
LOG_FILE="${1}"
4+
5+
if [[ ! -e "${LOG_FILE}" ]]
6+
then
7+
echo "Could not open ${LOG_FILE}" >&2
8+
exit 1
9+
fi
10+
11+
cut -d '"' -f 2 ${LOG_FILE} | cut -d ' ' -f 2 | sort | uniq -c | sort -n

0 commit comments

Comments
 (0)