Skip to content

Commit 8e69c54

Browse files
authored
chore: Move jazzy doc generation to a separate job (#1680)
1 parent 521e9ba commit 8e69c54

File tree

2 files changed

+20
-7
lines changed

2 files changed

+20
-7
lines changed

.circleci/config.yml

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -84,12 +84,6 @@ commands:
8484
- store_artifacts:
8585
path: artifacts
8686

87-
generate_api_docs:
88-
description: generate API documentation using jazzy
89-
steps:
90-
- run:
91-
name: Jazzy API doc gen
92-
command: bash ~/amplify-ios/CircleciScripts/jazzy_doc_gen.sh
9387

9488
jobs:
9589
checkout_code:
@@ -210,6 +204,16 @@ jobs:
210204
path: build/reports
211205
- upload_artifacts
212206

207+
generate_api_docs:
208+
<<: *defaults
209+
steps:
210+
- *restore_repo
211+
- restore_gems
212+
- check_bundle
213+
- run:
214+
name: Jazzy API doc generation
215+
command: bash ~/amplify-ios/CircleciScripts/jazzy_doc_gen.sh
216+
213217
deploy:
214218
<<: *defaults
215219
parameters:
@@ -228,7 +232,6 @@ jobs:
228232
name: Release pods
229233
command: bundle exec fastlane << parameters.lane >>
230234
no_output_timeout: 60m
231-
- generate_api_docs
232235

233236
deploy_requires: &deploy_requires
234237
requires:
@@ -331,3 +334,12 @@ workflows:
331334
branches:
332335
only:
333336
- release
337+
- generate_api_docs:
338+
name: Generate api documentation
339+
requires:
340+
- deploy stable
341+
filters:
342+
branches:
343+
only:
344+
- release
345+

CircleciScripts/jazzy_doc_gen.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ generate_docs() {
1717
git checkout gh-pages
1818
git reset --hard origin/release
1919
pod install
20+
gem install -n /usr/local/bin jazzy
2021
jazzy && ln -s ../readme-images docs
2122
git add docs
2223
git commit -m "chore: update API docs [skip ci]"

0 commit comments

Comments
 (0)