0
0
Fork 0
mirror of https://github.com/nextcloud/server.git synced 2025-04-28 11:03:00 +00:00
nextcloud_server/build/psalm-checker.sh
Ferdinand Thiessen 16188cd767 chore: adjust copyright year
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2025-04-07 14:40:37 +02:00

31 lines
703 B
Bash
Executable file
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/bin/sh
# SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors
# SPDX-License-Identifier: AGPL-3.0-or-later
if [ -d "dist" ]; then
missing=''
for app in apps/*; do
if git check-ignore "$app" -q ; then
echo " Ignoring non shipped app: $app"
continue
fi
grep "directory name=\"$app\"" psalm.xml 2>&1 > /dev/null
if [ $? -ne 0 ]; then
missing="$missing - $app\n"
fi
done
if [ "$missing" = "" ]; then
echo "✅ All apps will be linted by psalm"
else
echo "❌ Following apps are not setup for linting using psalm:"
echo -e "$missing"
exit 1
fi
else
echo "⚠️ This script needs to be executed from the root of the repository"
exit 1
fi