Skip to content

Commit 34db8f3

Browse files
committed
markdown source builds
Auto-generated via `{sandpaper}` Source : 6121b43 Branch : main Author : Robert Davey <robertdavey@carpentries.org> Time : 2024-12-03 10:36:47 +0000 Message : Merge pull request #218 from carpentries/tobyhodges-patch-2 Add instructions for configuring SANDPAPER_WORKFLOW post-transition
1 parent 3afd592 commit 34db8f3

File tree

4 files changed

+455
-2
lines changed

4 files changed

+455
-2
lines changed

config.yaml

Lines changed: 92 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,92 @@
1+
#------------------------------------------------------------
2+
# Values for this lesson.
3+
#------------------------------------------------------------
4+
5+
# Which carpentry is this (swc, dc, lc, or cp)?
6+
# swc: Software Carpentry
7+
# dc: Data Carpentry
8+
# lc: Library Carpentry
9+
# cp: Carpentries (to use for instructor traning for instance)
10+
carpentry: 'cp'
11+
12+
# Overall title for pages.
13+
title: 'Introduction to The Carpentries Workbench'
14+
15+
# Date the lesson was created (this is empty by default)
16+
created: ~
17+
18+
# Comma-separated list of keywords for the lesson
19+
keywords: 'static site, lesson template, markdown, R, software'
20+
21+
# Life cycle stage of the lesson
22+
# possible values: pre-alpha, alpha, beta, stable
23+
life_cycle: 'beta'
24+
25+
# License of the lesson
26+
license: 'CC-BY 4.0'
27+
28+
# Link to the source repository for this lesson
29+
source: 'https://github.com/carpentries/sandpaper-docs/'
30+
31+
# Default branch of your lesson
32+
branch: 'main'
33+
34+
# Who to contact if there are any issues
35+
contact: 'tobyhodges@carpentries.org'
36+
37+
# Navigation ------------------------------------------------
38+
#
39+
# Use the following menu items to specify the order of
40+
# individual pages in each dropdown section. Leave blank to
41+
# include all pages in the folder.
42+
#
43+
# Example -------------
44+
#
45+
# episodes:
46+
# - introduction.md
47+
# - first-steps.md
48+
#
49+
# learners:
50+
# - setup.md
51+
#
52+
# instructors:
53+
# - instructor-notes.md
54+
#
55+
# profiles:
56+
# - one-learner.md
57+
# - another-learner.md
58+
59+
# Order of episodes in your lesson
60+
episodes:
61+
- introduction.md
62+
- episodes.Rmd
63+
- editing.md
64+
- example.Rmd
65+
- deployment.md
66+
- update.md
67+
- pull-request.md
68+
69+
# Information for Learners
70+
learners:
71+
- reference.md
72+
- setup.md
73+
- github-pat.md
74+
- component-guide.md
75+
- migrating-from-styles.md
76+
- style.md
77+
78+
# Information for Instructors
79+
instructors:
80+
- instructor-notes.md
81+
82+
# Learner Profiles
83+
profiles:
84+
- maintainer.md
85+
- instructor.md
86+
87+
# Customisation ---------------------------------------------
88+
#
89+
# This space below is where custom yaml items (e.g. pinning
90+
# sandpaper and varnish versions) should live
91+
92+

md5sum.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"learners/setup.md" "61754cdfdaa08ff73f388fea6c5c9522" "site/built/setup.md" "2024-12-03"
1717
"learners/github-pat.md" "65a2c6f46233a1335a6fc0392cb8a405" "site/built/github-pat.md" "2024-12-03"
1818
"learners/component-guide.md" "77bc5292747a4d06561e1e27861585cc" "site/built/component-guide.md" "2024-12-03"
19-
"learners/migrating-from-styles.md" "68dd61e4d88734fbf0ce9d3237080ebc" "site/built/migrating-from-styles.md" "2024-12-03"
19+
"learners/migrating-from-styles.md" "d754b5c0b53823ade2b7a7e5eb4f20a9" "site/built/migrating-from-styles.md" "2024-12-03"
2020
"learners/style.md" "59a4d847201ced45d9b78b8ec9b05993" "site/built/style.md" "2024-12-03"
2121
"profiles/maintainer.md" "2a2b790c0aa8da5fb72e323e4fafabd9" "site/built/maintainer.md" "2024-12-03"
2222
"profiles/instructor.md" "ff8c586028a5e1c7ef0be4178b40417c" "site/built/instructor.md" "2024-12-03"

migrating-from-styles.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,13 @@ The script is run on the version of the Workbench lesson created by the transiti
8484
8585
It is sufficient to create an empty file, named appropriately. This is available in the add-lesson.sh file, which will also provide hints about how the data can be transformed.
8686
87+
::::::::::::::::::::::::::::::::::::::: caution
88+
89+
It is essential that you do not include a trailing `/` after YOUR-LESSON-NAME below.)
90+
91+
:::::::::::::::::::::::::::::::::::::::::::::::
92+
93+
8794
```bash
8895
bash add-lesson.sh carpentries-incubator/YOUR-LESSON-NAME
8996
```
@@ -215,7 +222,19 @@ After you have transitioned your lesson, you should:
215222
216223
1. **Delete and re-create any forks and local clones** of your lesson project, to minimise the likelihood that you will accidentally push the old project history back to the GitHub repository. If you have any collaborators and fellow lesson developers/maintainers, ask them to do the same.
217224
2. If your lesson is in The Carpentries Incubator, [**tell the Curriculum Team**](mailto:curriculum@carpentries.org) that you have completed the transition so that we can activate the automated creation of pull requests to update the Workbench infrastructure when new versions of the packages are released.
218-
3. (Optional, but highly recommended) Open a pull request to https://github.com/carpentries/reactables/ to **add the invalid commit hash** (in the `invalid.hash` file created for your lesson during the transition (step 3 above)) to [the `workbench/invalid-hashes.json` file](https://github.com/carpentries/reactables/blob/main/workbench/invalid-hashes.json). This will include the hash in the data feed used by our infrastructure to support the GitHub Actions workflow that will automatically close any pull requests opened to your repository from a branch containing the old project history. To do this:
225+
3. If your lesson is _not_ in the Incubator, **enable automated pull requests to keep your infrastructure updated** by adding a SANDPAPER_WORKFLOW token to your repository:
226+
* Navigate to <https://github.com/settings/tokens/new> and give your new token a name (e.g. "Sandpaper Token (YOUR-ORG-OR-USER-NAME/YOUR-LESSON-NAME)").
227+
* Check the box next to _workflow_.
228+
* Set an expiry date for the token.
229+
* Select _Generate token_.
230+
* Copy the token displayed on the screen.
231+
* On your GitHub repository:
232+
* Navigate to Settings->Secrets and variables->Actions->New repository secret
233+
* Set _Name_ to SANDPAPER_WORKFLOW, and paste your new token into the _Secret_ box.
234+
* Select Add secret
235+
236+
The maintenance workflows that use this token are scheduled to run weekly. When The Carpentries releases new versions of the workflow files used to build and maintain lessons, a pull request will be opened automatically on any repository with the SANDPAPER_WORKFLOW token set to incorporate the relevant updates. If your lesson uses R Markdown source files, the same token will be used to keep the package dependencies for your lesson updated.
237+
5. (Optional, but highly recommended) Open a pull request to https://github.com/carpentries/reactables/ to **add the invalid commit hash** (in the `invalid.hash` file created for your lesson during the transition (step 3 above)) to [the `workbench/invalid-hashes.json` file](https://github.com/carpentries/reactables/blob/main/workbench/invalid-hashes.json). This will include the hash in the data feed used by our infrastructure to support the GitHub Actions workflow that will automatically close any pull requests opened to your repository from a branch containing the old project history. To do this:
219238
* Make a fork of [the `carpentries/reactables` GitHub repository](https://github.com/carpentries/reactables/)
220239
* On a new branch of that fork, edit the `workbench/invalid-hashes.json` file, adding a new line before the final `}` line matching the format of the other lines containing hashes, i.e.
221240
`"carpentries-incubator/YOUR-LESSON-NAME": "HASHASHASHASHASHASHASH"`

0 commit comments

Comments
 (0)