7
0
mirror of https://github.com/marado/RNID.git synced 2025-04-07 11:06:52 +00:00
rnid/scripts/55-anqep.sh
Marcos Marado 5cbc97b49b novo incumprimento: anqep - catálogo nacional de qualificações
Falta: pedir resolução do incumprimento
PS: o github é um penico!

Closes: #106
2025-03-29 17:48:12 +00:00

18 lines
878 B
Bash
Executable File

#!/bin/bash
# ufcdPesquisa (HTML) includes a few javascripts, including two main-es*5.*js , which are the ones that show that we're getting XLS results
# As long as those two imports remain the same, so does the RNID violation...
wget https://catalogo.anqep.gov.pt/ufcdPesquisa -o /dev/null
if [ ! "$(diff ufcdPesquisa scripts/55/ufcdPesquisa|wc -l)" -eq "0" ]; then
echo "anqep: incumprimento pode já não existir";
else
echo "anqep: Incumprimento mantém-se, a actualizar o README (faça um git diff, valide, e commit!)";
while IFS='' read -r line || [[ -n "$line" ]]; do
test "$(echo "$line"|grep -v -c "anqep")" -eq "1" \
&& echo "$line" \
|| (h=$(echo "$line"|cut -d\| -f1-4); t=$(echo "$line"|cut -d\| -f6-); nc=$(echo "$line"|cut -d\| -f5 | wc -m); printf "%s| %-$((nc-2))s|%s\n" "$h" "$(date +%Y/%m/%d)" "$t");
done < README.md > new
mv new README.md
fi