mirror of
https://github.com/chenasraf/nextcloud-pantry.git
synced 2026-05-17 17:28:01 +00:00
build: add appinfo xmllint to precommit hook
This commit is contained in:
15
Makefile
15
Makefile
@@ -279,6 +279,21 @@ test-docker:
|
||||
echo "\x1b[33mRunning tests in container $$CONTAINER_ID for app $$APP_DIR\x1b[0m"; \
|
||||
docker exec $$CONTAINER_ID phpunit -c apps-shared/$$APP_DIR/tests/phpunit.docker.xml
|
||||
|
||||
info_xsd_url=https://apps.nextcloud.com/schema/apps/info.xsd
|
||||
info_xsd=$(build_tools_directory)/info.xsd
|
||||
|
||||
$(info_xsd):
|
||||
@mkdir -p $(build_tools_directory)
|
||||
curl -sS -o $(info_xsd) $(info_xsd_url)
|
||||
|
||||
# lint-appinfo:
|
||||
# - Validate appinfo/info.xml against the Nextcloud App Store XSD schema
|
||||
.PHONY: lint-appinfo
|
||||
lint-appinfo: $(info_xsd)
|
||||
@echo "\x1b[33mValidating appinfo/info.xml against Nextcloud schema...\x1b[0m"
|
||||
@xmllint --noout --schema $(info_xsd) appinfo/info.xml
|
||||
@echo "\x1b[32mappinfo/info.xml is valid.\x1b[0m"
|
||||
|
||||
# lint:
|
||||
# - Lint JS via pnpm and PHP via composer script "lint"
|
||||
.PHONY: lint
|
||||
|
||||
@@ -36,13 +36,13 @@ All data is scoped to a house; members only see the houses they belong to.
|
||||
<dependencies>
|
||||
<nextcloud min-version="29" max-version="34"/>
|
||||
</dependencies>
|
||||
<background-jobs>
|
||||
<job>OCA\Pantry\BackgroundJob\ReopenRecurringItemsJob</job>
|
||||
</background-jobs>
|
||||
<settings>
|
||||
<admin>OCA\Pantry\Settings\Admin</admin>
|
||||
<admin-section>OCA\Pantry\Sections\Admin</admin-section>
|
||||
</settings>
|
||||
<background-jobs>
|
||||
<job>OCA\Pantry\BackgroundJob\ReopenRecurringItemsJob</job>
|
||||
</background-jobs>
|
||||
<navigations>
|
||||
<navigation role="all">
|
||||
<name>Pantry</name>
|
||||
|
||||
@@ -20,3 +20,6 @@ pre-commit:
|
||||
openapi:
|
||||
glob: "*Controller.php"
|
||||
run: make openapi && git add openapi.json
|
||||
lint-appinfo:
|
||||
glob: "appinfo/info.xml"
|
||||
run: make lint-appinfo
|
||||
|
||||
Reference in New Issue
Block a user