mirror of
https://github.com/lalbornoz/roar.git
synced 2024-11-30 02:26:38 +00:00
18 lines
533 B
Bash
18 lines
533 B
Bash
|
#!/bin/sh
|
||
|
#
|
||
|
# MiRCARTCheckLineLengths.py -- check mIRC art line lengths
|
||
|
# Copyright (c) 2018 Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de>
|
||
|
# This project is licensed under the terms of the MIT licence.
|
||
|
#
|
||
|
|
||
|
for FNAME in "${@}"; do
|
||
|
FNAME_LINES="$(wc -l "${FNAME}" | awk '{print $1}')";
|
||
|
for FNAME_LINE in $(seq "${FNAME_LINES}"); do
|
||
|
printf "%-5d %-5d %s\n" \
|
||
|
"$(sed -n "${FNAME_LINE}p" "${FNAME}" | wc -c)" \
|
||
|
"${FNAME_LINE}" "${FNAME}";
|
||
|
done;
|
||
|
done | sort -nk1;
|
||
|
|
||
|
# vim:expandtab foldmethod=marker sw=4 ts=4 tw=120
|