Skip to content

Commit eb05374

Browse files
committed
📝 more detailed
1 parent 703e87b commit eb05374

File tree

1 file changed

+68
-35
lines changed

1 file changed

+68
-35
lines changed

README.md

Lines changed: 68 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,22 @@ Jekyll is a static site generator that takes care of updating a site template wi
66

77
The site template is [Hyde (see repo for more details)](https://github.com/poole/hyde) with some of our own modifications.
88

9-
Included are instructions for how to update the team website with a focus on the content rather than formating.
9+
Included are instructions for how to update the team website with a focus on the content rather than styling.
1010

1111
- [MoNA website](#mona-website)
12-
- [Contents](#contents)
13-
- [Directory organization](#directory-organization)
12+
- [Directory organization](#directory-organization)
13+
- [MUST READ - how jekyll works](#must-read---how-jekyll-works)
1414
- [Home page (default) vs. all other pages](#home-page-default-vs-all-other-pages)
15-
- [Adding a page (example)](#adding-a-page-example)
16-
- [Updating an existing page](#updating-an-existing-page)
17-
- [Updating side nav links](#updating-side-nav-links)
18-
- [Testing locally](#testing-locally)
15+
- [Updating website content](#updating-website-content)
16+
17+
- [Adding a page (example)](#adding-a-page-example)
18+
- [Updating an existing page](#updating-an-existing-page)
19+
- [Updating side nav links](#updating-side-nav-links)
20+
- [Testing locally](#testing-locally)
1921
- [Original Author](#original-author)
2022
- [License](#license)
2123

22-
## Contents
23-
24-
### Directory organization
24+
## Directory organization of Repo
2525

2626
(only highlighting folders and files relevant to updating site)
2727

@@ -49,37 +49,70 @@ Included are instructions for how to update the team website with a focus on the
4949

5050
```
5151

52-
- Main takeaway: To update the contents of the website you will only need to add/remove/update markdown files in the main directory.
52+
## MUST READ - how jekyll works
5353

54-
- To incorporate images or any other files into the site please put them in `/public/assets/`
54+
1. How jekyll knows to work its magic on a markdown or html file is based on the file's [YAML front matter block](https://jekyllrb.com/docs/front-matter/).
5555

56-
- Extra: Updates to formating is done in the 3 directories: `/_includes/` `/_layouts/` and `/_public/`
56+
e.g.,
57+
```
58+
---
59+
layout: page
60+
title: About
61+
permalink: /about/
62+
---
63+
```
64+
- **no front matter = not included in the website** (e.g., jekyll knows not to include this README.md you are reading because there is no front matter)
65+
66+
2. Main takeaway: To update the **contents of the website** you will only need to add/remove/update the markdown files with front matter in the main directory. (e.g., [3people.md](3people.md)) More instructions in [Updating website content](#updating-website-content).
5767

58-
### Home page (default) vs. all other pages
68+
- **Do not alter the files in `_includes`, `_layouts` for now.**
69+
70+
#### Home page (default) vs. all other pages
5971

6072
- How jekyll knows to work its magic on a markdown or html file is based on the file's [YAML front matter block](https://jekyllrb.com/docs/front-matter/).
6173

62-
- no front matter = not included in the website (e.g., this readme)
63-
6474
- Currently, there are 2 page layouts (templates) used in our site:
65-
- `/_layouts/default.html`
66-
- `/_layouts/page.html`
75+
- `default` via */_layouts/default.html*
76+
- `page` via */_layouts/page.html`*
6777

68-
- The way that they are merged with the markdown files is via the front matter:
78+
- The way that the styling is merged with the markdown files is via `layout` in the front matter:
79+
e.g.,
80+
```
81+
---
82+
layout: page
83+
title: About
84+
permalink: /about/
85+
---
86+
```
6987

70-
```
71-
---
72-
layout: page
73-
title: About
74-
permalink: /about/
75-
---
76-
```
88+
- `layout: page` is to be used for almost all of the pages you want included in the site
89+
90+
- `layout: default` is only used for the home page [index.md](index.md) because it has some additional formatting + appears as the first option in the top menu bar
91+
92+
>From the Hyde repo: "**Why require a specific layout?** Jekyll will return *all* pages, including the `atom.xml`, and with an alphabetical sort order. To ensure the first link is *Home*, we exclude the `index.md` page from this list by specifying the `default` layout."
93+
94+
95+
## Updating website content
96+
97+
- To update the contents of the website you will only need to add/remove/update markdown files in the main directory.
98+
99+
- To incorporate images or any other files into the site please put them in `/public/assets/`
100+
101+
102+
#### Updating an existing page
103+
104+
1. Clone this repository
105+
2. Create a branch from the 'master' branch of THIS repository (not the poole/hyde one)
106+
3.
107+
108+
- In the main directory, open the markdown file
109+
- make whatever changes to the content you want
110+
- save it and push changes
111+
112+
(it's that easy :smiley:)
77113

78-
- `layout: default` should only be used for the home page because it has some additional formatting + appears as the first option in the top menu bar
79114

80-
>From the Hyde repo: "**Why require a specific layout?** Jekyll will return *all* pages, including the `atom.xml`, and with an alphabetical sort order. To ensure the first link is *Home*, we exclude the `index.md` page from this list by specifying the `default` layout."
81115

82-
- `layout: page` is used for all other pages you want included in the site. More instructions for adding a new page below.
83116

84117
#### Adding a page (example)
85118

@@ -108,20 +141,20 @@ permalink: /contact/
108141

109142
- when done save and push changes, jekyll will take care of the rest
110143

111-
#### Updating an existing page
112144

113-
- In the main directory, open the markdown file
114-
- make whatever changes to the content you want
115-
- save it and push changes
116-
117-
(it's that easy :smiley:)
145+
## Updating the styling
146+
147+
- Extra: Updates to formating is done in the 3 directories: `/_includes/` `/_layouts/` and `/_public/`
118148

119149
### Updating side nav links
120150

121151
The file that needs to be updated is `/_inclues/sidebar.html`
122152

123153
Look for the `sidebar-nav-item` tags
124154

155+
156+
157+
125158
### Testing locally
126159

127160
If you want to test/preview the site locally as you make changes

0 commit comments

Comments
 (0)