Api docs update (#2676)
* fix: negate check for verbose. * fix: default version directory to latest version. * update: API changes. * update: API updated with grammar fixespull/2678/head
parent
c91cdd489d
commit
ef8c27716f
File diff suppressed because it is too large
Load Diff
|
@ -25,7 +25,7 @@
|
||||||
versionDirs=($(ls -d */))
|
versionDirs=($(ls -d */))
|
||||||
latestOSS=${versionDirs[${#versionDirs[@]}-1]}
|
latestOSS=${versionDirs[${#versionDirs[@]}-1]}
|
||||||
baseUrl="https://raw.githubusercontent.com/influxdata/openapi/master"
|
baseUrl="https://raw.githubusercontent.com/influxdata/openapi/master"
|
||||||
ossVersion=""
|
ossVersion=${latestOSS%/}
|
||||||
verbose=""
|
verbose=""
|
||||||
context=""
|
context=""
|
||||||
|
|
||||||
|
@ -65,7 +65,7 @@ case "$subcommand" in
|
||||||
baseUrl=$OPTARG
|
baseUrl=$OPTARG
|
||||||
;;
|
;;
|
||||||
o)
|
o)
|
||||||
ossVersion=${OPTARG-${latestOSS%/}}
|
ossVersion=$OPTARG
|
||||||
;;
|
;;
|
||||||
\?)
|
\?)
|
||||||
echo "Invalid option: $OPTARG" 1>&2
|
echo "Invalid option: $OPTARG" 1>&2
|
||||||
|
@ -94,7 +94,7 @@ function updateCloud {
|
||||||
|
|
||||||
function updateOSS {
|
function updateOSS {
|
||||||
echo "Updating OSS ${ossVersion} swagger..."
|
echo "Updating OSS ${ossVersion} swagger..."
|
||||||
curl ${verbose} ${baseUrl}/contracts/oss.yml -s -o ${ossVersion}/swagger.yml
|
mkdir -p ${ossVersion} && curl ${verbose} ${baseUrl}/contracts/oss.yml -s -o $_/swagger.yml
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateV1Compat {
|
function updateV1Compat {
|
||||||
|
@ -103,9 +103,10 @@ function updateV1Compat {
|
||||||
mkdir -p ${ossVersion} && cp cloud/swaggerV1Compat.yml $_/swaggerV1Compat.yml
|
mkdir -p ${ossVersion} && cp cloud/swaggerV1Compat.yml $_/swaggerV1Compat.yml
|
||||||
}
|
}
|
||||||
|
|
||||||
if [ -z ${verbose} ];
|
if [ ! -z ${verbose} ];
|
||||||
then
|
then
|
||||||
showArgs
|
showArgs
|
||||||
|
echo ""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$context" = "cloud" ];
|
if [ "$context" = "cloud" ];
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue