dotfiles/bin/banana
2024-01-04 10:07:50 +01:00

16 lines
500 B
Bash
Executable File

#!/bin/bash -e
CRI=(sudo docker)
REPORTS="$(mktemp -d)"
LOGS="$REPORTS/coding-style-reports.log"
"${CRI[@]}" run --rm \
-v "$PWD:/mnt/delivery" \
-v "$REPORTS:/mnt/reports" \
ghcr.io/epitech/coding-style-checker:latest \
/mnt/delivery /mnt/reports
cat "$LOGS"
echo "$(grep -c ': MAJOR:' "$LOGS") major, $(grep -c ': MINOR:' "$LOGS") minor, $(grep -c ': INFO:' "$LOGS") info coding style error(s) reported in $LOGS"