File: check-overlays.sh

package info (click to toggle)
coq 9.1.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 35,968 kB
  • sloc: ml: 239,908; sh: 4,355; python: 2,985; ansic: 2,644; makefile: 874; lisp: 171; javascript: 63; xml: 24; sed: 2
file content (23 lines) | stat: -rwxr-xr-x 467 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/bash

REDBOLD="\033[31;1m"
RESET="\033[0m"

function redprint
{
  if [ "$COQ_CI_COLOR" ]; then
    printf "$REDBOLD%s$RESET\n" "$1"
  else
    printf '%s\n' "$1"
  fi
}

for f in $(git ls-files "dev/ci/user-overlays/")
do
    if ! { [[ "$f" = dev/ci/user-overlays/README.md ]] || [[ "$f" == *.sh ]]; }
    then
        >&2 redprint "Bad overlay '$f'."
        >&2 echo "User overlays need to have extension .sh to be picked up!"
        exit 1
    fi
done