From 21fc6d0c186c4359a5ea341fe8c444de9b7efd5c Mon Sep 17 00:00:00 2001 From: Simon Thulbourn Date: Tue, 20 Jun 2023 13:48:51 +0000 Subject: [PATCH] fix(docs): upload versions.json --- .github/workflows/reusable-publish-docs.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/reusable-publish-docs.yml b/.github/workflows/reusable-publish-docs.yml index 2f53f9049d..be135d2443 100644 --- a/.github/workflows/reusable-publish-docs.yml +++ b/.github/workflows/reusable-publish-docs.yml @@ -125,4 +125,16 @@ jobs: run: | aws s3 sync \ site/ \ - s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-typescript/${{ env.ALIAS }}/ \ No newline at end of file + s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-typescript/${{ env.ALIAS }}/ + - name: Deploy Docs (Version JSON) + env: + VERSION: ${{ inputs.version }} + ALIAS: ${{ inputs.alias }} + run: | + aws s3 cp \ + s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-typescript/versions.json \ + versions_old.json + jq '. += [{"version": "${{ env.VERSION }}", "title": "${{ env.VERSION }}", "aliases": []}]' < versions_old.json > versions.json + aws s3 cp \ + versions.json \ + s3://${{ secrets.AWS_DOCS_BUCKET }}/lambda-typescript/versions.json \ No newline at end of file