Skip to content
Merged
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
888fea9
ci: update openapi build
matthewhanson Dec 9, 2020
0e9a145
ci: update dependencies and use pip to install yq
matthewhanson Dec 9, 2020
f775231
ci: fix docker image names
matthewhanson Dec 9, 2020
31b225c
ci: syntax
matthewhanson Dec 9, 2020
6e23520
ci: try install with apt
matthewhanson Dec 9, 2020
b4deb67
ci: yq append
matthewhanson Dec 9, 2020
c7994a3
ci: add swagger-config file
matthewhanson Dec 9, 2020
1f7d38c
ci: add swagger-combine
matthewhanson Dec 9, 2020
240fea1
ci: fix swagger config location
matthewhanson Dec 9, 2020
35a57dc
remove unused dependencies
matthewhanson Dec 9, 2020
18e5c7c
ci: remove install of yq
matthewhanson Dec 9, 2020
570a942
ci: minor syntax
matthewhanson Dec 9, 2020
5b0d9bc
ci: remove transaction from complete openapi
matthewhanson Dec 9, 2020
ed90258
Merge branch 'master' into dev
matthewhanson Dec 9, 2020
8992b2e
disable creating combined file
matthewhanson Dec 9, 2020
af6b7a5
Merge branch 'dev' of github.com:radiantearth/stac-api-spec into dev
matthewhanson Dec 9, 2020
dc9a135
Merge branch 'master' into dev
matthewhanson Dec 9, 2020
40dff11
restore lines in commons.yaml
matthewhanson Dec 9, 2020
2e4aaa4
Merge branch 'master' into dev
m-mohr Dec 9, 2020
edc0f9b
ci: put core openapi.yaml file at root of version in gh-pages
matthewhanson Dec 9, 2020
f11967a
Merge branch 'dev' of github.com:radiantearth/stac-api-spec into dev
matthewhanson Dec 9, 2020
6d1390c
Merge branch 'master' into dev
m-mohr Dec 9, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 22 additions & 2 deletions .circleci/build-openapi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,25 @@ FNAMES=`find . -name "openapi.yaml" -not -path "./fragments/*" -not -path "./nod
for fin in $FNAMES; do
fout=./build/$fin
mkdir -p ${fout%/*}
speccy resolve $fin > $fout
done
#speccy resolve $fin > $fout
swagger-cli bundle $fin -o $fout -t yaml
cp build/index.html ${fout%/*}/
done

cp build/core/openapi.yaml build/openapi.yaml

# use swagger-combine
#swagger-combine build/swagger-config.yaml --continueOnConflictingPaths -o build/openapi.yaml

# use openapi-merge-cli
#openapi-merge-cli -c build/openapi-merge-config.json
#json2yaml build/openapi-merge.json > build/openapi-merge.yaml

# use yq
#yq merge -a \
# build/core/openapi.yaml \
# build/item-search/openapi.yaml \
# build/ogcapi-features/openapi.yaml \
# build/ogcapi-features/extensions/transaction/openapi.yaml \
# build/ogcapi-features/extensions/version/openapi.yaml \
# | tee build/openapi-yq.yaml
20 changes: 20 additions & 0 deletions build/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<link rel="shortcut icon" href="../assets/images/favicon.png">
<title>STAC API</title>
</head>
<body>
<div id="content"></div>
<script src="https://cdn.jsdelivr.net/npm/redoc@next/bundles/redoc.standalone.js"> </script>
<script type="text/javascript">
Redoc.init('openapi.yaml', {
expandResponses:"200,201,202,203,204",
pathInMiddlePanel: true,
hideDownloadButton: true
}, document.getElementById('content'));
</script>
</body>
</html>
19 changes: 19 additions & 0 deletions build/swagger-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
openapi: 3.0.3
info:
title: STAC API - Complete
version: 1.0.0-beta.1
apis:
- url: 'build/core/openapi.yaml'
paths:
exclude:
- "^\/$"
- url: 'build/ogcapi-features/openapi.yaml'
#- url: 'build/ogcapi-features/extensions/transaction/openapi.yaml'
# dereference:
# circular: ignore
- url: 'build/item-search/openapi.yaml'
#dereference:
# circular: ignore
- url: 'build/ogcapi-features/extensions/version/openapi.yaml'
#dereference:
# circular: ignore
6 changes: 2 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,14 @@
"dependencies": {
"@stoplight/spectral": "^5.7.1",
"gh-pages": "^3.1.0",
"klaw-sync": "^6.0.0",
"redoc-cli": "^0.10.2",
"remark-cli": "^8.0.1",
"remark-lint": "^7.0.1",
"remark-lint-no-html": "^2.0.1",
"remark-preset-lint-consistent": "^3.0.1",
"remark-preset-lint-markdown-style-guide": "^3.0.1",
"remark-preset-lint-recommended": "^4.0.1",
"remark-validate-links": "^10.0.2",
"speccy": "^0.11.0",
"yaml-files": "^1.1.0"
"swagger-cli": "^4.0.4",
"swagger-combine": "^1.3.0"
}
}