Skip to content

Commit 072fa75

Browse files
committed
fix: syntax error
1 parent 86d8f40 commit 072fa75

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

.github/workflows/swagger_ui_v2.yml

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -116,29 +116,29 @@ jobs:
116116
mkdir -p "$OUTPUT_ROOT/schemas"
117117
cp -R $JSON_SCHEMA_PATH/*.json $OUTPUT_ROOT/schemas/
118118
119+
- name: Generate resource list
120+
shell: bash
121+
run: |
122+
echo "Generating resource list dynamically..."
123+
schema_dir="$OUTPUT_ROOT/schemas"
124+
swagger_dir="$OUTPUT_ROOT/swagger-ui"
125+
repo_name=${GITHUB_REPOSITORY##*/}
126+
site_url="https://${GITHUB_REPOSITORY_OWNER}.github.io/${repo_name}"
127+
128+
echo "---"
129+
for file in "$schema_dir"/*.json; do
130+
base=$(basename "$file" .json)
131+
echo "**${base}**"
132+
echo "- [Schema](${site_url}/${deploy_dir}/schemas/${base}.json)"
133+
echo "- [Swagger document](${site_url}/${deploy_dir}/swagger-ui/${base}/)"
134+
echo ""
135+
done
136+
echo "---"
137+
echo "Done. See the resource list above."
138+
119139
- name: Deploy to GitHub Pages
120140
uses: peaceiris/actions-gh-pages@v4
121141
with:
122142
github_token: ${{ secrets.GITHUB_TOKEN }}
123143
publish_dir: ${{ env.OUTPUT_ROOT }}
124-
destination_dir: ${{ env.OUTPUT_ROOT }}
125-
126-
- name: Generate resource list
127-
shell: bash
128-
run: |
129-
echo "Generating resource list dynamically..."
130-
schema_dir="$OUTPUT_ROOT/schemas"
131-
swagger_dir="$OUTPUT_ROOT/swagger-ui"
132-
repo_name=${GITHUB_REPOSITORY##*/}
133-
site_url="https://${GITHUB_REPOSITORY_OWNER}.github.io/${repo_name}"
134-
135-
echo "---"
136-
for file in "$schema_dir"/*.json; do
137-
base=$(basename "$file" .json)
138-
echo "**${base}**"
139-
echo "- [Schema](${site_url}/${deploy_dir}/schemas/${base}.json)"
140-
echo "- [Swagger document](${site_url}/${deploy_dir}/swagger-ui/${base}/)"
141-
echo ""
142-
done
143-
echo "---"
144-
echo "Done. See the resource list above."
144+
destination_dir: ${{ env.OUTPUT_ROOT }}

0 commit comments

Comments
 (0)