Skip to content

Commit f81f5a6

Browse files
committed
refactor: re-add template
1 parent ff93107 commit f81f5a6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

.github/workflows/auto-update.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
- name: Fetch the last template version that generated the client
3636
run: echo "template_last_version=$(cat ./configs.json | jq -r '.template_last_version')" >> $GITHUB_ENV
3737
- name: Fetch the last library version
38-
run: echo "library_last_version=$(cat ./package.json | jq -r '.version')" >> $GITHUB_ENV
38+
run: echo "library_last_version=$(cat ./package.json | jq -r '.version':=0.0.0)" >> $GITHUB_ENV
3939
- name: Fetch current template version
4040
run: echo "template_current_version=$(curl -sL https://api.github.com/repos/asyncapi/ts-nats-template/releases/latest | jq -r '.tag_name' | sed 's/v//')" >> $GITHUB_ENV
4141
- name: Get all the application AsyncAPI documents
@@ -90,7 +90,7 @@ jobs:
9090
run: |
9191
contents="$(jq ".template_last_version = \"$template_current_version\" | .document_last_version = \"$document_current_version\"" configs.json)" && echo "${contents}" > configs.json
9292
- name: Write old version to package.json file as it was cleared by the generator
93-
if: ${{env.major_version_change == 'true' || env.minor_version_change == 'true' || env.patch_version_change == 'true'}}
93+
if: ${{ env.major_version_change == 'true' || env.minor_version_change == 'true' || env.patch_version_change == 'true'}}
9494
run: contents="$(jq ".version = \"$library_last_version\"" package.json)" && echo "${contents}" > package.json
9595
- name: Merge custom package file with template generated
9696
if: ${{env.major_version_change == 'true' || env.minor_version_change == 'true' || env.patch_version_change == 'true'}}

0 commit comments

Comments
 (0)