Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
Lesson Template
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
prace-lessons
Lesson Template
Commits
e8f479a9
Commit
e8f479a9
authored
8 years ago
by
Greg Wilson
Browse files
Options
Downloads
Patches
Plain Diff
Explaining how to set up for lesson development
parent
56e4be9a
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
CONTRIBUTING.md
+2
-0
2 additions, 0 deletions
CONTRIBUTING.md
_episodes/01-tooling.md
+11
-16
11 additions, 16 deletions
_episodes/01-tooling.md
setup.md
+8
-3
8 additions, 3 deletions
setup.md
with
21 additions
and
19 deletions
CONTRIBUTING.md
+
2
−
0
View file @
e8f479a9
...
...
@@ -111,6 +111,8 @@ and have final say over what gets merged into the lesson.
[
This documentation
][
example-site
]
explains how we format our lessons
(and is itself an example of that formatting).
The episode on tooling explains
[
how to check and preview changes
](
{{
site.root }}/01-tooling/#checking-and-previewing).
## Other Resources
...
...
This diff is collapsed.
Click to expand it.
_episodes/01-tooling.md
+
11
−
16
View file @
e8f479a9
...
...
@@ -168,26 +168,17 @@ we store files that appear directly in the navigation bar
in the root directory of the lesson.
[The last episode]({{ site.root }}/03-organization/) describes these files.
##
Install
ing
##
Checking and Preview
ing
You can preview changes by pushing to the `gh-pages` branch of your own repository,
but it's often easier to view them locally first.
To do that,
you will need to install [Jekyll][jekyll] and a few other packages used by GitHub Pages.
The easiest way to do that is:
1. Install Ruby if you don't already have it.
2. Install Ruby Gems (Ruby's package manager).
3. `gem install github-pages` (which will give you Jekyll and things it depends on).
See [the Jekyll installation documentation][jekyll-install]
for full instructions.
## Previewing
The lesson template includes a Python program to check
whether lesson files conform to our template.
You can run this using `make lesson-check`.
It relies on a small Ruby script that uses Jekyll's own Markdown parser (called Kramdown)
so that we are guaranteed to be checking the same dialect of Markdown that Jekyll uses on GitHub.
[Jekyll][jekyll] can be used in two ways:
to compile source files into HTML pages in the `_site` directory,
or to do that and also run a small web server at <http://
127
.0.0.
1
:4000/>
or to do that and also run a small web server at <http://
0
.0.0.
0
:4000/>
so that the pages can be previewed.
We recommend using the latter,
since it gives a more accurate impression of what your lesson will actually look like.
...
...
@@ -198,6 +189,10 @@ while `make serve` builds the files and runs a server.
(It also re-builds the site whenever it notices changes in the source files.)
Run `make` on its own to get a full list of commands.
In order to use Jekyll and/or the checking script,
you may need to install it and some other software.
The [setup instructions]({{ site.root }}/setup/) explain what you need and how to get it.
[github-importer]: https://import.github.com/
[jekyll]: http://jekyllrb.com/
[jekyll-collection]: https://jekyllrb.com/docs/collections/
...
...
This diff is collapsed.
Click to expand it.
setup.md
+
8
−
3
View file @
e8f479a9
...
...
@@ -3,14 +3,17 @@ layout: page
title
:
Setup
permalink
:
/setup/
---
## Setup Instructions for Actual Lessons
1.
Installation instructions for core lessons are included in the
[
workshop template's home page
][
template
]
,
so that they are all in one place.
The
`setup.md`
files of core lessons link to the appropriate sections of the
[
workshop template page
][
template
]
.
The
`setup.md`
files of core lessons link to
the appropriate sections of the
[
workshop template page
][
{{ site.workshop_repo }}
]
.
2.
Other lessons'
`setup.md`
include full installation instructions organized by OS
(following the model of the workshop template home page).
--------
## Setting Up for Lesson Development
If you want to set up Jekyll
so that you can preview changes on your own machine before pushing them to GitHub,
...
...
@@ -31,4 +34,6 @@ you must install the software described below.
3.
**[Jekyll](https://jekyllrb.com/)**
.
You can install this by running
`gem install jekyll`
.
[
template
]:
{{
site.workshop_repo }}
If you want to run
`bin/check-lesson`
(which is invoked by
`make lesson-check`
)
you will need Jekyll (so that you have its Markdown parser, which is called Kramdown)
and the
[
PyYAML
](
https://pypi.python.org/pypi/PyYAML
)
module for Python 3.
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment