diff --git a/_extras/customization.md b/_extras/customization.md index d9cc2d4f..b4ae515a 100644 --- a/_extras/customization.md +++ b/_extras/customization.md @@ -35,6 +35,25 @@ configure some site-wide variables and make the site function correctly: it will appear in the "jumbotron" (the gray box at the top of the page). This variable is also used for the title of the extra pages. The README contains [more information about extra pages](https://github.com/carpentries/workshop-template#creating-extra-pages). +### Slug Validation + +For workshops teaching a core or mix and match curriculum, i.e. +where `carpentry` is set to `swc`, `dc`, or `lc`, the website build +will check that your repository name matches the Carpentries slug +format - `YYYY-MM-DD-site[-online]`, e.g. `2024-05-07-oomza-online`. + +**If your repository name does not match this format, the build will +fail, and will direct you to rename your workshop website repository +to a valid slug.** You will then need to commit a change to the repo +to rebuild the site, e.g. adding a space or other inconsequential +change to the `README.md`. + +Workshop websites using `cp` or `incubator` will go through the same +check, but the build will not fail if the repo name does not match +the slug format. You will see a warning in the build output instead. + +### Incubator lessons + For workshops teaching lessons in The Carpentries Incubator, i.e. where `carpentry` is set to `incubator`, you should uncomment the following three fields in diff --git a/bin/workshop_check.py b/bin/workshop_check.py index e4c7178f..fb45edd7 100644 --- a/bin/workshop_check.py +++ b/bin/workshop_check.py @@ -420,7 +420,7 @@ def check_slug(reporter, filename, repo_dir): print(fail_msg.format(repo_name, slugfmt)) sys.exit(1) - elif carpentry in ('cp'): + elif carpentry in ('cp', 'incubator'): warn_msg = ( 'Website repository name `{0}` does not match the suggested slug format: `{1}`. ' 'If teaching a workshop which you are collecting surveys for or are submitting into AMY, '