Move gh-pages
branch files into /docs
and add test files
- Jekyll ignore `/docs` and `/test` folders when using from root - Update Staticman config to point to correct branch and data file location - Replace `{{ base_path }}` references with `absolute_url` filter - Update documentation
This commit is contained in:
parent
8ed97862e5
commit
57a4324fa0
570 changed files with 22895 additions and 84 deletions
20
README.md
20
README.md
|
@ -25,7 +25,7 @@ See what's new in the [CHANGELOG](CHANGELOG.md).
|
|||
- Optional [header images](https://mmistakes.github.io/minimal-mistakes/docs/layouts/#headers), [custom sidebars](https://mmistakes.github.io/minimal-mistakes/docs/layouts/#sidebars), [table of contents](https://mmistakes.github.io/minimal-mistakes/docs/helpers/#table-of-contents), [galleries](https://mmistakes.github.io/minimal-mistakes/docs/helpers/#gallery), related posts, [breadcrumb links](https://mmistakes.github.io/minimal-mistakes/docs/configuration/#breadcrumb-navigation-beta), [navigation lists](https://mmistakes.github.io/minimal-mistakes/docs/helpers/#navigation-list), and more.
|
||||
- Commenting support (powered by [Disqus](https://disqus.com/), [Facebook](https://developers.facebook.com/docs/plugins/comments), Google+, [Discourse](https://www.discourse.org/), static-based via [Staticman](https://staticman.net/), and custom).
|
||||
- [Google Analytics](https://www.google.com/analytics/) support.
|
||||
- UI localized text in English (default), Brazilian Portguese, Chinese, French, German, Italian, Spanish, and Turkish
|
||||
- UI localized text in English (default), Brazilian Portuguese, Chinese, French, German, Italian, Spanish, and Turkish
|
||||
|
||||
## Demo Pages
|
||||
|
||||
|
@ -39,7 +39,7 @@ See what's new in the [CHANGELOG](CHANGELOG.md).
|
|||
| [Categories Archive][categories-archive] | Posts grouped by category. |
|
||||
| [Tags Archive][tags-archive] | Posts grouped by tags. |
|
||||
|
||||
For even more demo pages check the [posts archive][year-archive] on the demo site. Looking for the source code to peep the YAML Front Matter and Markdown used? Check the [`gh-pages`](https://github.com/mmistakes/minimal-mistakes/tree/gh-pages) branch.
|
||||
Additional sample posts are available under [posts archive][year-archive] on the demo site. Source files for these (and the entire demo site) can be found in [`/docs`](docs).
|
||||
|
||||
[header-image-post]: https://mmistakes.github.io/minimal-mistakes/layout-header-image-text-readability/
|
||||
[gallery-post]: https://mmistakes.github.io/minimal-mistakes/post%20formats/post-gallery/
|
||||
|
@ -50,6 +50,12 @@ For even more demo pages check the [posts archive][year-archive] on the demo sit
|
|||
[tags-archive]: https://mmistakes.github.io/minimal-mistakes/tags/
|
||||
[year-archive]: https://mmistakes.github.io/minimal-mistakes/year-archive/
|
||||
|
||||
## Usage
|
||||
|
||||
For detailed instructions on how to configure, customize, add content, and more read the [theme's documentation](https://mmistakes.github.io/minimal-mistakes/docs/quick-start-guide/).
|
||||
|
||||
**Note:** Gem version of the theme requires Jekyll v3.3+ and is not currently supported on [GitHub Pages](https://pages.github.com/). You can still use the theme with GitHub Pages, you'll just need to install using the old "[repo fork method](https://mmistakes.github.io/minimal-mistakes/docs/installation/)".
|
||||
|
||||
## Quick Start
|
||||
|
||||
Add this line to your Jekyll site's `Gemfile`:
|
||||
|
@ -64,17 +70,13 @@ Add this line to your Jekyll site's `_config.yml` file:
|
|||
theme: minimal-mistakes-jekyll
|
||||
```
|
||||
|
||||
Run Bundler:
|
||||
Then run Bundler to install the theme gem and dependencies:
|
||||
|
||||
```bash
|
||||
bundle install
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
For detailed instructions on how to configure, customize, add content, and more read the [theme's documentation](https://mmistakes.github.io/minimal-mistakes/docs/quick-start-guide/).
|
||||
|
||||
**Note:** Gem version of the theme requires Jekyll v3.3+ and is not supported with sites hosted with [GitHub Pages](https://pages.github.com/). You can still use the theme on GitHub Pages, you'll just need to install using the old "[repo fork method](https://mmistakes.github.io/minimal-mistakes/docs/installation/)".
|
||||
To update the theme run `bundle update`.
|
||||
|
||||
---
|
||||
|
||||
|
@ -90,7 +92,7 @@ This goes for author sidebar links and "share button" additions -- I have no int
|
|||
|
||||
To help me out try to avoid creating pull requests on `master` and instead branch off of `develop`. It's much easier for me to test, merge, and roll them into new releases this way.
|
||||
|
||||
Theme documentation and demo pages can be found in the `gh-pages` branch, please submit pull requests against that branch.
|
||||
Theme documentation and demo pages can be found in the [`/docs`](docs) if submitting improvements, typo corrections, etc.
|
||||
|
||||
---
|
||||
|
||||
|
|
|
@ -30,12 +30,12 @@ comments:
|
|||
colorscheme : # "light" (default), "dark"
|
||||
staticman:
|
||||
allowedFields : ['name', 'email', 'url', 'message']
|
||||
branch : # "master", "gh-pages"
|
||||
branch : "master"
|
||||
commitMessage : "New comment."
|
||||
filename : comment-{@timestamp}
|
||||
format : "yml"
|
||||
moderation : true
|
||||
path : "_data/comments/{options.slug}"
|
||||
path : "docs/_data/comments/{options.slug}"
|
||||
requiredFields : ['name', 'email', 'message']
|
||||
transforms:
|
||||
email : "md5"
|
||||
|
@ -135,6 +135,8 @@ exclude:
|
|||
- Rakefile
|
||||
- README
|
||||
- tmp
|
||||
- /docs # ignore Minimal Mistakes /docs
|
||||
- /test # ignore Minimal Mistakes /test
|
||||
keep_files:
|
||||
- .git
|
||||
- .svn
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
# main links links
|
||||
# main links
|
||||
main:
|
||||
- title: "Quick-Start Guide"
|
||||
url: https://mmistakes.github.io/minimal-mistakes/docs/quick-start-guide/
|
||||
- title: "About"
|
||||
url: https://mmistakes.github.io/minimal-mistakes/about/
|
||||
- title: "Sample Posts"
|
||||
url: /year-archive/
|
||||
- title: "Sample Collections"
|
||||
url: /collection-archive/
|
||||
- title: "Sitemap"
|
||||
url: /sitemap/
|
||||
# - title: "About"
|
||||
# url: https://mmistakes.github.io/minimal-mistakes/about/
|
||||
# - title: "Sample Posts"
|
||||
# url: /year-archive/
|
||||
# - title: "Sample Collections"
|
||||
# url: /collection-archive/
|
||||
# - title: "Sitemap"
|
||||
# url: /sitemap/
|
14
docs/Gemfile
Normal file
14
docs/Gemfile
Normal file
|
@ -0,0 +1,14 @@
|
|||
source "https://rubygems.org"
|
||||
|
||||
gem "github-pages", group: :jekyll_plugins
|
||||
|
||||
gem "wdm", "~> 0.1.0" if Gem.win_platform?
|
||||
|
||||
# If you have any plugins, put them here!
|
||||
# group :jekyll_plugins do
|
||||
# gem "jekyll-paginate"
|
||||
# gem "jekyll-sitemap"
|
||||
# gem "jekyll-gist"
|
||||
# gem "jekyll-feed"
|
||||
# gem "jemoji"
|
||||
# end
|
13
docs/_config.dev.yml
Normal file
13
docs/_config.dev.yml
Normal file
|
@ -0,0 +1,13 @@
|
|||
# Develop override settings
|
||||
|
||||
url: http://localhost:4000
|
||||
|
||||
analytics:
|
||||
provider: false
|
||||
|
||||
comments:
|
||||
disqus:
|
||||
shortname : "mmistakes-dev"
|
||||
|
||||
sass:
|
||||
style: expanded
|
307
docs/_config.yml
Normal file
307
docs/_config.yml
Normal file
|
@ -0,0 +1,307 @@
|
|||
# Welcome to Jekyll!
|
||||
#
|
||||
# This config file is meant for settings that affect your entire site, values
|
||||
# which you are expected to set up once and rarely need to edit after that.
|
||||
# For technical reasons, this file is *NOT* reloaded automatically when you use
|
||||
# `jekyll serve`. If you change this file, please restart the server process.
|
||||
|
||||
# Site Settings
|
||||
locale : "en-US"
|
||||
title : "Minimal Mistakes"
|
||||
title_separator : "-"
|
||||
name : &name "Michael Rose"
|
||||
description : &description "A flexible Jekyll theme for your blog or site with a minimalist aesthetic."
|
||||
url : https://mmistakes.github.io # the base hostname & protocol for your site e.g. "https://mmistakes.github.io"
|
||||
baseurl : "/minimal-mistakes" # the subpath of your site, e.g. "/blog"
|
||||
repository : "mmistakes/minimal-mistakes"
|
||||
teaser : # path of fallback teaser image, e.g. "/assets/images/500x300.png"
|
||||
# breadcrumbs : false # true, false (default)
|
||||
words_per_minute : 200
|
||||
comments:
|
||||
provider : "staticman" # false (default), "disqus", "discourse", "facebook", "google-plus", "staticman", "custom"
|
||||
disqus:
|
||||
shortname :
|
||||
discourse:
|
||||
server : # https://meta.discourse.org/t/embedding-discourse-comments-via-javascript/31963 , e.g.: meta.discourse.org
|
||||
facebook:
|
||||
# https://developers.facebook.com/docs/plugins/comments
|
||||
appid :
|
||||
num_posts : # 5 (default)
|
||||
colorscheme : # "light" (default), "dark"
|
||||
staticman:
|
||||
allowedFields : ['name', 'email', 'url', 'message']
|
||||
branch : "master"
|
||||
commitMessage : "New comment."
|
||||
filename : comment-{@timestamp}
|
||||
format : "yml"
|
||||
moderation : true
|
||||
path : "_data/comments/{options.slug}"
|
||||
requiredFields : ['name', 'email', 'message']
|
||||
transforms:
|
||||
email : "md5"
|
||||
generatedFields:
|
||||
date:
|
||||
type : "date"
|
||||
options:
|
||||
format : "iso8601" # "iso8601" (default), "timestamp-seconds", "timestamp-milliseconds"
|
||||
atom_feed:
|
||||
path : # blank (default) uses feed.xml
|
||||
|
||||
# SEO Related
|
||||
google_site_verification : "UQj93ERU9zgECodaaXgVpkjrFn9UrDMEzVamacSoQ8Y"
|
||||
bing_site_verification :
|
||||
alexa_site_verification :
|
||||
yandex_site_verification :
|
||||
|
||||
# Social Sharing
|
||||
twitter:
|
||||
username : &twitter "mmistakes"
|
||||
facebook:
|
||||
username : &facebook "michaelrose"
|
||||
app_id :
|
||||
publisher :
|
||||
og_image : "/assets/images/site-logo.png" # Open Graph/Twitter default site image
|
||||
# For specifying social profiles
|
||||
# - https://developers.google.com/structured-data/customize/social-profiles
|
||||
social:
|
||||
type : # Person or Organization (defaults to Person)
|
||||
name : # If the user or organization name differs from the site's name
|
||||
links: # An array of links to social media profiles
|
||||
- "https://twitter.com/mmistakes"
|
||||
- "https://facebook.com/michaelrose"
|
||||
|
||||
# Analytics
|
||||
analytics:
|
||||
provider : "google-universal" # false (default), "google", "google-universal", "custom"
|
||||
google:
|
||||
tracking_id : "UA-2011187-3"
|
||||
|
||||
|
||||
# Site Author
|
||||
author:
|
||||
name : *name
|
||||
avatar : "/assets/images/michael-rose.jpg"
|
||||
bio : "Just another boring, tattooed, time traveling, designer."
|
||||
location : "Buffalo, NY"
|
||||
email :
|
||||
uri : "https://mademistakes.com"
|
||||
bitbucket :
|
||||
codepen :
|
||||
dribbble :
|
||||
flickr :
|
||||
facebook : *facebook
|
||||
foursquare :
|
||||
github : "mmistakes"
|
||||
google_plus :
|
||||
keybase :
|
||||
instagram : "mmistakes"
|
||||
lastfm :
|
||||
linkedin :
|
||||
pinterest :
|
||||
soundcloud :
|
||||
stackoverflow : # http://stackoverflow.com/users/123456/username
|
||||
steam :
|
||||
tumblr :
|
||||
twitter : *twitter
|
||||
vine :
|
||||
weibo :
|
||||
xing :
|
||||
youtube :
|
||||
|
||||
|
||||
# Reading Files
|
||||
include:
|
||||
- .htaccess
|
||||
- _pages
|
||||
exclude:
|
||||
- "*.sublime-project"
|
||||
- "*.sublime-workspace"
|
||||
- vendor
|
||||
- .asset-cache
|
||||
- .bundle
|
||||
- .jekyll-assets-cache
|
||||
- .sass-cache
|
||||
- assets/js/plugins
|
||||
- assets/js/_main.js
|
||||
- assets/js/vendor
|
||||
- Capfile
|
||||
- CHANGELOG
|
||||
- config
|
||||
- Gemfile
|
||||
- Gruntfile.js
|
||||
- gulpfile.js
|
||||
- LICENSE
|
||||
- log
|
||||
- node_modules
|
||||
- package.json
|
||||
- Rakefile
|
||||
- README
|
||||
- tmp
|
||||
keep_files:
|
||||
- .git
|
||||
- .svn
|
||||
encoding: "utf-8"
|
||||
markdown_ext: "markdown,mkdown,mkdn,mkd,md"
|
||||
|
||||
|
||||
# Conversion
|
||||
markdown: kramdown
|
||||
highlighter: rouge
|
||||
lsi: false
|
||||
excerpt_separator: "\n\n"
|
||||
incremental: false
|
||||
|
||||
|
||||
# Markdown Processing
|
||||
kramdown:
|
||||
input: GFM
|
||||
hard_wrap: false
|
||||
auto_ids: true
|
||||
footnote_nr: 1
|
||||
entity_output: as_char
|
||||
toc_levels: 1..6
|
||||
smart_quotes: lsquo,rsquo,ldquo,rdquo
|
||||
enable_coderay: false
|
||||
|
||||
|
||||
# Collections
|
||||
collections:
|
||||
docs:
|
||||
output: true
|
||||
permalink: /:collection/:path/
|
||||
recipes:
|
||||
output: true
|
||||
permalink: /:collection/:path/
|
||||
pets:
|
||||
output: true
|
||||
permalink: /:collection/:path/
|
||||
portfolio:
|
||||
output: true
|
||||
permalink: /:collection/:path/
|
||||
|
||||
|
||||
# Defaults
|
||||
defaults:
|
||||
# _posts
|
||||
- scope:
|
||||
path: ""
|
||||
type: posts
|
||||
values:
|
||||
layout: single
|
||||
author_profile: true
|
||||
read_time: true
|
||||
comments: true
|
||||
share: true
|
||||
related: true
|
||||
# _pages
|
||||
- scope:
|
||||
path: ""
|
||||
type: pages
|
||||
values:
|
||||
layout: single
|
||||
author_profile: true
|
||||
# _docs
|
||||
- scope:
|
||||
path: ""
|
||||
type: docs
|
||||
values:
|
||||
layout: single
|
||||
read_time: false
|
||||
author_profile: false
|
||||
share: false
|
||||
comments: false
|
||||
sidebar:
|
||||
nav: "docs"
|
||||
# _recipes
|
||||
- scope:
|
||||
path: ""
|
||||
type: recipes
|
||||
values:
|
||||
layout: single
|
||||
author_profile: true
|
||||
share: true
|
||||
comments: true
|
||||
# _pets
|
||||
- scope:
|
||||
path: ""
|
||||
type: pets
|
||||
values:
|
||||
layout: single
|
||||
author_profile: true
|
||||
share: true
|
||||
comment: true
|
||||
# _portfolio
|
||||
- scope:
|
||||
path: ""
|
||||
type: portfolio
|
||||
values:
|
||||
layout: single
|
||||
author_profile: false
|
||||
share: true
|
||||
|
||||
|
||||
# Sass/SCSS
|
||||
sass:
|
||||
sass_dir: _sass
|
||||
style: compressed # http://sass-lang.com/documentation/file.SASS_REFERENCE.html#output_style
|
||||
|
||||
|
||||
# Outputting
|
||||
permalink: /:categories/:title/
|
||||
# paginate: 5 # amount of posts to show
|
||||
# paginate_path: /page:num/
|
||||
timezone: America/New_York # http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||
|
||||
|
||||
# Plugins
|
||||
gems:
|
||||
- jekyll-paginate
|
||||
- jekyll-sitemap
|
||||
- jekyll-gist
|
||||
- jekyll-feed
|
||||
- jemoji
|
||||
|
||||
# mimic GitHub Pages with --safe
|
||||
whitelist:
|
||||
- jekyll-paginate
|
||||
- jekyll-sitemap
|
||||
- jekyll-gist
|
||||
- jekyll-feed
|
||||
- jemoji
|
||||
|
||||
|
||||
# Archives
|
||||
# Type
|
||||
# - GitHub Pages compatible archive pages built with Liquid ~> type: liquid (default)
|
||||
# - Jekyll Archives plugin archive pages ~> type: jekyll-archives
|
||||
# Path (examples)
|
||||
# - Archive page should exist at path when using Liquid method or you can
|
||||
# expect broken links (especially with breadcrumbs enabled)
|
||||
# - <base_path>/tags/my-awesome-tag/index.html ~> path: /tags/
|
||||
# - <base_path/categories/my-awesome-category/index.html ~> path: /categories/
|
||||
# - <base_path/my-awesome-category/index.html ~> path: /
|
||||
category_archive:
|
||||
type: liquid
|
||||
path: /categories/
|
||||
tag_archive:
|
||||
type: liquid
|
||||
path: /tags/
|
||||
# https://github.com/jekyll/jekyll-archives
|
||||
# jekyll-archives:
|
||||
# enabled:
|
||||
# - categories
|
||||
# - tags
|
||||
# layouts:
|
||||
# category: archive-taxonomy
|
||||
# tag: archive-taxonomy
|
||||
# permalinks:
|
||||
# category: /categories/:name/
|
||||
# tag: /tags/:name/
|
||||
|
||||
|
||||
# HTML Compression
|
||||
# - http://jch.penibelst.de/
|
||||
compress_html:
|
||||
clippings: all
|
||||
ignore:
|
||||
envs: development
|
0
example/_data/authors.yml → docs/_data/authors.yml
Executable file → Normal file
0
example/_data/authors.yml → docs/_data/authors.yml
Executable file → Normal file
|
@ -0,0 +1,6 @@
|
|||
message: Cooooookies! Yum! (Thanks for this awesome them.. and... recipe..)
|
||||
name: Markus
|
||||
email: f6f9be6ae6e174661ea7c87a520ffef8
|
||||
url: 'http://www.markusgiesen.com'
|
||||
hidden: ''
|
||||
date: '2016-09-14T16:23:32.840Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: "![Bill Murray](http://www.fillmurray.com/400/300)\r\n\r\n“It's hard to be an artist. It's hard to be anything. It's hard to be.”"
|
||||
name: Bill Murray
|
||||
email: b0caa2a71f5066b3d90711c224578c21
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-11T19:33:25.928Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: "> “I never had seen Seinfeld, and they said, ‘Oh, it’s the last episode.’ And I said, ‘Oh, I’ll watch Seinfeld.’ And it was terrible.”\r\n>\r\n> *— From a 2014 interview with Howard Stern*"
|
||||
name: Anonymous
|
||||
email: 8c7e898f1b570760f834ecc03edf6b35
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-11T19:36:01.033Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: test
|
||||
name: test
|
||||
email: c028c75814332d38e088e43a252b7092
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-27T14:34:32.281Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: Test message
|
||||
name: Artur
|
||||
email: 1cbebf1e64617de54d7858ffc6d96935
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-09-19T17:41:00.416Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: test
|
||||
name: test
|
||||
email: 01540d5a1cdb4d03edb23805df684762
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-24T12:05:22.844Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: test
|
||||
name: ppmeng
|
||||
email: b9c981f67166172c8804b5f9066a404a
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-25T17:37:17.780Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: "Here's a test comment with a Markdown code block:\r\n\r\n```scss\r\nh1, h2, h3, h4, h5, h6 {\r\n margin: 2em 0 0.5em;\r\n line-height: 1.2;\r\n font-family: $header-font-family;\r\n font-weight: bold;\r\n}\r\n```"
|
||||
name: Michael Rose
|
||||
email: 1ce71bc10b86565464b612093d89707e
|
||||
url: 'https://mademistakes.com'
|
||||
hidden: ''
|
||||
date: '2016-08-12T02:41:04.706Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: mm
|
||||
name: mm
|
||||
email: 9d0057d30e7a5e44f6378ea2c9c11f5d
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-24T18:49:19.649Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: This is a tst
|
||||
name: GnCavalry
|
||||
email: 5669e6e45ccab46a7384a8c8ab88edd2
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-09-02T03:15:37.068Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: "This is a test comment with some **Markdown** sprinkled about for *testing purposes*.\r\n\r\n### Subheading in a comment? Madness!\r\n\r\nNam et risus nec ipsum efficitur facilisis. Aenean tincidunt dapibus odio, eget rutrum urna lacinia non. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas."
|
||||
name: Michael Rose
|
||||
email: 1ce71bc10b86565464b612093d89707e
|
||||
url: 'https://mademistakes.com'
|
||||
hidden: ''
|
||||
date: '2016-08-11T19:03:24.929Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: '"How much wood would a woodchuck chuck if a woodchuck could chuck wood?"'
|
||||
name: Jackalope
|
||||
email: cba827e665ae179e1d1ae007a6c3c1ab
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-11T19:04:06.958Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: '"How much wood would a woodchuck chuck if a woodchuck could chuck wood?"'
|
||||
name: Jackalope Duplicate
|
||||
email: cba827e665ae179e1d1ae007a6c3c1ab
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-11T19:04:25.085Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: "Images can be added to a comment using Markdown like this\r\n\r\n```markdown\r\n![Bill Murray](http://www.fillmurray.com/600/400)\r\n```\r\n![Bill Murray](http://www.fillmurray.com/600/400)"
|
||||
name: Michael Rose
|
||||
email: 1ce71bc10b86565464b612093d89707e
|
||||
url: 'https://mademistakes.com'
|
||||
hidden: ''
|
||||
date: '2016-08-11T19:08:12.789Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: 'Wow, this is awesome'
|
||||
name: kkangshawn
|
||||
email: db92190b2ee6118786fd1f25dceb448c
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-21T23:49:06.270Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: Test
|
||||
name: Test
|
||||
email: b642b4217b34b1e8d3bd915fc65c4452
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-08-22T03:03:07.694Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: This is a test
|
||||
name: TestName
|
||||
email: 97dfebf4098c0f5c16bca61e2b76c373
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-09-02T03:23:18.756Z'
|
|
@ -0,0 +1,6 @@
|
|||
message: just testing as well
|
||||
name: js
|
||||
email: f349d4bc6fa472971f68bcccc04337f9
|
||||
url: ''
|
||||
hidden: ''
|
||||
date: '2016-09-19T23:49:09.452Z'
|
99
docs/_data/navigation.yml
Normal file
99
docs/_data/navigation.yml
Normal file
|
@ -0,0 +1,99 @@
|
|||
# example navigation
|
||||
foo:
|
||||
- title: "Parent Link 1"
|
||||
url: /parent-1-page-url/
|
||||
children:
|
||||
- title: "Child Link 1"
|
||||
url: /child-1-page-url/
|
||||
- title: "Child Link 2"
|
||||
url: /child-2-page-url/
|
||||
|
||||
- title: "Parent Link 2"
|
||||
url: /parent-2-page-url/
|
||||
children:
|
||||
- title: "Child Link 1"
|
||||
url: /child-1-page-url/
|
||||
- title: "Child Link 2"
|
||||
url: /child-2-page-url/
|
||||
- title: "Child Link 3"
|
||||
url: /child-3-page-url/
|
||||
|
||||
|
||||
# main links links
|
||||
main:
|
||||
- title: "Quick-Start Guide"
|
||||
url: /docs/quick-start-guide/
|
||||
|
||||
- title: "About"
|
||||
url: /about/
|
||||
|
||||
- title: "Sample Posts"
|
||||
url: /year-archive/
|
||||
|
||||
- title: "Sample Collections"
|
||||
url: /collection-archive/
|
||||
|
||||
- title: "Terms & Privacy Policy"
|
||||
url: /terms/
|
||||
|
||||
|
||||
# documentation links
|
||||
docs:
|
||||
- title: Getting Started
|
||||
children:
|
||||
- title: "Quick-Start Guide"
|
||||
url: /docs/quick-start-guide/
|
||||
- title: "Structure"
|
||||
url: /docs/structure/
|
||||
- title: "Installation"
|
||||
url: /docs/installation/
|
||||
- title: "Upgrading"
|
||||
url: /docs/upgrading/
|
||||
|
||||
- title: Customization
|
||||
children:
|
||||
- title: "Configuration"
|
||||
url: /docs/configuration/
|
||||
- title: "Overriding Theme Defaults"
|
||||
url: /docs/overriding-theme-defaults/
|
||||
- title: "Navigation"
|
||||
url: /docs/navigation/
|
||||
- title: "UI Text"
|
||||
url: /docs/ui-text/
|
||||
- title: "Authors"
|
||||
url: /docs/authors/
|
||||
- title: "Layouts"
|
||||
url: /docs/layouts/
|
||||
|
||||
- title: Content
|
||||
children:
|
||||
- title: "Working with Posts"
|
||||
url: /docs/posts/
|
||||
- title: "Working with Pages"
|
||||
url: /docs/pages/
|
||||
- title: "Working with Collections"
|
||||
url: /docs/collections/
|
||||
- title: "Helpers"
|
||||
url: /docs/helpers/
|
||||
- title: "Utility Classes"
|
||||
url: /docs/utility-classes/
|
||||
|
||||
- title: Extras
|
||||
children:
|
||||
- title: "Stylesheets"
|
||||
url: /docs/stylesheets/
|
||||
- title: "JavaScript"
|
||||
url: /docs/javascript/
|
||||
|
||||
- title: Meta
|
||||
children:
|
||||
- title: "History"
|
||||
url: /docs/history/
|
||||
- title: "Contributing"
|
||||
url: /docs/contributing/
|
||||
- title: "Old 2.2 Docs"
|
||||
url: /docs/docs-2-2/
|
||||
- title: "License"
|
||||
url: /docs/license/
|
||||
- title: "Terms & Privacy Policy"
|
||||
url: /terms/
|
|
@ -351,57 +351,5 @@ zh: &DEFAULT_ZH
|
|||
zh-TW:
|
||||
<<: *DEFAULT_ZH
|
||||
|
||||
# German / Deutsch
|
||||
# -----------------
|
||||
de: &DEFAULT_DE
|
||||
page : "Seite"
|
||||
pagination_previous : "Vorherige"
|
||||
pagination_next : "Nächste"
|
||||
breadcrumb_home_label : "Home"
|
||||
breadcrumb_separator : "/"
|
||||
toc_label : "Auf dieser Seite"
|
||||
ext_link_label : "Direkter Link"
|
||||
less_than : "weniger als"
|
||||
minute_read : "Minuten zum lesen"
|
||||
share_on_label : "Teilen auf"
|
||||
meta_label :
|
||||
tags_label : "Tags:"
|
||||
categories_label : "Kategorien:"
|
||||
date_label : "Aktualisiert:"
|
||||
comments_label : "Hinterlassen sie einen Kommentar"
|
||||
comments_title : "Kommentare"
|
||||
more_label : "Mehr anzeigen"
|
||||
related_label : "Ihnen gefällt vielleicht auch"
|
||||
follow_label : "Folgen:"
|
||||
feed_label : "Feed"
|
||||
powered_by : "Powered by"
|
||||
website_label : "Webseite"
|
||||
email_label : "E-Mail"
|
||||
recent_posts : "Aktuelle Beiträge"
|
||||
undefined_wpm : "Undefinierter Parameter words_per_minute in _config.yml"
|
||||
comment_form_info : "Ihre E-Mail Adresse wird nicht veröffentlicht. Benötigte Felder sind markiert"
|
||||
comment_form_comment_label : "Kommentar"
|
||||
comment_form_md_info : "Markdown wird unterstützt."
|
||||
comment_form_name_label : "Name"
|
||||
comment_form_email_label : "E-Mail Addresse"
|
||||
comment_form_website_label : "Webseite (optional)"
|
||||
comment_btn_submit : "Kommentar absenden"
|
||||
comment_btn_submitted : "Versendet"
|
||||
comment_success_msg : "Danke für ihren Kommentar! Er wird auf der Seite angezeigt, nachdem er geprüft wurde."
|
||||
comment_error_msg : "Entschuldigung, es gab einen Fehler. Bitte füllen sie alle benötigten Felder aus und versuchen sie es erneut."
|
||||
loading_label : "Lade..."
|
||||
de-DE:
|
||||
<<: *DEFAULT_DE
|
||||
de-AT:
|
||||
<<: *DEFAULT_DE
|
||||
de-CH:
|
||||
<<: *DEFAULT_DE
|
||||
de-BE:
|
||||
<<: *DEFAULT_DE
|
||||
de-LI:
|
||||
<<: *DEFAULT_DE
|
||||
de-LU:
|
||||
<<: *DEFAULT_DE
|
||||
|
||||
# Another locale
|
||||
# --------------
|
153
docs/_docs/01-quick-start-guide.md
Normal file
153
docs/_docs/01-quick-start-guide.md
Normal file
|
@ -0,0 +1,153 @@
|
|||
---
|
||||
title: "Quick-Start Guide"
|
||||
permalink: /docs/quick-start-guide/
|
||||
excerpt: "How to quickly install and setup Minimal Mistakes for use with GitHub Pages."
|
||||
modified: 2016-11-03T10:01:43-04:00
|
||||
redirect_from:
|
||||
- /theme-setup/
|
||||
---
|
||||
|
||||
Minimal Mistakes has been developed as a [Jekyll theme gem](http://jekyllrb.com/docs/themes/) for easier use. It is also 100% compatible with GitHub Pages --- just with a more involved installation process.
|
||||
|
||||
{% include toc %}
|
||||
|
||||
## Installing the Theme
|
||||
|
||||
If you're running Jekyll v3.3+ and self-hosting you can quickly install the theme as Ruby gem.
|
||||
If you're hosting with GitHub Pages you'll have to use the old "repo fork" method or directly copy all of the theme files[^structure] into your site.
|
||||
|
||||
[^structure]: See [**Structure** page]({{ "/docs/structure/" | absolute_url }}) for a list of theme files and what they do.
|
||||
|
||||
**ProTip:** Be sure to remove `/docs` and `/test` if you forked Minimal Mistakes. These folders contain documentation and test pages for the theme and you probably don't littering up in your repo.
|
||||
{: .notice--info}
|
||||
|
||||
### Ruby Gem Method
|
||||
|
||||
Add this line to your Jekyll site's `Gemfile`:
|
||||
|
||||
```ruby
|
||||
gem "minimal-mistakes-jekyll"
|
||||
```
|
||||
|
||||
Add this line to your Jekyll site's `_config.yml` file:
|
||||
|
||||
```yaml
|
||||
theme: minimal-mistakes-jekyll
|
||||
```
|
||||
|
||||
Then run Bundler to install the theme gem and dependencies:
|
||||
|
||||
```bash
|
||||
bundle install
|
||||
```
|
||||
|
||||
### GitHub Pages Compatible Method
|
||||
|
||||
Fork the [Minimal Mistakes theme](https://github.com/mmistakes/minimal-mistakes/fork), then rename the repo to **USERNAME.github.io** --- replacing **USERNAME** with your GitHub username.
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-theme-fork-repo.png' | absolute_url }}" alt="fork Minimal Mistakes">
|
||||
</figure>
|
||||
|
||||
**Note:** Your Jekyll site should be viewable immediately at <http://USERNAME.github.io>. If it's not, you can force a rebuild by **Customizing Your Site** (see below for more details).
|
||||
{: .notice--warning}
|
||||
|
||||
If you're hosting several Jekyll based sites under the same GitHub username you will have to use Project Pages instead of User Pages. Essentially you rename the repo to something other than **USERNAME.github.io** and create a `gh-pages` branch off of `master`. For more details on how to set things up check [GitHub's documentation](https://help.github.com/articles/user-organization-and-project-pages/).
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-gh-pages.gif' | absolute_url }}" alt="creating a new branch on GitHub">
|
||||
</figure>
|
||||
|
||||
Replace the contents of `Gemfile` found in the root of your Jekyll site with the following:
|
||||
|
||||
```ruby
|
||||
source "https://rubygems.org"
|
||||
|
||||
gem "github-pages", group: :jekyll_plugins
|
||||
|
||||
group :jekyll_plugins do
|
||||
gem "jekyll-paginate"
|
||||
gem "jekyll-sitemap"
|
||||
gem "jekyll-gist"
|
||||
gem "jekyll-feed"
|
||||
gem "jemoji"
|
||||
end
|
||||
```
|
||||
|
||||
Then run `bundle update` and verify that all gems install properly.
|
||||
|
||||
### Remove the Unnecessary
|
||||
|
||||
If you forked or downloaded the `minimal-mistakes-jekyll` repo you can safely remove the following folders and files:
|
||||
|
||||
- `.editorconfig`
|
||||
- `.gitattributes`
|
||||
- `.github`
|
||||
- `/docs`
|
||||
- `/test`
|
||||
- `CHANGELOG.md`
|
||||
- `minimal-mistakes-jekyll.gemspec`
|
||||
- `README.md`
|
||||
- `screenshot-layouts.png`
|
||||
- `screenshot.png`
|
||||
|
||||
## Setup Your Site
|
||||
|
||||
Depending on the path you took installing Minimal Mistakes you'll setup things a little differently.
|
||||
|
||||
### Starting Fresh
|
||||
|
||||
Starting with an empty folder and `Gemfile` you'll need to copy or re-create this [default `_config.yml`](https://github.com/mmistakes/minimal-mistakes/blob/master/_config.yml) file. For a full explanation of every setting be sure to read the [**Configuration**]({{ "/docs/configuration/" | absolute_url }}) section.
|
||||
|
||||
After taking care of Jekyll's configuration file, you'll need to create and edit the following data files.
|
||||
|
||||
- [`_data/ui-text.yml`](https://github.com/mmistakes/minimal-mistakes/blob/master/_data/ui-text.yml) - UI text [documentation]({{ "/docs/ui-text/" | absolute_url }})
|
||||
- [`_data/navigation.yml`](https://github.com/mmistakes/minimal-mistakes/blob/master/_data/navigation.yml) - navigation [documentation]({{ "/docs/navigation/" | absolute_url }})
|
||||
|
||||
### Starting from `jekyll new`
|
||||
|
||||
Scaffolding out a site with the `jekyll new` command requires you to modify a few files that it creates.
|
||||
|
||||
Edit `_config.yml` and create `_data/ui-text.yml` and `_data/navigation.yml` same as above. Then:
|
||||
|
||||
- Replace `<site root>/index.html` with a modified [Minimal Mistakes `index.html`](https://github.com/mmistakes/minimal-mistakes/blob/master/index.html).
|
||||
- Change `layout: post` in `_posts/0000-00-00-welcome-to-jekyll.markdown` to `layout: single`.
|
||||
- Remove `about.md`, or at the very least change `layout: page` to `layout: single` and remove references to `icon-github.html` (or [copy to your `_includes`](https://github.com/jekyll/minima/tree/master/_includes) if using it).
|
||||
|
||||
### Migrating to Gem Version
|
||||
|
||||
If you're migrating a site already using Minimal Mistakes and haven't customized any of the theme files things upgrading will be easier for you.
|
||||
|
||||
Start by removing `_includes`, `_layouts`, `_sass`, `assets` folders and all files within. You won't need these anymore as they're bundled with the theme gem.
|
||||
|
||||
If you customized any of these files leave them alone, and only remove the untouched ones. If done correctly your modified versions should [override](http://jekyllrb.com/docs/themes/#overriding-theme-defaults) the versions bundled with the theme and be used by Jekyll instead.
|
||||
|
||||
#### Update Gemfile
|
||||
|
||||
Replace `gem "github-pages` or `gem "jekyll"` with `gem "jekyll", "~> 3.3.0"`. You'll need the latest version of Jekyll[^update-jekyll] for Minimal Mistakes to work and load all of the theme's assets properly, this line forces Bundler to do that.
|
||||
|
||||
[^update-jekyll]: You could also run `bundle update jekyll` to update Jekyll.
|
||||
|
||||
Add the Minimal Mistakes theme gem:
|
||||
|
||||
```ruby
|
||||
gem "minimal-mistakes-jekyll"
|
||||
```
|
||||
|
||||
When finished your `Gemfile` should look something like this:
|
||||
|
||||
```ruby
|
||||
source "https://rubygems.org"
|
||||
|
||||
gem "jekyll", "~> 3.3.0"
|
||||
gem "minimal-mistakes-jekyll"
|
||||
```
|
||||
|
||||
Then run `bundle update` and add `theme: minimal-mistakes-jekyll` to your `_config.yml`.
|
||||
|
||||
**v4 Breaking Change:** Paths for image headers, overlays, teasers, [galleries]({{ "/docs/helpers/#gallery" | absolute_url }}), and [feature rows]({{ "/docs/helpers/#feature-row" | absolute_url }}) have changed and now require a full path. Instead of just `image: filename.jpg` you'll need to use the full path eg: `image: /assets/images/filename.jpg`. The preferred location is now `/assets/images/` but can be placed elsewhere or external hosted. This all applies for image references in `_config.yml` and `author.yml` as well.
|
||||
{: .notice--danger}
|
||||
|
||||
---
|
||||
|
||||
That's it! If all goes well running `bundle exec jekyll serve` should spin-up your site.
|
54
docs/_docs/02-structure.md
Normal file
54
docs/_docs/02-structure.md
Normal file
|
@ -0,0 +1,54 @@
|
|||
---
|
||||
title: "Structure"
|
||||
permalink: /docs/structure/
|
||||
excerpt: "How the theme is organized and what all of the files are for."
|
||||
modified: 2016-10-06T22:39:43-04:00
|
||||
---
|
||||
|
||||
Nothing clever here :wink:. Layouts, data files, and includes are all placed in their default locations. Stylesheets and scripts in `assets`, and a few development related files in the project's root directory.
|
||||
|
||||
**Please note:** If you installed Minimal Mistakes via the Ruby Gem method, theme files like `_layouts`, `_includes`, `_sass`, and `/assets/` will be missing. This is normal as they are bundled with the [`minimal-mistakes-jekyll`](https://rubygems.org/gems/minimal-mistakes-jekyll) Ruby gem.
|
||||
{: .notice--info}
|
||||
|
||||
```bash
|
||||
minimal-mistakes
|
||||
├── _data # data files for customizing the theme
|
||||
| ├── navigations.yml # main navigation links
|
||||
| └── ui-text.yml # text used throughout the theme's UI
|
||||
├── _includes
|
||||
| ├── analytics-providers # snippets for analytics (Google and custom)
|
||||
| ├── comments-providers # snippets for comments (Disqus, Facebook, Google+, and custom)
|
||||
| ├── footer # custom snippets to add to site footer
|
||||
| ├── head # custom snippets to add to site head
|
||||
| ├── base_path # site.url + site.baseurl shortcut
|
||||
| ├── feature_row # feature row helper
|
||||
| ├── gallery # image gallery helper
|
||||
| ├── group-by-array # group by array helper for archives
|
||||
| ├── nav_list # navigation list helper
|
||||
| ├── toc # table of contents helper
|
||||
| └── ...
|
||||
├── _layouts
|
||||
| ├── archive-taxonomy.html # tag/category archive for Jekyll Archives plugin
|
||||
| ├── archive.html # archive listing documents in an array
|
||||
| ├── compress.html # compresses HTML in pure Liquid
|
||||
| ├── default.html # base for all other layouts
|
||||
| ├── home.html # home page
|
||||
| ├── single.html # single document (post/page/etc)
|
||||
| └── splash.html # splash page
|
||||
├── _sass # SCSS partials
|
||||
├── assets
|
||||
| ├── css
|
||||
| | └── main.scss # main stylesheet, loads SCSS partials from _sass
|
||||
| ├── fonts
|
||||
| | └── fontawesome-webfont # Font Awesome webfonts
|
||||
| ├── images # image assets for posts/pages/collections/etc.
|
||||
| ├── js
|
||||
| | ├── plugins # jQuery plugins
|
||||
| | ├── vendor # vendor scripts
|
||||
| | ├── _main.js # plugin settings and other scripts to load after jQuery
|
||||
| | └── main.min.js # optimized and concatenated script file loaded before </body>
|
||||
├── _config.yml # site configuration
|
||||
├── Gemfile # gem file dependencies
|
||||
├── index.html # paginated home page showing recent posts
|
||||
└── package.json # NPM build scripts
|
||||
```
|
107
docs/_docs/03-installation.md
Normal file
107
docs/_docs/03-installation.md
Normal file
|
@ -0,0 +1,107 @@
|
|||
---
|
||||
title: "Installation"
|
||||
permalink: /docs/installation/
|
||||
excerpt: "Instructions for installing the theme for new and existing Jekyll based sites."
|
||||
modified: 2016-11-03T10:13:32-04:00
|
||||
---
|
||||
|
||||
## Install the Theme
|
||||
|
||||
There are several ways to install the theme:
|
||||
|
||||
**1.** For a **new site**, install the `minimal-mistakes-jekyll` theme gem or fork the Minimal Mistakes repo on GitHub following the steps outlined in the [*Quick-Start Guide*]({{ "/docs/quick-start-guide/" | absolute_url }}).
|
||||
|
||||
**2.** For an **existing site** follow the **Ruby Gem Method** steps outlined in the [*Quick-Start Guide*]({{ "/docs/quick-start-guide/" | absolute_url }}). If you plan to host with GitHub Pages I suggest you fork and rename the theme's repo, then clone it locally by running `git clone https://github.com/USERNAME/REPONAME.git` --- replacing **USERNAME** and **REPONAME** with your own.
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-github-copy-repo-url.jpg' | absolute_url }}" alt="copy GitHub repo URL">
|
||||
<figcaption>Tap the copy to clipboard button (outlined in red above) to grab your GitHub repo's path.</figcaption>
|
||||
</figure>
|
||||
|
||||
**3.** And for those who don't want to mess with Git, you can download the theme as a ZIP file to work with locally.
|
||||
|
||||
[<i class="fa fa-download"></i> Download Minimal Mistakes Theme](https://github.com/mmistakes/minimal-mistakes/archive/master.zip){: .btn .btn--success}
|
||||
|
||||
**ProTip:** Be sure to remove `/docs` and `/test` if you forked Minimal Mistakes. These folders contain documentation and test pages for the theme and you probably don't littering up in your repo.
|
||||
{: .notice--info}
|
||||
|
||||
---
|
||||
|
||||
To move over any existing content you'll want to copy the contents of your `_posts` folder to the new site. Along with any pages, collections, data files, images, or other assets you may have.
|
||||
|
||||
Next you'll need to convert posts and pages to use the proper layouts and settings. In most cases you simply need to update `_config.yml` to your liking and set the correct `layout` in their YAML Front Matter.
|
||||
|
||||
[**Front Matter defaults**](https://jekyllrb.com/docs/configuration/#front-matter-defaults) are your friend and I encourage you to leverage them instead of setting a layout and other global options in each post/page's YAML Front Matter.
|
||||
|
||||
Posts can be configured to use the `single` layout --- with reading time, comments, social sharing links, and related posts enabled. Adding the following to `_config.yml` will set these defaults for all posts:
|
||||
|
||||
```yaml
|
||||
defaults:
|
||||
# _posts
|
||||
- scope:
|
||||
path: ""
|
||||
type: posts
|
||||
values:
|
||||
layout: single
|
||||
read_time: true
|
||||
comments: true
|
||||
share: true
|
||||
related: true
|
||||
```
|
||||
|
||||
**Post/Page Settings**: Be sure to read through the "Working with..." documentation to learn about all the options available to you. The theme has been designed to be flexible --- with numerous settings for each.
|
||||
{: .notice--info}
|
||||
|
||||
## Install Dependencies
|
||||
|
||||
If this is your first time using Jekyll be sure to read through the [official documentation](https://jekyllrb.com/docs/home/) before jumping in. This guide assumes you have Ruby v2 installed and a basic understanding of how Jekyll works.
|
||||
|
||||
To keep your sanity and better manage dependencies I strongly urge you to [install Bundler](http://bundler.io/) with `gem install bundler` and use the following `Gemfile`:
|
||||
|
||||
```ruby
|
||||
source "https://rubygems.org"
|
||||
|
||||
# Hello! This is where you manage which Jekyll version is used to run.
|
||||
# When you want to use a different version, change it below, save the
|
||||
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
|
||||
#
|
||||
# bundle exec jekyll serve
|
||||
#
|
||||
# This will help ensure the proper Jekyll version is running.
|
||||
# Happy Jekylling!
|
||||
|
||||
# gem "github-pages", group: :jekyll_plugins
|
||||
|
||||
# To upgrade, run `bundle update`.
|
||||
|
||||
gem "jekyll", "~> 3.3.0"
|
||||
gem "minimal-mistakes-jekyll"
|
||||
|
||||
# If you have any plugins, put them here!
|
||||
group :jekyll_plugins do
|
||||
gem "jekyll-paginate"
|
||||
gem "jekyll-sitemap"
|
||||
gem "jekyll-gist"
|
||||
gem "jekyll-feed"
|
||||
gem "jemoji"
|
||||
end
|
||||
```
|
||||
|
||||
To maintain a local Jekyll environment in sync with GitHub Pages replace the `gem "jekyll"` line with `gem "github-pages", group: :jekyll_plugins` and run the following:
|
||||
|
||||
```bash
|
||||
$ bundle install
|
||||
```
|
||||
|
||||
**Note:** The [GitHub Pages gem](https://github.com/github/pages-gem) installs additional dependencies that may need to be added to your `Gemfile` if you decide to remove the `gem "github-pages"` eg. `jekyll-paginate`, `jekyll-sitemap`, `jekyll-feed`, etc.
|
||||
{: .notice--warning}
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-bundle-install.gif' | absolute_url }}" alt="bundle install in Terminal window">
|
||||
</figure>
|
||||
|
||||
Depending on what gems you already have installed you may have to run `bundle update` to clear up any dependency issues. Bundler is usually pretty good at letting you know what gems need updating or have issues installing, to further investigate.
|
||||
|
||||
When using Bundler to manage gems you'll want to run Jekyll using `bundle exec jekyll serve` and `bundle exec jekyll build`.
|
||||
|
||||
Doing so executes the gem versions specified in `Gemfile.lock`. Sure you can test your luck with a naked `jekyll serve`, but I wouldn't suggest it. A lot of Jekyll errors originate from outdated or conflicting gems fighting with each other. So do yourself a favor and just use Bundler.
|
48
docs/_docs/04-upgrading.md
Normal file
48
docs/_docs/04-upgrading.md
Normal file
|
@ -0,0 +1,48 @@
|
|||
---
|
||||
title: "Upgrading"
|
||||
permalink: /docs/upgrading/
|
||||
excerpt: "Instructions and suggestions for upgrading the theme."
|
||||
modified: 2016-11-03T10:16:34-04:00
|
||||
---
|
||||
|
||||
If you're using the Ruby Gem version of the theme upgrading is fairly painless.
|
||||
|
||||
Simply run `bundle update` if you're using Bundler (have a `Gemfile`) or `gem update minimal-mistakes-jekyll` if you're not.
|
||||
|
||||
## Use Git
|
||||
|
||||
If you want to get the most out of the Jekyll + GitHub Pages workflow, then you'll need to utilize Git. To pull down theme updates you must first ensure there's an upstream remote. If you forked the theme's repo then you're likely good to go.
|
||||
|
||||
To double check, run `git remote -v` and verify that you can fetch from `origin https://github.com/{{ site.repository }}.git`.
|
||||
|
||||
To add it you can do the following:
|
||||
|
||||
```bash
|
||||
$ git remote add upstream https://github.com/{{ site.repository }}.git
|
||||
```
|
||||
|
||||
### Pull Down Updates
|
||||
|
||||
Now you can pull any commits made to theme's `master` branch with:
|
||||
|
||||
```bash
|
||||
$ git pull upstream master
|
||||
```
|
||||
|
||||
Depending on the amount of customizations you've made after forking, there's likely to be merge conflicts. Work through any conflicting files Git flags, staging the changes you wish to keep, and then commit them.
|
||||
|
||||
## Update Files Manually
|
||||
|
||||
Another way of dealing with updates is [downloading the theme](https://github.com/{{ site.repository }}/archive/master.zip) --- replacing your layouts, includes, and assets with the newer ones manually. To be sure that you don't miss any changes it's probably a good idea to review the theme's [commit history](https://github.com/{{ site.repository }}/commits/master) to see what's changed since.
|
||||
|
||||
Here's a quick checklist of the important folders/files you'll want to be mindful of:
|
||||
|
||||
| Name | |
|
||||
| ---- | --- |
|
||||
| `_layouts` | Replace all. Apply edits if you customized any layouts. |
|
||||
| `_includes` | Replace all. Apply edits if you customized any includes. |
|
||||
| `assets` | Replace all. Apply edits if you customized stylesheets or scripts. |
|
||||
| `_sass` | Replace all. Apply edits if you customized Sass partials. |
|
||||
| `_data/navigation.yml` | Safe to keep. Verify that there were no major structural changes or additions. |
|
||||
| `_data/ui-text.yml` | Safe to keep. Verify that there were no major structural changes or additions. |
|
||||
| `_config.yml` | Safe to keep. Verify that there were no major structural changes or additions. |
|
624
docs/_docs/05-configuration.md
Normal file
624
docs/_docs/05-configuration.md
Normal file
|
@ -0,0 +1,624 @@
|
|||
---
|
||||
title: "Configuration"
|
||||
permalink: /docs/configuration/
|
||||
excerpt: "Settings for configuring and customizing the theme."
|
||||
modified: 2016-11-03T10:42:01-04:00
|
||||
---
|
||||
|
||||
Settings that affect your entire site can be changed in [Jekyll's configuration file](https://jekyllrb.com/docs/configuration/): `_config.yml`, found in the root of your project. If you don't have this file you'll need to copy or create one using the theme's [default `_config.yml`](https://github.com/mmistakes/minimal-mistakes/blob/master/_config.yml) as a base.
|
||||
|
||||
**Note:** for technical reasons, `_config.yml` is NOT reloaded automatically when used with `jekyll serve`. If you make any changes to this file, please restart the server process for them to be applied.
|
||||
{: .notice--warning}
|
||||
|
||||
Take a moment to look over the configuration file included with the theme. Comments have been added to provide examples and default values for most settings. Detailed explanations of each can be found below.
|
||||
|
||||
## Site Settings
|
||||
|
||||
### Theme
|
||||
|
||||
If you're using the Ruby gem version of the theme you'll need this line to activate it:
|
||||
|
||||
```yaml
|
||||
theme: minimal-mistakes-jekyll
|
||||
```
|
||||
|
||||
### Site Locale
|
||||
|
||||
`site.locale` is used to declare the primary language for each web page within the site.
|
||||
|
||||
*Example:* `locale: "en-US"` sets the `lang` attribute for the site to the *United States* flavor of English, while `en-GB` would be for the `United Kingdom` style of English. Country codes are optional and the shorter variation `locale: "en"` is also acceptable. To find your language and country codes check this [reference table](https://msdn.microsoft.com/en-us/library/ee825488(v=cs.20).aspx).
|
||||
|
||||
Properly setting the locale is important for associating localized text found in the [**UI Text**]({{ "/docs/ui-text/" | absolute_url }}) data file. An improper match will cause parts of the UI to disappear (eg. button labels, section headings, etc).
|
||||
|
||||
**Note:** The theme comes with localized text in English (`en`, `en-US`, `en-GB`). If you change `locale` in `_config.yml` to something else, most of the UI text will go blank. Be sure to add the corresponding locale key and translated text to `_data/ui-text.yml` to avoid this.
|
||||
{: .notice--warning}
|
||||
|
||||
### Site Title
|
||||
|
||||
The name of your site. Is used throughout the theme in places like the site masthead and `<title>` tags.
|
||||
|
||||
*Example:* `title: "My Awesome Site"`
|
||||
|
||||
You also have the option of customizing the separation character used in SEO-friendly page titles.
|
||||
|
||||
*Example:* `title_separator: "|"` would produce page titles like `Sample Page | My Awesome Site`.
|
||||
|
||||
**Note:** Long site titles have been known to break the masthead layout. Avoid adding a long "tagline" to the title prevent this from happening eg. `My Awesome Site is the Best Because I Say So".
|
||||
{: .notice--warning}
|
||||
|
||||
### Site Name
|
||||
|
||||
Used to assign a site author. Don't worry, you can override the site author with different ones on specific posts, pages, or collection documents.
|
||||
|
||||
*Example:* `name: "Michael Rose"`.
|
||||
|
||||
**ProTip:** If you want to get crafty with your YAML you can use [anchors](http://www.yaml.org/spec/1.2/spec.html#id2785586) to reuse values. For example `foo: &var "My String"` allows you to reuse `"My String"` elsewhere in `_config.yml` like so... `bar: *var`. You'll see a few examples of this in the provided Jekyll config.
|
||||
{: .notice--info}
|
||||
|
||||
### Site Description
|
||||
|
||||
Fairly obvious. `site.description` describes the site. Used predominantly in meta descriptions for improving SEO.
|
||||
|
||||
*Example:* `description: "A flexible Jekyll theme for your blog or site with a minimalist aesthetic."`
|
||||
|
||||
### Site URL
|
||||
|
||||
The base hostname and protocol for your site. If you're hosting with GitHub Pages this will be something like `url: "https://github.io.mmistakes"` or `url: "https://mademistakes.com"` if you have a custom domain name.
|
||||
|
||||
GitHub Pages now [forces `https://` for new sites](https://help.github.com/articles/securing-your-github-pages-site-with-https/) so be mindful of that when setting your URL to avoid mixed-content warnings.
|
||||
|
||||
**Note:** Jekyll 3.3 overrides this value with `url: http://localhost:4000` when running `jekyll serve` locally in development. If you want to avoid this behavior set `JEKYLL_ENV=production` to [force the environment](http://jekyllrb.com/docs/configuration/#specifying-a-jekyll-environment-at-build-time) to production.
|
||||
{: .notice--warning}
|
||||
|
||||
### Site Base URL
|
||||
|
||||
This little option causes all kinds of confusion in the Jekyll community. If you're not hosting your site as a GitHub Pages Project or in a subfolder (eg: `/blog`), then don't mess with it.
|
||||
|
||||
In the case of the Minimal Mistakes demo site it's hosted on GitHub at <https://mmistakes.github.io/minimal-mistakes>. To correctly set this base path I'd use `url: "https://mmistakes.github.io"` and `baseurl: "/minimal-mistakes"`.
|
||||
|
||||
For more information on how to properly use `site.url` and `site.baseurl` as intended by the Jekyll maintainers, check [Parker Moore's post on the subject](https://byparker.com/blog/2014/clearing-up-confusion-around-baseurl/).
|
||||
|
||||
**Note:** When using `baseurl` remember to include it as part of your path when testing your site locally. Values of `url: ` and `baseurl: "/blog"` would make your local site visible at `http://localhost:4000/blog` and not `http://localhost:4000`.
|
||||
{: .notice--warning}
|
||||
|
||||
### Site Repository
|
||||
|
||||
Add your repository name with organization to your site's configuration file, `_config.yml`.
|
||||
|
||||
```yaml
|
||||
repository: "username/repo-name"
|
||||
```
|
||||
|
||||
"NWO" stands for "name with owner." It is GitHub lingo for the username of the owner of the repository plus a forward slash plus the name of the repository, e.g. '**mmistakes/minimal-mistakes**', where '**mmistakes**' is the owner and '**minimal-mistakes**' is the repository name.
|
||||
|
||||
Your `site.github.*` fields should fill in like normal. If you run Jekyll with the --verbose flag, you should be able to see all the API calls made.
|
||||
|
||||
If you don't set `repository` correctly you may see the following error when trying to `serve` or `build` your Jekyll site:
|
||||
|
||||
**Liquid Exceptions:** No repo name found. Specify using `PAGES_REPO_NWO` environment variables, `repository` in your configuration, or set up `origin` git remote pointing to your github.com repository.
|
||||
{: .notice--danger}
|
||||
|
||||
For more information on how `site.github` data can be used with Jekyll check out [`github-metadata`'s documentation](https://github.com/jekyll/github-metadata).
|
||||
|
||||
### Site Default Teaser Image
|
||||
|
||||
To assign a fallback teaser image used in the "**Related Posts**" module, place a graphic in the `/assets/images/` directory and add the filename to `_config.yml` like so:
|
||||
|
||||
```yaml
|
||||
teaser: /assets/images/500x300.png
|
||||
```
|
||||
|
||||
This image can be overridden at anytime by applying the following to a document's YAML Front Matter.
|
||||
|
||||
```yaml
|
||||
header:
|
||||
teaser: /assets/images/my-awesome-post-teaser.jpg
|
||||
```
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-teaser-images-example.jpg' | absolute_url }}" alt="teaser image example">
|
||||
<figcaption>Example of teaser images found in the related posts module.</figcaption>
|
||||
</figure>
|
||||
|
||||
### Breadcrumb Navigation (Beta)
|
||||
|
||||
Enable breadcrumb links to help visitors better navigate deep sites. Because of the fragile method of implementing them they don't always produce accurate links reliably. For best results:
|
||||
|
||||
1. Use a category based permalink structure e.g. `permalink: /:categories/:title/`
|
||||
2. Manually create pages for each category or use a plugin like [jekyll-archives][jekyll-archives] to auto-generate them. If these pages don't exist breadcrumb links to them will be broken.
|
||||
|
||||
![breadcrumb navigation example]({{ "/assets/images/mm-breadcrumbs-example.jpg" | absolute_url }})
|
||||
|
||||
```yaml
|
||||
breadcrumbs: true # disabled by default
|
||||
```
|
||||
|
||||
Breadcrumb start link text and separator character can both be changed in the [UI Text data file]({{ "/docs/ui-text/" | absolute_url }}).
|
||||
|
||||
### Reading Time
|
||||
|
||||
Enable estimated reading time snippets with `read_time: true` in YAML Front Matter. `200` has been set as the default words per minute value --- which can be changed by adjusting `words_per_minutes: ` in `_config.yml`.
|
||||
|
||||
![reading time example]({{ "/assets/images/mm-read-time-example.jpg" | absolute_url }})
|
||||
|
||||
Instead of adding `read_time: true` to each post, apply as a default in `_config.yml` like so:
|
||||
|
||||
```yaml
|
||||
defaults:
|
||||
# _posts
|
||||
- scope:
|
||||
path: ""
|
||||
type: posts
|
||||
values:
|
||||
read_time: true
|
||||
```
|
||||
|
||||
To disable reading time for a post, add `read_time: false` its YAML Front Matter to override what was set in `_config.yml`.
|
||||
|
||||
### Comments
|
||||
|
||||
[**Disqus**](https://disqus.com/), [**Discourse**](https://www.discourse.org/), [**Facebook**](https://developers.facebook.com/docs/plugins/comments), **Google+**, and static-based commenting via [**Staticman**](https://staticman.net/) are built into the theme. First set the comment provider you'd like to use:
|
||||
|
||||
| Name | Comment Provider |
|
||||
| ---- | ---------------- |
|
||||
| **disqus** | Disqus |
|
||||
| **discourse** | Discourse |
|
||||
| **facebook** | Facebook Comments |
|
||||
| **google-plus** | Google+ Comments |
|
||||
| **staticman** | Staticman |
|
||||
| **custom** | Other |
|
||||
|
||||
Then add `comments: true` to each document you want comments visible on.
|
||||
|
||||
Instead of adding YAML Front Matter to each document, apply as a default in `_config.yml`. To enable comments for all posts:
|
||||
|
||||
```yaml
|
||||
defaults:
|
||||
# _posts
|
||||
- scope:
|
||||
path: ""
|
||||
type: posts
|
||||
values:
|
||||
comments: true
|
||||
```
|
||||
|
||||
If you add `comments: false` to a post's YAML Front Matter it will override the default and disable comments for just that post.
|
||||
|
||||
##### Disqus
|
||||
|
||||
To use Disqus you'll need to create an account and [shortname](https://help.disqus.com/customer/portal/articles/466208-what-s-a-shortname-). Once you have both update `_config.yml` to:
|
||||
|
||||
```yaml
|
||||
comments:
|
||||
provider: "disqus"
|
||||
disqus:
|
||||
shortname: "your-disqus-shortname"
|
||||
```
|
||||
|
||||
##### Discourse
|
||||
|
||||
For guidance on how to set up Discourse for embedding comments from a topic on a post page, [consult this guide](https://meta.discourse.org/t/embedding-discourse-comments-via-javascript/31963).
|
||||
|
||||
```yaml
|
||||
comments:
|
||||
provider : "discourse"
|
||||
discourse:
|
||||
server : # meta.discourse.org
|
||||
```
|
||||
|
||||
|
||||
##### Facebook Comments
|
||||
|
||||
To enable Facebook Comments choose how many comments you'd like visible per post and the color scheme of the widget.
|
||||
|
||||
```yaml
|
||||
comments:
|
||||
provider : "facebook"
|
||||
facebook:
|
||||
appid : # optional
|
||||
num_posts : # 5 (default)
|
||||
colorscheme : # "light" (default), "dark"
|
||||
```
|
||||
|
||||
##### Static-Based Comments via Staticman
|
||||
|
||||
Transform user comments into `_data` files that live inside of your GitHub repository by enabling Staticman.
|
||||
|
||||
###### Add Staticman as a Collaborator
|
||||
|
||||
1. Allow Staticman push access to your GitHub repository by clicking on **Settings**, then the **Collaborators** tab and adding `staticmanapp` as a collaborator.
|
||||
2. To accept the pending invitation visit: `https://api.staticman.net/v1/connect/{your GitHub username}/{your repository name}`. Consult the Staticman "[Get Started](https://staticman.net/get-started)" guide for more info.
|
||||
|
||||
###### Configure Staticman
|
||||
|
||||
Default settings have been provided in `_config.yml`. The important ones to set are `provider: "staticman"` and `branch`. View the [full list of configurations](https://github.com/eduardoboucas/staticman#jekyll-configuration).
|
||||
|
||||
**Branch setting:** This is the branch comment files will be sent to via pull requests. If you host your site on GitHub Pages it will likely be `master` unless your repo is setup as a project --- use `gh-pages` in that case.
|
||||
{: .notice--info}
|
||||
|
||||
```yaml
|
||||
comments:
|
||||
provider: "staticman"
|
||||
staticman:
|
||||
allowedFields : ['name', 'email', 'url', 'message']
|
||||
branch : # "master", "gh-pages"
|
||||
commitMessage : "New comment."
|
||||
filename : comment-{@timestamp}
|
||||
format : "yml"
|
||||
moderation : true
|
||||
path : "_data/comments/{options.slug}"
|
||||
requiredFields : ['name', 'email', 'message']
|
||||
transforms:
|
||||
email : "md5"
|
||||
generatedFields:
|
||||
date:
|
||||
type : "date"
|
||||
options:
|
||||
format : "iso8601" # "iso8601" (default), "timestamp-seconds", "timestamp-milliseconds"
|
||||
```
|
||||
|
||||
###### Comment Moderation
|
||||
|
||||
By default comment moderation is enabled in `_config.yml`. As new comments are submitted Staticman will send a pull request. Merging these in will approve the comment, close the issue, and automatically rebuild your site (if hosted on GitHub Pages).
|
||||
|
||||
To skip this moderation step simply set `moderation: false`.
|
||||
|
||||
**ProTip:** Create a GitHub webhook that sends a `POST` request to the following payload URL `https://api.staticman.net/v1/webhook` and triggers a "Pull request" event to delete Staticman branches on merge.
|
||||
{: .notice--info}
|
||||
|
||||
![pull-request webhook]({{ "/assets/images/mm-staticman-pr-webhook.jpg" | absolute_url }})
|
||||
|
||||
##### Other Comment Providers
|
||||
|
||||
To use another provider not included with the theme set `provider: "custom"` then add their embed code to `_includes/comments-providers/custom.html`.
|
||||
|
||||
### Custom Feed URL
|
||||
|
||||
By default the theme links to `feed.xml` generated in the root of your site by the **jekyll-feed** plugin. To link to an externally hosted feed update `atom_feed` in `_config.yml` like so:
|
||||
|
||||
```yaml
|
||||
atom_feed:
|
||||
path: "http://feeds.feedburner.com/youFeedname"
|
||||
```
|
||||
|
||||
**Note:** By default the site feed is linked in two locations: inside the [`<head>` element]({{ gh_repo }}/master/_includes/head.html) and at the bottom of every page in the [site footer](https://github.com/{{ site.repository }}/master/_includes/footer.html).
|
||||
{: .notice--info}
|
||||
|
||||
### SEO, Social Sharing, and Analytics Settings
|
||||
|
||||
All optional, but a good idea to take the time setting up to improve SEO and links shared from the site.
|
||||
|
||||
#### Google Search Console
|
||||
|
||||
Formerly known as [Google Webmaster Tools](https://www.google.com/webmasters/tools/), add your [verification code](https://support.google.com/analytics/answer/1142414?hl=en) like so: `google_site_verification: "yourVerificationCode"`.
|
||||
|
||||
**Note:** You likely won't have to do this if you verify site ownership through **Google Analytics** instead.
|
||||
{: .notice--warning}
|
||||
|
||||
#### Bing Webmaster Tools
|
||||
|
||||
There are several ways to [verify site ownership](https://www.bing.com/webmaster/help/how-to-verify-ownership-of-your-site-afcfefc6) --- the easiest adding an authentication code to your config file.
|
||||
|
||||
Copy and paste the string inside of `content`:
|
||||
|
||||
```html
|
||||
<meta name="msvalidate.01" content="0FC3FD70512616B052E755A56F8952D" />
|
||||
```
|
||||
|
||||
Into `_config.yml`
|
||||
|
||||
```yaml
|
||||
bing_site_verification: "0FC3FD70512616B052E755A56F8952D"
|
||||
```
|
||||
|
||||
#### Alexa
|
||||
|
||||
To [claim your site](http://www.alexa.com/siteowners/claim) with Alexa add the provided verification ID `alexa_site_verification: "yourVerificationID"`.
|
||||
|
||||
#### Yandex
|
||||
|
||||
To verify site ownership copy and paste the string inside of `name`:
|
||||
|
||||
```html
|
||||
<meta name='yandex-verification' content='2132801JL' />
|
||||
```
|
||||
|
||||
Into `_config.yml`
|
||||
|
||||
```yaml
|
||||
yandex_site_verification: "2132801JL"
|
||||
```
|
||||
|
||||
#### Twitter Cards and Facebook Open Graph
|
||||
|
||||
To improve the appearance of links shared from your site to social networks like Twitter and Facebook be sure to configure the following.
|
||||
|
||||
##### Site Twitter Username
|
||||
|
||||
Twitter username for the site. For pages that have custom author Twitter accounts assigned in their YAML Front Matter or data file, they will be attributed as a **creator** in the Twitter Card.
|
||||
|
||||
For example if my site's Twitter account is `@mmistakes-theme` I would add the following to `_config.yml`
|
||||
|
||||
```yaml
|
||||
twitter:
|
||||
username: "mmistakes-theme"
|
||||
```
|
||||
|
||||
And if I assign `@mmistakes` as an author account it will appear in the Twitter Card along with `@mmistakes-theme`, attributed as a creator of the page being shared.
|
||||
|
||||
**Note**: You need to [apply for Twitter Cards](https://dev.twitter.com/docs/cards) and validate they're working on your site before they will begin showing up.
|
||||
{: .notice--warning}
|
||||
|
||||
##### Facebook Open Graph
|
||||
|
||||
If you have a Facebook ID or publisher page add them:
|
||||
|
||||
```yaml
|
||||
facebook:
|
||||
app_id: # A Facebook app ID
|
||||
publisher: # A Facebook page URL or ID of the publishing entity
|
||||
```
|
||||
|
||||
While not part a part of Open Graph, you can also add your Facebook username for use in the sidebar and footer.
|
||||
|
||||
```yaml
|
||||
facebook:
|
||||
username: "michaelrose" # https://www.facebook.com/michaelrose
|
||||
```
|
||||
|
||||
**ProTip:** To debug Open Graph data use [this tool](https://developers.facebook.com/tools/debug/og/object?q=https%3A%2F%2Fmademistakes.com) to test your pages. If content changes aren't reflected you will probably have to hit the **Fetch new scrape information** button to refresh.
|
||||
{: .notice--info}
|
||||
|
||||
##### Open Graph Default Image
|
||||
|
||||
For pages that don't have a `header.image` assigned in their YAML Front Matter, `site.og_image` will be used as a fallback. Use your logo, icon, avatar or something else that is meaningful. Just make sure it is place in the `/assets/images/` folder, a minimum size of 120px by 120px, and less than 1MB in file size.
|
||||
|
||||
```yaml
|
||||
og_image: /assets/images/site-logo.png
|
||||
```
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-twitter-card-summary-image.jpg' | absolute_url }}" alt="Twitter Card summary example">
|
||||
<figcaption>Example of a image placed in a Summary Card.</figcaption>
|
||||
</figure>
|
||||
|
||||
Documents who have a `header.image` assigned in their YAML Front Matter will appear like this when shared on Twitter and Facebook.
|
||||
|
||||
<figure>
|
||||
<img src="{{ '/assets/images/mm-twitter-card-summary-large.jpg' | absolute_url }}" alt="page shared on Twitter">
|
||||