Skip to content

Commit fab30f3

Browse files
authored
Add files via upload
1 parent be52596 commit fab30f3

File tree

100 files changed

+7621
-10
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

100 files changed

+7621
-10
lines changed

.gitignore

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
*.gem
2+
*.sublime-project
3+
*.sublime-workspace
4+
.bundle
5+
.DS_Store
6+
.jekyll-metadata
7+
.sass-cache
8+
_asset_bundler_cache
9+
_site
10+
codekit-config.json
11+
Gemfile.lock
12+
node_modules
13+
npm-debug.log*
14+
15+

.gitlab-ci.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# requiring the environment of Ruby 2.3.x
2+
image: ruby:2.3
3+
# add bundle cache to 'vendor' for speeding up builds
4+
cache:
5+
paths:
6+
- vendor/
7+
before_script:
8+
- bundle install --path vendor
9+
# the 'pages' job will deploy and build your site to the 'public' path
10+
pages:
11+
stage: deploy
12+
script:
13+
- bundle exec jekyll build -d public/
14+
artifacts:
15+
paths:
16+
- public
17+
only:
18+
- master # this job will affect only the 'master' branch

Gemfile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
source "https://rubygems.org"
2+
gemspec
3+
gem "jekyll", "~> 4.3.1"
4+
gem "kramdown-parser-gfm"

LICENSE.txt

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2017 Lingyi Hu
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 179 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,179 @@
1-
# recursionlab.github.io
1+
<img src="https://img.shields.io/liberapay/receives/verfasor.svg?logo=liberapay">
2+
3+
**NOTE: The netlify demo is broken as I don't use the service anymore. The repo should work OOB nonetheless. Please create an issue if it isn't working as intended.**
4+
5+
# SparrowX - Jekyll Netlify CMS Boilerplate
6+
7+
A clean minimal Jekyll theme for SEO-focused writers. The theme loads fast and it's Netlify CMS-ready. SparrowX is a remix of sparrow by [lingxz](https://github.com/lingxz/sparrow).
8+
9+
[Live Demo](https://sparrowx.netlify.app)
10+
11+
- [Features](#features)
12+
- [Install](#install)
13+
- [Up and running with Netlify CMS](#up-and-running-with-netlify-cms)
14+
- [General configuration](#general-configuration)
15+
- [Disqus](#disqus)
16+
- [Google analytics](#google-analytics)
17+
- [Collections](#collections)
18+
- [Pagination](#pagination)
19+
- [Navigation](#navigation)
20+
- [Front matter defaults](#front-matter-defaults)
21+
- [Other](#other)
22+
- [Credits](#credits)
23+
24+
## Screenshot
25+
26+
![](screenshot.png)
27+
28+
## Website Speed Test
29+
30+
![](pagespeed.png)
31+
32+
## Original Sparrow Features
33+
34+
- Fully compatible with Github Pages
35+
- Configurable and responsive multi layer menu, adapted from [slimmenu](https://github.com/adnantopal/slimmenu)
36+
- Disqus integration
37+
- [Font Awesome icons](http://fontawesome.io/) included
38+
- Google analytics
39+
- Social sharing using [rrssb](https://www.rrssb.ml/)
40+
- 404 page included
41+
- Atom feed generated with [jekyll-feed](https://github.com/jekyll/jekyll-feed)
42+
- Pagination enabled for blog using [jekyll-paginate](https://github.com/jekyll/jekyll-paginate)
43+
- Basic SEO with Facebook Open Graph tags and Twitter cards
44+
45+
## SparrowX Features
46+
47+
- Fully compatible with Netlify CMS (one-click setup).
48+
- Added new custom variables like updated, headerimage, feature-img, sitemap and tag.
49+
- The theme renders system font-stack.
50+
- Compressed JS.
51+
- Improved load time and reduced file requests.
52+
- _redirects feature
53+
54+
## Install
55+
56+
Just fork this repo and replace the posts with your own. Also rename the sample poetry collection to replace it with your own collection, or just delete it if you don't need to use collections. The example is poetry, but you can easily revamp this into essays, short stories, portfolio, or whatever your creative work is.
57+
58+
59+
## Up and running with Netlify CMS
60+
61+
[Click here](https://sparrowx.netlify.app/netlify-cms-jekyll-setup) to read the documentation for Netlify CMS.
62+
63+
For customization, see below.
64+
65+
### General configuration
66+
67+
Customize these values in the `_config.yml` file:
68+
69+
```yaml
70+
title : "SparrowX"
71+
description : "A clean minimal Jekyll theme for SEO-focused writers."
72+
favicon : "/assets/images/image.png" # You can use base64 encoded images.
73+
url : "https://sparrowx.m1q.net" # the base hostname & protocol for your site e.g. "https://mmistakes.github.io"
74+
baseurl : "" # the subpath of your site, e.g. "/blog" leave blank if no subpath
75+
76+
# Site Author
77+
author:
78+
name : "Mighil" # appears in the footer and atom feed
79+
```
80+
81+
82+
### Disqus
83+
84+
To activate Disqus, fill in your disqus shortname:
85+
86+
```yaml
87+
comments : true # set it to false to disable comments
88+
disqus:
89+
shortname : your_shortname
90+
```
91+
92+
### Google analytics
93+
94+
Enable google analytics by filling in your tracking ID:
95+
96+
```yaml
97+
analytics:
98+
google:
99+
tracking_id : # add your google tracking id here
100+
```
101+
102+
### Collections
103+
104+
If you are using collections, be sure to replace this with your collection name:
105+
106+
```yaml
107+
collections:
108+
poetry:
109+
output: true
110+
permalink: /:collection/:title/
111+
```
112+
113+
### Pagination
114+
115+
Currently, pagination is set to a the blog page. Unfortunately Jekyll does not yet support pagination on multiple pages.
116+
117+
If you want to paginate on a different page, simply change the `paginate_path` value in the config file and create the relevant page.
118+
119+
```yaml
120+
paginate: 5 # amount of posts to show
121+
paginate_path: "/blog/page:num/"
122+
timezone: # http://en.wikipedia.org/wiki/List_of_tz_database_time_zones
123+
```
124+
125+
### Navigation
126+
127+
You can change the navigation links in `_data/navigation.yml`.
128+
129+
### Front matter defaults
130+
131+
At the bottom of the config file, you can also set [front matter defaults](https://jekyllrb.com/docs/configuration/#front-matter-defaults) so that you don't have to repeat the same front matter for every post. This is an example:
132+
133+
```yaml
134+
# Front matter defaults
135+
defaults:
136+
# _pages
137+
- scope:
138+
path: ""
139+
type: pages
140+
values:
141+
layout: page
142+
comments: false
143+
# _posts
144+
- scope:
145+
path: ""
146+
type: posts
147+
values:
148+
layout: post
149+
comments: true
150+
share: true
151+
# _poetry
152+
- scope:
153+
path: ""
154+
type: poetry
155+
values:
156+
layout: post
157+
share: false
158+
```
159+
160+
### How tags work
161+
162+
You should create specific .md files within ```/tag/``` before using the variable.
163+
164+
### Other
165+
166+
To enhance SEO, you can add your twitter username to `_config.yml`.
167+
168+
You can also add an image path for the `og_image` value in the config file, for a default open graph sharing image. This value can be overridden in individual posts by using **headerimage** variable.
169+
170+
Your default image Netlify CMS uploads will go to /images/.
171+
172+
For the various config options see the [sample config file for the demo site](https://github.com/mighildotcom/sparrowx/blob/master/_config.yml)
173+
174+
The color schemes and fonts can also be customized through scss, by editing the relevant variable in `_variables.scss`.
175+
176+
## Credits
177+
178+
- Base theme sparrow by [lingxz](https://github.com/lingxz/sparrow)
179+
- Icon made by [Freepik](https://www.freepik.com/) from www.flaticon.com

_config.yml

Lines changed: 127 additions & 3 deletions
Large diffs are not rendered by default.

_data/navigation.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# main links
2+
main:
3+
- title: "Documentation"
4+
url: /documentation
5+
- title: "Netlify CMS"
6+
url: /netlify-cms-jekyll-setup
7+
- title: "Blog"
8+
url: /blog
9+
- title: "Submenu"
10+
url: /
11+
children:
12+
- title: "Sitemap"
13+
url: /sitemap.xml
14+
- title: "RSS"
15+
url: /feed.xml

_includes/analytics.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{% if site.analytics and page.analytics != false %}
2+
3+
<script>
4+
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
5+
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
6+
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
7+
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
8+
9+
ga('create', '{{ site.analytics.google.tracking_id }}', 'auto');
10+
ga('send', 'pageview');
11+
</script>
12+
13+
{% endif %}

_includes/breadcrumbs.html

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{% if page.collection != 'posts' %}
2+
{% assign path_type = nil %}
3+
{% assign crumb_path = '/' %}
4+
{% else %}
5+
{% assign crumb_path = site.categories.path %}
6+
{% endif %}
7+
8+
<nav class="breadcrumbs">
9+
<ol itemscope itemtype="http://schema.org/BreadcrumbList">
10+
{% assign crumbs = page.url | split: '/' %}
11+
{% assign i = 1 %}
12+
{% for crumb in crumbs offset: 1 %}
13+
{% if forloop.first %}
14+
<li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
15+
<a href="{{ site.url }}{{ site.baseurl }}/" itemprop="item"><span itemprop="name">Home</span></a>
16+
<meta itemprop="position" content="{{ i }}" />
17+
</li>
18+
<span class="sep">/</span>
19+
{% endif %}
20+
{% if forloop.last %}
21+
<li class="current">{{ page.title }}</li>
22+
{% else %}
23+
{% assign i = i | plus: 1 %}
24+
<li itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
25+
<a href="{{ crumb | downcase | replace: '%20', '-' | prepend: path_type | prepend: crumb_path | absolute_url }}" itemprop="item"><span itemprop="name">{{ crumb | replace: '-', ' ' | replace: '%20', ' ' | capitalize }}</span></a>
26+
<meta itemprop="position" content="{{ i }}" />
27+
</li>
28+
<span class="sep">/</span>
29+
{% endif %}
30+
{% endfor %}
31+
</ol>
32+
</nav>

_includes/collecttags.html

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{% assign rawtags = "" %}
2+
{% for post in site.posts %}
3+
{% assign ttags = post.tags | join:'|' | append:'|' %}
4+
{% assign rawtags = rawtags | append:ttags %}
5+
{% endfor %}
6+
{% assign rawtags = rawtags | split:'|' | sort %}
7+
8+
{% assign site.tags = "" %}
9+
{% for tag in rawtags %}
10+
{% if tag != "" %}
11+
{% if tags == "" %}
12+
{% assign tags = tag | split:'|' %}
13+
{% endif %}
14+
{% unless tags contains tag %}
15+
{% assign tags = tags | join:'|' | append:'|' | append:tag | split:'|' %}
16+
{% endunless %}
17+
{% endif %}
18+
{% endfor %}

0 commit comments

Comments
 (0)