Skip to content

Commit a8c5c65

Browse files
committed
ci: fix update zkevm api workflow
1 parent 4c90782 commit a8c5c65

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

.github/workflows/update-zkevm-api-package.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,18 +26,18 @@ jobs:
2626
- name: Download remote openapi.json
2727
run: curl -o openapi.json https://imx-openapiv3-mr-sandbox.s3.us-east-2.amazonaws.com/openapi.json
2828

29-
- name: Ensure local openapi.yaml exists (if not, assume it's blank)
29+
- name: Ensure local openapi.json exists (if not, create an empty one)
3030
run: |
31-
if [ ! -f ./src/Packages/ZkEvmApi/api~/openapi.yaml ]; then
32-
echo "Creating empty openapi.yaml file..."
31+
if [ ! -f ./src/Packages/ZkEvmApi/api~/openapi.json ]; then
32+
echo "Creating empty openapi.json file..."
3333
mkdir -p ./src/Packages/ZkEvmApi/api~
34-
touch ./src/Packages/ZkEvmApi/api~/openapi.yaml
34+
echo "{}" > ./src/Packages/ZkEvmApi/api~/openapi.json
3535
fi
3636
37-
- name: Compare openapi.json with openapi.yaml
37+
- name: Compare openapi.json files
3838
id: comparison
3939
run: |
40-
if diff openapi.json ./src/Packages/ZkEvmApi/api~/openapi.yaml > /dev/null; then
40+
if diff openapi.json ./src/Packages/ZkEvmApi/api~/openapi.json > /dev/null; then
4141
echo "::set-output name=difference::false"
4242
else
4343
echo "::set-output name=difference::true"
@@ -67,6 +67,7 @@ jobs:
6767
cp -r ./ZkEvmApi/api/* ./src/Packages/ZkEvmApi/api~/
6868
cp -r ./ZkEvmApi/docs/* ./src/Packages/ZkEvmApi/Documentation~/
6969
cp -r ./ZkEvmApi/src/Immutable.Api.ZkEvm/* ./src/Packages/ZkEvmApi/Runtime/
70+
cp openapi.json ./src/Packages/ZkEvmApi/api~/openapi.json
7071
7172
# Remove .meta files that do not have corresponding files
7273
for dir in ./src/Packages/ZkEvmApi/Runtime; do

0 commit comments

Comments
 (0)