Markdown (in a few minutes)
Markdown is a standard to simplify writing content for the web. A handful of simple conventions translate into the basic HTML elements, making it quick to write and edit. Markdown can be used any where on GitHub, in popular static site generators such as Jekyll, and to create documents using Pandoc or a Markdown editor.
Create a Markdown File
Create a new file in the repo:
- Click “Create new file” button on the repository page
- Type
about.md
in the name box - Click into the editor
- Write some Markdown!
- Scroll to the bottom, add a message, and click Commit new file. (You just used Git again!)
- Behold lovely rendered Markdown on GitHub…
# Heading One
## Heading Two
### Heading Three, etc.
Any text with no empty lines between will become a paragraph.
Leave an empty line between headings and paragraphs.
Font can be *Italic* or **Bold**.
Code can be highlighted with `backticks`.
Hyperlinks look like this [GitHub Help](https://help.github.com/).
Images look similar:
![alt text here](https://upload.wikimedia.org/wikipedia/commons/4/4b/Focus_ubt.jpeg)
A bullet list is created using `*`, `+`, or `-`, like:
- dog
- cat
- muffin
A numbered list is created using a number + `.`, like:
1. one
2. two
6. three
2. four
----
Heading One
Heading Two
Heading Three, etc.
Any text with no empty lines between will become a paragraph.
Leave an empty line between headings and paragraphs.
Font can be Italic or Bold.
Code can be highlighted with backticks
.
Hyperlinks look like this GitHub Help. Images look similar:
A bullet list is created using *
, +
, or -
, like:
- dog
- cat
- muffin
A numbered list is created using a number + .
, like:
- one
- two
- three
- four
Jekyll?
Visit your index.html
on your new site and click the link to about.html
.
Notice that your about.md
has been converted into about.html
and put in a fancy HTML template?
Behind the scene, gh-pages is running Jekyll static site generator. Jekyll automatically converted your Markdown into a lovely web page using a builtin theme. This website is created in the same way: content written in basic markdown is converted into the incredibly beautiful pages you see here by the workshop-template-b theme.
Resources
- GitHub Guide Mastering Markdown
- GitHub markdown flavor
- Dillinger, online Markdown editor
- Pandoc, utility to convert between formats, such as Markdown to PDF or DOCX.