File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -181,13 +181,21 @@ contents:
181181 script:
182182 - pip install mkdocs-material
183183 - mkdocs build --site-dir public
184+ cache:
185+ key: ${CI_COMMIT_REF_SLUG}
186+ paths:
187+ - .cache/ # (1)!
184188 artifacts:
185189 paths:
186190 - public
187191 rules:
188192 - if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH'
193+
189194 ```
190195
196+ 1. Some Material for MkDocs plugins use [caching] to speed up repeated
197+ builds, and store the results in the `.cache` directory.
198+
191199=== "Insiders"
192200
193201 ``` yaml
@@ -197,6 +205,10 @@ contents:
197205 script: # (1)!
198206 - pip install git+https://${GH_TOKEN}@github.com/squidfunk/mkdocs-material-insiders.git
199207 - mkdocs build --site-dir public
208+ cache:
209+ key: ${CI_COMMIT_REF_SLUG}
210+ paths:
211+ - .cache/ # (2)!
200212 artifacts:
201213 paths:
202214 - public
@@ -208,6 +220,9 @@ contents:
208220 [personal access token] when deploying [Insiders], which can be done
209221 using [masked custom variables].
210222
223+ 2. Some Material for MkDocs plugins use [caching] to speed up repeated
224+ builds, and store the results in the `.cache` directory.
225+
211226Now, when a new commit is pushed to the [ default branch] (typically ` master ` or
212227` main ` ), the static site is automatically built and deployed. Commit and push
213228the file to your repository to see the workflow in action.
You can’t perform that action at this time.
0 commit comments