Skip to content

Commit d4f35ba

Browse files
authored
Merge branch 'master' into header_pages_config
2 parents f3e091f + bcabdbd commit d4f35ba

File tree

13 files changed

+129
-46
lines changed

13 files changed

+129
-46
lines changed

History.markdown

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,36 @@
1-
## HEAD
1+
## 2.1.0 / 2016-11-15
2+
3+
### Minor Enhancements
4+
5+
* Update gemspec to require at least Jekyll 3.3 (#59)
6+
* Use `absolute_url` filter for disqus (#66)
7+
* replace `example/index.html` with `example/index.md` (#58)
8+
9+
### Development Fixes
10+
11+
* Example should require Jekyll 3.3 (#61)
12+
13+
## 2.0.0 / 2016-10-06
214

315
### Minor Enhancements
416

517
* priority to site.url when site.github.url is available (#46)
618
* Move contents of the index.html page to the 'home' layout (#48)
19+
* Use new `absolute_url` and `relative_url` filters in minima (#57)
720

821
### Development Fixes
922

1023
* Use standardized tab size of 2 spaces (#44)
1124

25+
### Major Enhancements
26+
27+
* move `css/` directory from jekyll into `assets/` (#43)
28+
29+
### Bug Fixes
30+
31+
* Fix html proofer errors (#49)
32+
* Update gem regex to include new `assets` directory (#54)
33+
1234
## 1.2.0 / 2016-09-12
1335

1436
### Minor Enhancements

README.md

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,31 @@ And then execute:
2222
2323
$ bundle
2424
25-
Then add a `css/main.scss` file based on the following template, don't forget to include the frontmatter:
2625
27-
```css
28-
---
29-
---
26+
## Usage
3027
31-
@import "minima";
32-
```
28+
### Customization
29+
30+
To override the default structure and style of minima, simply create the concerned directory at the root of your site, copy the file you wish to customize to that directory, and then edit the file.
31+
e.g., to override the [`_includes/head.html `](_includes/head.html) file to specify a custom style path, create an `_includes` directory, copy `_includes/head.html` from minima gem folder to `<yoursite>/_includes` and start editing that file.
3332

34-
You can choose to override the [`_includes/head.html `](_includes/head.html) file to specify a custom style path.
33+
The site's default CSS has now moved to a new place within the gem itself, [`assets/main.scss`](assets/main.scss). To **override the default CSS**, the file has to exist at your site source. Do either of the following:
34+
- Create a new instance of `main.scss` at site source.
35+
- Create a new file `main.scss` at `<your-site>/assets/`
36+
- Add the frontmatter dashes, and
37+
- Add `@import "minima";`, to `<your-site>/assets/main.scss`
38+
- Add your custom CSS.
39+
- Download the file from this repo
40+
- Create a new file `main.scss` at `<your-site>/assets/`
41+
- Copy the contents at [assets/main.scss](assets/main.scss) onto the `main.scss` you just created, and edit away!
42+
- Copy directly from Minima 2.0 gem
43+
- Go to your local minima gem installation directory ( run `bundle show minima` to get the path to it ).
44+
- Copy the `assets/` folder from there into the root of `<your-site>`
45+
- Change whatever values you want, inside `<your-site>/assets/main.scss`
3546

36-
## Enabling comments (via Disqus)
47+
--
48+
49+
### Enabling comments (via Disqus)
3750

3851
Optionally, if you have a Disqus account, you can tell Jekyll to use it to show a comments section below each post.
3952

@@ -50,7 +63,9 @@ Comments are enabled by default and will only appear in production, i.e., `JEKYL
5063

5164
If you don't want to display comments for a particular post you can disable them by adding `comments: false` to that post's YAML Front Matter.
5265

53-
## Enabling Google Analytics
66+
--
67+
68+
### Enabling Google Analytics
5469

5570
To enable Google Anaytics, add the following lines to your Jekyll site:
5671

_includes/disqus_comments.html

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,10 @@
11
{% if page.comments != false and jekyll.environment == "production" %}
2-
{% if site.url %}
3-
{% assign disqus_url = page.url | prepend: site.url %}
4-
{% elsif site.github.url %}
5-
{% assign disqus_url = page.url | prepend: site.github.url %}
6-
{% endif %}
72

83
<div id="disqus_thread"></div>
94
<script>
105
var disqus_config = function () {
11-
this.page.url = '{{ disqus_url }}';
12-
this.page.identifier = '{{ disqus_url }}';
6+
this.page.url = '{{ page.url | absolute_url }}';
7+
this.page.identifier = '{{ page.url | absolute_url }}';
138
};
149

1510
(function() {

_includes/footer.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ <h2 class="footer-heading">{{ site.title | escape }}</h2>
1414
{{ site.title | escape }}
1515
{% endif %}
1616
</li>
17-
<li><a href="mailto:{{ site.email }}">{{ site.email }}</a></li>
17+
{% if site.email %}
18+
<li><a href="mailto:{{ site.email }}">{{ site.email }}</a></li>
19+
{% endif %}
1820
</ul>
1921
</div>
2022

_includes/head.html

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,9 @@
66
<title>{% if page.title %}{{ page.title | escape }}{% else %}{{ site.title | escape }}{% endif %}</title>
77
<meta name="description" content="{{ page.excerpt | default: site.description | strip_html | normalize_whitespace | truncate: 160 | escape }}">
88

9-
{% assign custom_url = site.url | append: site.baseurl %}
10-
{% assign full_base_url = custom_url | default: site.github.url %}
11-
<link rel="stylesheet" href="{{ "/css/main.css" | prepend: full_base_url }}">
12-
<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: full_base_url }}">
13-
<link rel="alternate" type="application/rss+xml" title="{{ site.title | escape }}" href="{{ "/feed.xml" | prepend: full_base_url }}">
9+
<link rel="stylesheet" href="{{ "/assets/main.css" | relative_url }}">
10+
<link rel="canonical" href="{{ page.url | replace:'index.html','' | absolute_url }}">
11+
<link rel="alternate" type="application/rss+xml" title="{{ site.title | escape }}" href="{{ "/feed.xml" | relative_url }}">
1412

1513
{% if jekyll.environment == 'production' and site.google_analytics %}
1614
{% include google-analytics.html %}

_includes/header.html

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,24 @@
11
<header class="site-header" role="banner">
22

33
<div class="wrapper">
4-
5-
{% assign custom_url = site.url | append: site.baseurl %}
6-
{% assign full_base_url = custom_url | default: site.github.url %}
74
{% assign default_paths = site.pages | map: "path" %}
85
{% assign page_paths = site.header_pages | default: default_paths %}
9-
<a class="site-title" href="{{ full_base_url }}/">{{ site.title | escape }}</a>
6+
<a class="site-title" href="{{ "/" | relative_url }}">{{ site.title | escape }}</a>
107

118
<nav class="site-nav">
12-
<a href="#" class="menu-icon">
9+
<span class="menu-icon">
1310
<svg viewBox="0 0 18 15" width="18px" height="15px">
1411
<path fill="#424242" d="M18,1.484c0,0.82-0.665,1.484-1.484,1.484H1.484C0.665,2.969,0,2.304,0,1.484l0,0C0,0.665,0.665,0,1.484,0 h15.031C17.335,0,18,0.665,18,1.484L18,1.484z"/>
1512
<path fill="#424242" d="M18,7.516C18,8.335,17.335,9,16.516,9H1.484C0.665,9,0,8.335,0,7.516l0,0c0-0.82,0.665-1.484,1.484-1.484 h15.031C17.335,6.031,18,6.696,18,7.516L18,7.516z"/>
1613
<path fill="#424242" d="M18,13.516C18,14.335,17.335,15,16.516,15H1.484C0.665,15,0,14.335,0,13.516l0,0 c0-0.82,0.665-1.484,1.484-1.484h15.031C17.335,12.031,18,12.696,18,13.516L18,13.516z"/>
1714
</svg>
18-
</a>
15+
</span>
1916

2017
<div class="trigger">
2118
{% for path in page_paths %}
2219
{% assign my_page = site.pages | where: "path", path | first %}
2320
{% if my_page.title %}
24-
<a class="page-link" href="{{ my_page.url | prepend: full_base_url }}">{{ my_page.title | escape }}</a>
21+
<a class="page-link" href="{{ my_page.url | relative_url }}">{{ my_page.title | escape }}</a>
2522
{% endif %}
2623
{% endfor %}
2724
</div>

_layouts/home.html

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,18 @@ <h1 class="page-heading">Posts</h1>
88

99
{{ content }}
1010

11-
{% assign custom_url = site.url | append: site.baseurl %}
12-
{% assign full_base_url = custom_url | default: site.github.url %}
13-
1411
<ul class="post-list">
1512
{% for post in site.posts %}
1613
<li>
1714
<span class="post-meta">{{ post.date | date: "%b %-d, %Y" }}</span>
1815

1916
<h2>
20-
<a class="post-link" href="{{ post.url | prepend: full_base_url }}">{{ post.title | escape }}</a>
17+
<a class="post-link" href="{{ post.url | relative_url }}">{{ post.title | escape }}</a>
2118
</h2>
2219
</li>
2320
{% endfor %}
2421
</ul>
2522

26-
<p class="rss-subscribe">subscribe <a href="{{ "/feed.xml" | prepend: full_base_url }}">via RSS</a></p>
23+
<p class="rss-subscribe">subscribe <a href="{{ "/feed.xml" | relative_url }}">via RSS</a></p>
2724

2825
</div>

assets/main.scss

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
# Only the main Sass file needs front matter (the dashes are enough)
3+
---
4+
@charset "utf-8";
5+
6+
// Our variables
7+
$base-font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
8+
$base-font-size: 16px;
9+
$base-font-weight: 400;
10+
$small-font-size: $base-font-size * 0.875;
11+
$base-line-height: 1.5;
12+
13+
$spacing-unit: 30px;
14+
15+
$text-color: #111;
16+
$background-color: #fdfdfd;
17+
$brand-color: #2a7ae2;
18+
19+
$grey-color: #828282;
20+
$grey-color-light: lighten($grey-color, 40%);
21+
$grey-color-dark: darken($grey-color, 25%);
22+
23+
// Width of the content area
24+
$content-width: 800px;
25+
26+
$on-palm: 600px;
27+
$on-laptop: 800px;
28+
29+
// Minima also includes a mixin for defining media queries.
30+
// Use media queries like this:
31+
// @include media-query($on-palm) {
32+
// .wrapper {
33+
// padding-right: $spacing-unit / 2;
34+
// padding-left: $spacing-unit / 2;
35+
// }
36+
// }
37+
38+
// Import partials from the `minima` theme.
39+
@import "minima";

example/Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
source "https://rubygems.org"
22

3-
gem "jekyll", "~> 3.2"
3+
gem "jekyll", "~> 3.3"
44
gem "minima", path: "../"

example/css/main.scss

Lines changed: 0 additions & 4 deletions
This file was deleted.

0 commit comments

Comments
 (0)