How to Use GitHub to Create and Manage Markdown Files
1. Create a GitHub Account
2. Create a New Repository
A repository is like a folder for your project.
- Log in to GitHub.
- Click the "+" icon in the top right corner and select "New repository."
- Give your repository a name (like a folder name) and click "Create repository."
3. Create a Markdown File
- Go to your new repository.
- Click the "Add file" button and select "Create new file."
- Name your file. Make sure to include the
.md
extension (e.g., README.md
).
4. Write in Markdown
In the text editor that appears, write your content. Here are some basics:
-
Headings:
# Heading level 1
## Heading level 2
### Heading level 3
-
Paragraphs:
Paragraphs are formatted as blocks of plain text separated by blank lines.
This is the first sentence in paragraph 1. This is another sentence in paragraph 1.
This is the first sentence in paragraph 2. This is another sentence in paragraph 2.
-
Bold and Italics:
**Bold text**
*Italic text*
-
lists:
- list item 1
- list item 2
- nested list item 1
- nested list item 2
-
Hyperlinks:
-
Inline code:
-
A simple markdown file
Below is a simple markdown file with a heading, paragraph, and an image. The paragraph includes italicized, bolded text, and a hyperlink.
# Common Sunflower
The **common sunflower** (*Helianthus annuus*) is a species of large annual forb of the daisy family Asteraceae. The [common sunflower](https://en.wikipedia.org/wiki/Common_sunflower) is harvested for its edible oily seeds which are used in the production of cooking oil.
![Common sunflower]( https://upload.wikimedia.org/wikipedia/commons/thumb/4/40/Sunflower_sky_backdrop.jpg/217px-Sunflower_sky_backdrop.jpg)
5. Save Your File
- Scroll down to the "Commit new file" section.
- Add a short message describing your file (e.g., "Added a new Markdown file").
- Click "Commit new file."
6. Edit a Markdown File
- Open the Markdown file you want to edit in your repository.
- Click the pencil icon (✏️) in the top right of the file view.
- Make your changes in the text editor.
- Scroll down to the "Commit changes" section.
- Add a message describing your changes.
- Click "Commit changes."