X-Git-Url: https://gitweb.ps.run/ps-cgit/blobdiff_plain/ce56d89a2662549acd178292450798f5ffcd4bc6..55fa25adb097d2681607d8b0f51a0c393cc9af1a:/tests/setup.sh diff --git a/tests/setup.sh b/tests/setup.sh index 861f48a..5879348 100755 --- a/tests/setup.sh +++ b/tests/setup.sh @@ -60,6 +60,12 @@ fi FILTER_DIRECTORY=$(cd ../filters && pwd) +if cgit --version | grep -F -q "[+] Lua scripting"; then + export CGIT_HAS_LUA=1 +else + export CGIT_HAS_LUA=0 +fi + mkrepo() { name=$1 count=$2 @@ -98,7 +104,7 @@ virtual-root=/ cache-root=$PWD/cache cache-size=1021 -snapshots=tar.gz tar.bz zip +snapshots=tar.gz tar.bz tar.lz tar.xz tar.zst zip enable-log-filecount=1 enable-log-linecount=1 summary-log=5 @@ -125,15 +131,28 @@ repo.url=with space repo.path=$PWD/repos/with space/.git repo.desc=spaced repo -repo.url=filter +repo.url=filter-exec +repo.path=$PWD/repos/filter/.git +repo.desc=filtered repo +repo.about-filter=exec:$FILTER_DIRECTORY/dump.sh +repo.commit-filter=exec:$FILTER_DIRECTORY/dump.sh +repo.email-filter=exec:$FILTER_DIRECTORY/dump.sh +repo.source-filter=exec:$FILTER_DIRECTORY/dump.sh +repo.readme=master:a+b +EOF + + if [ $CGIT_HAS_LUA -eq 1 ]; then + cat >>cgitrc <