Hello! Welcome to the repository of Open Neuroscience website.
If you are interested in the website's layout, go to Sleek, the open source layout we used to create this site.
-
this project started in 2013, as a way for me to keep track of what kind of open source projects for neuroscience were available out there, and also to serve as a central repository for people who might be interested in this intersection.
-
Luckly over time more people contributed to this project:
sleek
├── _includes # theme includes
├── _js # javascript files (by default jquery will be included with the scripts inside)
├── _layouts # theme layouts (see below for details)
├── _pages # pages folder (empty by default)
├── _posts # blog posts
├── _sass # Sass partials
├── assets
| ├── css # minified css files
| ├── img # images and icons used for the template
| └── js # bundled and minified files from _js folder
├── _config.yml # sample configuration
├── gulpfile.js # gulp tasks (tasks autorunner)
├── index.md # sample home page (blog page)
└── package.json # gulp tasks
You can modify the theme by changing the settings in _config.yml
.
Create a new Markdown file such as 2017-01-13-my-post.md in _post folder. Configure YAML Front Matter (stuff between ---
):
---
layout: post # needs to be post
title: Getting Started with Sleek # title of your post
featured-img: sleek #optional - if you want you can include hero image
---
In case you want to add a hero image to the post, apart from changing featured-img in YAML, you also need to add the image file to the project. To do so, just upload an image in .jpg format to _img
folder. The name must before the .jpg file extension has to match with featured-img in YAML. Next, run gulp img
from command line to generate optimized version of the image and all the thumbnails. You have to restart the jekyll server to see the changes.
Sleek uses Lazy Sizes. Lazy Loader for loading images. Check the link for more info. Lazy Sizes doesnt’t require any configuration and it’s going to be included in your bundled js file.
The home page is located under index.md file. To change the content or design you have to edit the default.html file in _layouts
folder.
In order to add a new page, create a new html or markdown file under root directory or inside _pages folder. To add a link in navigation add it in _config.yml
:
# THEME SETTINGS
navigation: # Navigation links
- {name: 'Home', link: '/'}
- {name: 'About', link: '/about'}
- {name: 'Contact', link: '/contact'}
name
is the text that will be shown and link, well, it's a link.
Sleek comes with jekyll-seo-tag
plugin preinstalled to make sure your website gets the most useful meta tags. See usage to know how to set it up.
Additionally, in _config.yml
you can find custom theme settings under # THEME SETTINGS
comment. Here's a brief overview of those custom settings:
navigation
- collection of links that will be shown in the headertagline
- text that will be displayed on the homepage under the heading.hero_img
- background image of the homepage hero section
Bug reports and pull requests are welcome on GitHub at https://github.com/janczizikow/sleek. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.
To set up your environment to develop this theme, run bundle install
and npm install
.
The theme is setup just like a normal Jekyll site! Check out file structure overview for details. To test the theme, run gulp
and open your browser at http://localhost:3000
. This starts a Jekyll server using the theme. Add pages, documents, data, etc. like normal to test the theme's contents. As you make modifications to the theme and to the content, your site will regenerate and you should see the changes in the browser after a refresh, just like normal.
The theme is available as open source under the terms of the MIT License.