mirror of
https://github.com/nextcloud/server.git
synced 2025-09-18 15:04:08 +00:00
feat(openapi): Generate merged spec for all apps
Signed-off-by: provokateurin <kate@provokateurin.de>
This commit is contained in:
parent
3732be59fd
commit
95df189595
4 changed files with 30720 additions and 0 deletions
|
@ -342,3 +342,7 @@ License: CC0-1.0
|
|||
Files: apps/theming/fonts/OpenDyslexic-Bold.otf apps/theming/fonts/OpenDyslexic-Regular.otf
|
||||
Copyright: 2012-2019 Abbie Gonzalez <https://abbiecod.es|support@abbiecod.es>, with Reserved Font Name OpenDyslexic.
|
||||
License: OFL-1.1-RFN
|
||||
|
||||
Files: openapi.json
|
||||
Copyright: 2025 Nextcloud GmbH and Nextcloud contributors
|
||||
License: AGPL-3.0-or-later
|
||||
|
|
|
@ -69,6 +69,7 @@ $expectedFiles = [
|
|||
'occ',
|
||||
'ocs',
|
||||
'ocs-provider',
|
||||
'openapi.json',
|
||||
'package-lock.json',
|
||||
'package.json',
|
||||
'psalm-ncu.xml',
|
||||
|
|
|
@ -3,12 +3,25 @@
|
|||
# SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors
|
||||
# SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
specs=()
|
||||
for path in core apps/*; do
|
||||
if [ ! -f "$path/.noopenapi" ] && [[ "$(git check-ignore "$path")" != "$path" ]]; then
|
||||
composer exec generate-spec "$path" "$path/openapi.json" || exit 1
|
||||
if [[ "$(basename "$path")" != "core" ]]; then
|
||||
if [ -f "$path/openapi-full.json" ]; then
|
||||
specs+=("$path/openapi-full.json")
|
||||
else
|
||||
specs+=("$path/openapi.json")
|
||||
fi;
|
||||
fi;
|
||||
fi
|
||||
done
|
||||
|
||||
composer exec merge-specs -- \
|
||||
--core core/openapi-full.json \
|
||||
--merged openapi.json \
|
||||
"${specs[@]}"
|
||||
|
||||
files="$(git ls-files --exclude-standard --modified --others)"
|
||||
changed=false
|
||||
for file in $files; do
|
||||
|
|
30702
openapi.json
Normal file
30702
openapi.json
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue