diff --git a/Gemfile b/Gemfile index 93422883..d6838e50 100755 --- a/Gemfile +++ b/Gemfile @@ -1,5 +1,6 @@ source 'https://rubygems.org' gem 'github-pages', group: :jekyll_plugins +gem 'jekyll-seo-tag' #gem 'jekyll-sass-converter' # Avoid polling for changes diff --git a/README.md b/README.md index e3330576..6e8fa74d 100644 --- a/README.md +++ b/README.md @@ -39,16 +39,19 @@ bundle exec jekyll serve ``` ## 5. Open the local site and check your changes -Open a browser and go to `localhost:4000/`. Any changes you make to any of the repository's files, except `_config.yml` will be reflected on the site after refreshing the page. +Open a browser and go to `localhost:4000/`. Any changes you make to any of the repository's files, except `_config.yml`, will be reflected on the site after refreshing the page. If you edit `_config.yml`, you will need to quit the local server (`Ctrl+C`) and rebuild the site locally in order to see your changes. # How the site is set up The structure can be a little confusing, but I'll try to outline the basics. Just to be clear, I (TS) don't know much, and everything I do know is from playing with the site for a day and a half. Still, here is goes: The different pages (e.g., News, Papers, Team) are organized in separate folders. Each folder contains a file for the page itself (`index.html`) and a folder containing markdown files with the different entries for the page (`_posts/`). Whether adding a new lab member, paper, poster, presentation, project, or piece of news, you will generally be creating one of these markdown files. -The markdown files have two sections, a header with metadata and the content below. How the post is formatted on the general page (e.g., how Taylor Salo's picture fits into the Team webpage) is determined by the `index.html` file mentioned above. How the post is formatted on its own page (e.g., Taylor Salo's member page) is determined by the theme for that post's category. Themes are saved as html files in `_includes/themes/lab/`. You can change these themes, but be aware that they will affect all other pages of the same type. For example, if you resize the photo field in the lab member theme file, then the photos of all lab members will be affected. NOTE: You might assume that the themes or similar info are in the `_layouts` folder, but that appears to be a red herring. Those pages just call the files in the `themes` folder. +The markdown files have two sections, a header with metadata and the content below. How the post is formatted on the general page (e.g., how Taylor Salo's picture fits into the [Team webpage](https://nbclab.github.io/team/)) is determined by the `index.html` file mentioned above. How the post is formatted on its own page (e.g., [Taylor Salo's member page](https://nbclab.github.io/team/taylor-salo)) is determined by the theme for that post's category. Themes are saved as html files in `_includes/themes/lab/`. You can change these themes, but be aware that they will affect all other pages of the same type. For example, if you resize the photo field in the lab member theme file, then the photos of all lab members will be affected. +- NOTE: You might assume that the themes or similar info are in the `_layouts` folder, but that appears to be a red herring. Those pages just call the files in the `themes` folder. +- Ultimately, if it is possible, we would like simplify this structure. Pictures, pdfs, etc. can be placed in `assets/`. However, because GitHub repositories are limited in terms of space, I would ultimately like to shift toward using a public Google Drive folder or something similar. +- When adding pictures of posters or presentations, please export the pdf (assuming that's what you have) to png format, and then resample to a lower resolution. For posters, we use a width of 250 pixels with whatever height scales proportionally with that, and a resolution of 72 pixels per inch. For presentations, please save just the first slide for the page thumbnail, and use a width of 1000 pixels (again, with whatever height matches this) and a resolution of 150 pixels per inch. The markdown files for the homepage, the "About the site" page, and the "Contact us" page are all located in `misc/_posts/`. I only mention this because it wasn't obvious to me when I went searching for those pages. diff --git a/_config.yml b/_config.yml index 8cb2fd67..d05674a8 100644 --- a/_config.yml +++ b/_config.yml @@ -160,5 +160,6 @@ JB : # where [HELPER] is the name of the helper you are overriding. # allow page redirection -gems: +plugins: - jekyll-redirect-from + - jekyll-seo-tag diff --git a/_includes/themes/lab/default.html b/_includes/themes/lab/default.html index 10278501..dea195fc 100755 --- a/_includes/themes/lab/default.html +++ b/_includes/themes/lab/default.html @@ -28,7 +28,7 @@ - + @@ -36,7 +36,6 @@ - + {% seo %}
diff --git a/_includes/themes/lab/member.html b/_includes/themes/lab/member.html index d2e2f20f..e9b1f9b8 100755 --- a/_includes/themes/lab/member.html +++ b/_includes/themes/lab/member.html @@ -12,7 +12,7 @@{{ pres.title }} @@ -246,8 +272,7 @@
diff --git a/_includes/themes/lab/poster_or_presentation.html b/_includes/themes/lab/poster_or_presentation.html index 8db9d129..cc5def53 100644 --- a/_includes/themes/lab/poster_or_presentation.html +++ b/_includes/themes/lab/poster_or_presentation.html @@ -20,7 +20,7 @@