1 Creating a new workshop
2 =======================
4 There is a central repository for all workshops.
6 https://github.com/swcarpentry/workshop
8 The “master” branch has the current state-of-the-art source (Markdown,
9 ReST, LaTeX, …) for the instructors' projected content (HTML pages,
10 PDF slides, …), handouts, workshop homepage, …. If we can't agree on
11 a canonical representation, there may be a handful of feature branches
12 with alternative content.
14 An instructor preparing for a new workshop should create a
15 new repository on the SWC GitHub page by forking the master.
17 After the fork, they can optionally merge feature branches they like:
21 This gives a starting point for developing your workshop.
23 -o--o--o--o--o origin/master
24 \-o--o \ origin/git-wtk
27 Figure 1: Graph of commits for the beginning of the
28 2012-12-my-workshop repository. Time increases to the right.
29 Commits are marked with “o”. ASCII art connects child commits with
30 their parents. The merge of a well-maintained feature branch should
33 Topics will live in per-subject subdirectories, ideally organized in
34 half-day-sized chunks.
59 Figure 2: Example directory tree for the current 2012-12-my-workshop
60 tip. Sections should be in half-day-ish chunks. Complicated topics
61 that need more detailed coverage (e.g. version control) can have
64 Developing workshop content
65 ===========================
67 If you don't have strong ideas about the content, there's probably not
68 much to do here besides tweaking a few workshop-specific bits
69 (location, dates, master-index, …). These changes should go into the
72 -o--o--o--o--o origin/master
73 \-o--o \ origin/git-wtk
74 \------o--a--b 2012-12-my-workshop
76 Figure 2: Workshop-specific changes go into the workshop-specific
77 repository. Example log:
80 ------ -----------------------------------------------------
81 a index.rst: link to shell, git/basic, and git/advanced
82 b index.rst: localize for 2012-12 workshop at my house
84 If you want to change some of the general content, you have some
87 1. With commit rights to the central repo, go ahead and make your
88 change on the master repository. Then pull your changes into your
91 -o--o--o--o--o--a-----\ origin/master
92 \-o--o \ \ origin/git-wtk
93 \------o--o--o--b master
95 Figure 3: General changes go into their general branch. Example log:
98 ------ --------------------------------------------------
99 a git/basic: fix origin\master -> origin/master typo
100 b merge recent master branch updates
102 2. If you can't commit to the central repo, put your changes in their
103 own feature branch and make a pull request.
105 /-a----\---\ typo-fix
106 -o--o--o--o--o--------\---c origin/master
107 \-o--o \ \ origin/git-wtk
108 \------o--o--o--b master
110 Figure 4: You can't push to master, so you made a new “typo-fix”
111 branch. Later on, a SWC dev will merge it into the master
112 repository (c). The content of commits “a” and “b” is the same as
115 3. You don't like this fancy branch stuff, so you just make the commit
116 in your workshop repository. You let the SWC devs know so they can
117 cherry-pick it into the master branch.
119 -o--o--o--o--o------------d origin/master
120 \-o--o \ : origin/git-wtk
121 \------o--o--o--a master
123 Figure 5: You make the general change “a” in your workshop branch.
124 SWC devs have to cherry pick the change into the master repository
125 with “d”. This makes it awkward for other people to base work off
126 your workshop branch. It is even more awkward if you've stuffed
127 workshop-specific changes into “a”, but you can avoid that by
128 making clean commits.
130 4. If you really want to roll your own content, feel free to skip the
131 master repository entirely.
133 Publishing workshop websites
134 ============================
136 This is not really part of the workshop-branch vs. workshop-repo
137 discussion, but one benefit to the workshop-repo approach is that each
138 workshop has a gh-pages website at
140 http://<user>.github.com/<repo>
141 http://swcarpentry.github.com/2012-12-my-workshop
143 Post-workshop archival
144 ======================
146 The workshop repositories are already on the SWC GitHub page, so
147 there's nothing to do here.