New site for ManKind Project Japan, currently at https://mkpjapan.github.io/
Setup Jekyll based on github pages: Jekyll
- ~/.../GitHub/mkpjapan.github.io>bundle exec jekyll serve --incremental
- Go to http://127.0.0.1:4000/
Strings for the site generally go into _data/strings.yml with a header for the section followed by strings for the section. These strings are then accessed via assign s = site.data.strings[page.foo_section].
It's done this way to allow the writers the flexibility to change the yml file without having to go through the html files themselves.
For lists which are repeated, they fall into either a subfolder or their own yml file (like testimonials / faqs) to allow changing them to be separate. Things in #_includes are essentially skeletons which just read string data from the yml files under _data.
- Go to _layouts/home.html
- Remove the section you want
- If your section was part of nav.html go to _includes\nav.html and remove it from the list there.
- Push the change.
- Create your new section in _includes. Something like MyNewSection.html
- Write out your section
- In _layouts/home.html include it like the other sections in the order you want it to appear in.
- In nav.html, add your section to the header (or not)
- You can search for the string by just searching _data for the string you're looking for
- Change the string inside of _data in the yml file you found it in
- run the site locally and see the string change.
- If you have something in static/ just move it into static/exclude. These are assets that are not used in the site, but could be used in the future.
Jekyll sites are essentially just frontend code which means the user will download nearly all assets of the site itself. Everything in the _site folder is directly downloaded to the user's machine. This means:
- All jpegs which didn't come from an online source must have their jpeg headers stripped to anonymize them
- Any face pics or identifying information must be scrutinized heavily before pushing it
- Scrub any strings in the repo for identifying information especially posts.
Because Jekyll is wholly frontend code, use of php and ajax is essentially impossible (no back end to speak of). Due to that we can't use certain things like captchas or standard fullstack technology. We should consider getting a backend eventually even if it's just to keep posts on a server.
Because _site is essentially downloaded onto a client's device the smaller the _site folder is the faster it will be so be judicious about what you put into it. Ultimately we do need to support slower speed internet if there are people who are interested from abroad.