Skip to content

Commit acee85a

Browse files
committed
build: fix scripts for m1 macs
Signed-off-by: Timo Glastra <timo@animo.id>
1 parent 29dbd2d commit acee85a

File tree

4 files changed

+12
-2
lines changed

4 files changed

+12
-2
lines changed

generator/README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,11 @@ cd aries-cloudcontroller/generator
3232
./scripts/retrieve-openapi.sh py36-1.16-1_0.7.0
3333

3434
# transform to OpenAPI V3
35-
./scripts/convert-to-openapi3.sh
35+
./scripts/convert-to-openapi3-local.sh
36+
37+
# If the transform script is not working (e.g. does't work on M1 macs), you can also use an online converter
38+
# This will upload the content to the cloud however
39+
# ./scripts/convert-to-openapi3-remote.sh
3640

3741
# Fix the openapi file (add missing operation ids from data/operation-id-map.yml)
3842
./scripts/process-openapi.sh

generator/scripts/convert-to-openapi3.sh renamed to generator/scripts/convert-to-openapi3-local.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@ while [[ "$(curl -s -o /dev/null -w ''%{http_code}'' localhost:8080)" != "200" ]
1111
echo "Converter not yet ready..."
1212
sleep 1
1313
done
14+
1415
curl -X POST http://localhost:8080/api/convert -H "Content-Type: application/json" -H "Accept: application/yaml" --data-binary "@../data/swagger.json" -o ../data/openapi.yml
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env bash
2+
3+
cd "$(dirname "$0")" || exit
4+
5+
curl -X POST https://converter.swagger.io/api/convert -H "Content-Type: application/json" -H "Accept: application/yaml" --data-binary "@../data/swagger.json" -o ../data/openapi.yml

generator/scripts/create-patch.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
cd "$(dirname "$0")" || exit
44

55
cp ../data/openapi.yml ../data/openapi-updated.yml
6-
sh ./convert-to-openapi3.sh
6+
sh ./convert-to-openapi3-remote.sh
77
sh ./process-openapi.sh
88

99
cd ..

0 commit comments

Comments
 (0)