Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions 404.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
layout: default
title: 404 - Page not found
---
404 - Page not found
====================
Sorry, we couldn’t find the requested URL. You can try again by going [back to the homepage]({{ site.baseurl }}).
6 changes: 5 additions & 1 deletion _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ author:
url: "http://www.jacoporabolini.com"

# Build settings
baseurl: /emerald/ # Change this to your relative path (ex: /blog/), or leave just a /
baseurl: /emerald # Change this to your relative path (ex: /blog/), or leave just a /
markdown: kramdown
source: .
destination: ./_site
Expand All @@ -25,6 +25,10 @@ defaults:
values:
layout: "post"

# Plugins
gems:
- jekyll-paginate

# Custom variables
version: "1.1.0"

Expand Down
2 changes: 1 addition & 1 deletion _includes/footer.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<footer><span>@2015 - Emerald</span></footer>
<footer class="footer"><span>@2015 - Emerald</span></footer>
4 changes: 2 additions & 2 deletions _includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
<title>{%if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}</title>

<!-- CSS & fonts -->
<link rel="stylesheet" href="{{ "css/main.css" | prepend: site.baseurl }}">
<link href='http://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700,900,400italic%7CSignika:700,300,400,600' rel='stylesheet' type='text/css'>
<link rel="stylesheet" href="{{ "/css/main.css" | prepend: site.baseurl | replace: '//', '/' }}">
<link href='https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700,900,400italic%7CSignika:700,300,400,600' rel='stylesheet' type='text/css'>

<!-- RSS -->
<link href="/atom.xml" type="application/atom+xml" rel="alternate" title="ATOM Feed" />
Expand Down
2 changes: 1 addition & 1 deletion _includes/header.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<header id="header">
<a href="{{ site.baseurl }}">
<img src="{{ "img/emerald.svg" | prepend: site.baseurl }}" alt="Emerald Logo">
<img src="{{ "/img/emerald.svg" | prepend: site.baseurl | replace: '//', '/' }}" alt="Emerald Logo">
<h1>emerald</h1>
</a>
</header>
2 changes: 1 addition & 1 deletion _includes/menu.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<!-- Nav pages -->
{% for page in site.pages %}
{% if page.layout == "page" %}
<a href="{{ site.baseurl }}{{ page.url }}" title="{{ page.title }}">{{ page.title }}</a>
<a href="{% if site.baseurl == "/" %}{{ page.url }}{% else %}{{ page.url | prepend: site.baseurl }}{% endif %}" title="{{ page.title }}">{{ page.title }}</a>
{% endif %}
{% endfor %}

Expand Down
2 changes: 1 addition & 1 deletion _includes/script.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<script src="{{ "js/main.js" | prepend: site.baseurl }}"></script>
<script src="{{ "/js/main.js" | prepend: site.baseurl | replace: '//', '/' }}"></script>
2 changes: 1 addition & 1 deletion _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
{% include menu.html %}

<!-- Icon menu -->
<a href="#" {% if site.reverse == true %}id="nav-menu-left"{% else %}id="nav-menu"{% endif %}>
<a {% if site.reverse == true %}id="nav-menu-left"{% else %}id="nav-menu"{% endif %}>
<div id="menu"></div>
</a>

Expand Down
4 changes: 4 additions & 0 deletions _posts/2019-03-18-small-text.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
title: Small text
---
This is an example of a blog post with small amount of text.
21 changes: 21 additions & 0 deletions _sass/layout.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
/* -- General Layout -- */

/* Required for footer to stick to the bottom */
html, body {
height: 100%;
}

/* Navigation */

#nav, #nav-left {
Expand Down Expand Up @@ -253,3 +258,19 @@ footer {
text-align: center;
padding: 0.6667em 0;
}

#wrap {
min-height:100%;
position:relative;
padding-bottom: 105px;
}

.footer {
padding: 25px 0;
background-color: $main-color;
color: $background-color;
text-align: center;
position: absolute;
width: 100%;
bottom: 0;
}
2 changes: 1 addition & 1 deletion _sass/mixin.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

@mixin icon-position($position) {
display: block;
position: absolute;
position: fixed;
top: 35px;
#{$position}: 25px;
z-index: 10;
Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
{% for post in paginator.posts %}

<li class="post">
<h2><a href="{{ site.baseurl }}{{ post.url }}">{{ post.title }}</a></h2>
<h2><a href="{% if site.baseurl == "/" %}{{ post.url }}{% else %}{{ post.url | prepend: site.baseurl }}{% endif %}">{{ post.title }}</a></h2>
<time datetime="{{ post.date | date_to_xmlschema }}" class="by-line">{{ post.date | date_to_string }}</time>
<p>{{ post.content | strip_html | truncatewords:50 }}</p>
</li>
Expand Down
19 changes: 18 additions & 1 deletion readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,23 @@ After extracting the content from the folder into the selected directory, you ca

Additionally it is possible to fork the repository and use Github Pages as hosting. By following this way it will be enough to change the ``baseurl`` value into the ``_config.yml`` file, with the directory name of your project (for example /blog) or simply with a "/" (slash) if you want install Emerald in the root.

### Options
Starting from the 1.1.0 version, you can customize Emerald thanks to a few options. Now it is possible to set a custom header tag by setting the related option in the ``_config.yml`` file to "true". Then insert your custom code into the ``header-custom.html`` file.
In the same way, you can customize the footer of the navigation menu, by setting to "true" the related option and put your code into the ``nav-footer-custom.html`` file.
Moreover it is now possible to select a reverse option that allows to move the navigation menu to the left side, by setting it to "true".

### Colors
The basic colors are set into the ``base.scss`` file:
- $main-color: used for the menu, title, link and footer
- $background-color: used for background and links in the navigation menu
- $text-color: used for text and title in posts and pages

To customize the colors, just set the values in HEX, RGB (or RGBa) or any other format accepted by CSS.

### Navigation menu
Starting from the 1.1.0 version, the links inside the navigation menu are autogenerated from pages having the layout set to ``page``.
You can set custom links, by putting in the ``<a>`` tag into the ``link.html`` file.

### Branch
Emerald has two branch:
- ``master``: is for developing pourpose.
Expand All @@ -29,7 +46,7 @@ Last but not least: the [Jekyll documentation](http://jekyllrb.com) is the best
### Jacopo Rabolini

- Web site: [www.jacoporabolini.com](http://www.jacoporabolini.com)
- Google+: [+JacopoRabolini](https://plus.google.com/u/0/+JacopoRabolini/posts)
- Linkedin: [linkedin.com/in/jacopo-rabolini/](https://www.linkedin.com/in/jacopo-rabolini/)

## License
Emerald is released under [MIT License](license.md).