]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - scripts/openapi-clients.sh
Update translations and support fa
[github/Chocobozzz/PeerTube.git] / scripts / openapi-clients.sh
index b031ceac1194be5c7776818c0f3c4a029913c622..b11d0001e2313cbb76a39e031a3e9a99f683bff7 100755 (executable)
@@ -46,6 +46,8 @@ for lang in ${API_LANGS//:/ } ; do
 (
     echo "Generating client API libs for $lang"
 
+    lang_dir="support/openapi/${lang}"
+
     out_dir_prefix="dist/api/${API_PATH_PREFIX}"
     out_dir="${out_dir_prefix}/${lang}"
     git_repo_id="${API_PATH_PREFIX}${lang}"
@@ -57,10 +59,12 @@ for lang in ${API_LANGS//:/ } ; do
         git clone "https://${host_path}" "$out_dir"
     fi
 
-    npx openapi-generator generate \
+    npx @openapitools/openapi-generator-cli generate \
         -i support/doc/api/openapi.yaml \
-        -c "support/openapi/${lang}.yaml" \
+        -c "${lang_dir}/def.yaml" \
+        -t "${lang_dir}" \
         -g "$lang" \
+        --skip-validate-spec \
         --git-host "${API_REPO_HOST}" \
         --git-user-id "${API_URL_USERNAME}" \
         --git-repo-id "${git_repo_id}" \