simple-purple-theme

simple-purple-theme

Responsive, Fluid typography, SEO for Google Search, Jekyll theme for GitHub Pages

simple-purple-theme

This is a Jekyll gem-based theme built to be 100% compatible with GitHub Pages.

It was created for calinradoni.github.io. It have its own demo pages and documentation at simple-purple-theme.

I wanted a simple, Javascript free theme.

Installation and usage

Here are three ways to use the theme:

  • as a remote theme for GitHub Pages
  • as a Ruby gem
  • by copying the files

As a remote theme for GitHub Pages

For GitHub Pages, having a content like this for the Gemfile:

source "https://rubygems.org"
gem 'github-pages', group: :jekyll_plugins

you only have to add this entry:

remote_theme: "CalinRadoni/simple-purple-theme"

to the _config.yml file. Make sure that no other theme: or remote-theme: entries are present in _config.yml.

Note: you can specify the version or commit to use by appending @ and the git reference, like this: CalinRadoni/[email protected]. Without any supplemental specification the last version from the master branch will be used.

If you start in an empty directory you need:

  1. _config.yml, Gemfile and index.html files. Copy the ones from theme's demo directory as a starting point;
  2. the pages directory. Create it and add the files from theme's docs/pages in it;
  3. the _posts directory. Create it and put your posts in it;
  4. the assets/img directory to hold your images. Copy the logo.svg from the demo directory in it.
├── assets
│   └── img
│       └── logo.svg (from theme's demo directory)
├── _posts
│   └── (your posts)
├── pages
│   └── (demo files from theme's docs directory)
├── _config.yml (from theme's demo directory)
├── Gemfile (from theme's demo directory)
└── index.html (from theme's demo directory)

To test it run form the directory with _config.yml:

# first time only, you need to run these two commands to install required files
bundle config set path 'vendor/bundle'
bundle install

# start a web server for your site
bundle exec jekyll serve

then open your browser at http://127.0.0.1:4000/demo/.

As a gem - NOT TESTED

Warning: This section is work-in-progress !

Add this line to your Jekyll site's Gemfile:

gem "simple-purple-theme"

And add this line to your Jekyll site's _config.yml (Make sure that no other theme: or remote-theme: entries are present):

theme: simple-purple-theme

And then execute:

$ bundle

Or install it yourself as:

$ gem install simple-purple-theme

By copying the files

Fork or copy theme's files from github.com/CalinRadoni/simple-purple-theme.

If you start in an empty directory you need:

  1. the following theme directories: _includes, _layouts, _sass and assets;
  2. the pages directory. Create it and add the files from theme's docs/pages in it;
  3. the _posts directory. Create it and put your posts in it;
  4. the assets/img directory to hold your images. Copy the logo.svg from the demo directory in it;
  5. _config.yml, Gemfile and index.html files. Copy the ones from theme's demo directory as a starting point;
  6. comment the remote_theme: entry from the _config.yml file.
├── assets
│   ├── css
│   │   └── (files from theme)
│   └── img
│       └── logo.svg (from theme's demo directory)
├── _includes
│   └── (files from theme)
├── _layouts
│   └── (files from theme)
├── _sass
│   └── (files from theme)
├── _posts
│   └── (your posts)
├── pages
│   └── (demo files from theme's docs directory)
├── _config.yml (from theme's demo directory)
├── Gemfile (from theme's demo directory)
└── index.html (from theme's demo directory)

To test it run form the directory with _config.yml:

# first time only, you need to run these two commands to install required files
bundle config set path 'vendor/bundle'
bundle install

# start a web server for your site
bundle exec jekyll serve

then open your browser at http://127.0.0.1:4000/demo/.

Docs

For detailed documentation go to simple-purple-theme quick-start.

Warning: the documentation is work-in-progress.

Test and theme development

Use the create_test_theme.sh script to create the spt_test directory with a copy of this theme and the demo site.

Modify the files as you wish and serve them locally with bundle exec jekyll serve to see the result.

Development

To set up your environment to develop this theme, run:

bundle config set path 'vendor/bundle'
bundle install

When the theme is released, only the files tracked with Git from:

  • _includes
  • _layouts
  • _sass
  • assets

directories and these files from root directory:

  • LICENSE.txt
  • README.md
  • index.html

will be bundled in the Ruby gem. This list can be changed by editing the regexp in simple-purple-theme.gemspec accordingly.

Contributing

As much as I want to adopt the Contributor Covenant code of conduct, I am afraid that my spare time may be a real stopper sometime.

You can submit an issue or make a pull request. For pull requests please follow GitHub flow.

Contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The theme is available as open source under the terms of the MIT License.