Skip to content

Commit

Permalink
Merge pull request academicpages#3 from daattali/master
Browse files Browse the repository at this point in the history
merge updates
  • Loading branch information
epwalsh authored Aug 9, 2016
2 parents 819a437 + 613367b commit b907c47
Show file tree
Hide file tree
Showing 9 changed files with 260 additions and 15 deletions.
20 changes: 13 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Beautiful Jekyll

**Beautiful Jekyll** is a ready-to-use template to help you create an awesome website quickly. Perfect for personal blogs or simple project websites. [Check out a demo](http://deanattali.com/beautiful-jekyll) of what you'll get after just two minutes. You can also look at [my personal website](http://deanattali.com) to see it in use, or see examples of websites other people created using this theme [here](#featured-users-success-stories).
> *Copyright 2016 [Dean Attali](http://deanattali.com). Licensed under the MIT license.*
**Beautiful Jekyll** is a ready-to-use template to help you create an awesome website quickly. Perfect for personal blogs or simple project websites. [Check out a demo](http://deanattali.com/beautiful-jekyll) of what you'll get after just two minutes. You can also look at [my personal website](http://deanattali.com) to see it in use, or see examples of websites other people created using thcois theme [here](#featured-users-success-stories).

If you need a bit of help or have comments, feel free to [contact me](http://deanattali.com/aboutme#contact). Even if you don't have anything important to say but found this useful, I'd love to [hear about it](http://deanattali.com/aboutme#contact). Lastly, if you like this theme, please consider [supporting me](https://www.paypal.me/daattali/20) if you want to make me extra happy. :)

Expand Down Expand Up @@ -102,7 +104,11 @@ If the `disqus` parameter is set in the configuration file, then all blog posts

#### Adding Google Analytics to track page views

Beautiful Jekyll lets you easily add Google Analytics to all your pages. This will let you track all sorts of information about visits to your website, such as how many times each page is viewed and where (geographically) your users come from. To add Google Analytics, simply sign up to [Google Analytics](http://www.google.com/analytics/) to obtain your Google Tracking ID, and add this tracking ID to the `google_analytics` parameter in `_config.yml`.
Beautiful Jekyll lets you easily add Google Analytics to all your pages. This will let you track all sorts of information about visits to your website, such as how many times each page is viewed and where (geographically) your users come from. To add Google Analytics, simply sign up to [Google Analytics](http://www.google.com/analytics/) to obtain your Google Tracking ID, and add this tracking ID to the `google_analytics` parameter in `_config.yml`.

#### Sharing blog posts on social media

By default, all blog posts will have buttons at the bottom of the post to allow people to share the current page on Twitter/Facebook/LinkedIn. You can choose to enable/disable specific social media websites in the `_config.yml` file. You can also turn off the social media buttons on specific blog posts using `social-share: false` in the YAML front matter.

#### Page types

Expand All @@ -123,6 +129,7 @@ bigimg | Include a large full-width image at the top of the page. You can
comments | If you want do add Disqus comments to a specific page, use `comments: true`. Comments are automatically enabled on blog posts; to turn comments off for a specific post, use `comments: false`. Comments only work if you set your Disqus id in the `_config.yml` file.
show-avatar | If you have an avatar configured in the `_config.yml` but you want to turn it off on a specific page, use `show-avatar: false`. If you want to turn it off by default, locate the line `show-avatar: true` in the file `_config.yml` and change the `true` to `false`; then you can selectively turn it on in specific pages using `show-avatar: true`.
share-img | If you want to specify an image to use when sharing the page on Facebook or Twitter, then provide the image's full URL here.
social-share | If you don't want to show buttons to share a blog post on social media, use `social-share: false` (this feature is turned on by default).
layout | What type of page this is (default is `blog` for blog posts and `page` for other pages. You can use `minimal` if you don't want a header and footer)
js | List of local JavaScript files to include in the page (eg. `/js/mypage.js`)
ext-js | List of external JavaScript files to include in the page (eg. `//cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.2/underscore-min.js`)
Expand Down Expand Up @@ -164,10 +171,9 @@ Want your website featured here? [Contact me](http://deanattali.com/aboutme#cont
| [joecks.github.io/clipboard-actions](http://joecks.github.io/clipboard-actions/) | Clipboard Actions - an Android app |
| [embedded.guide](http://embedded.guide) | Writing an Embedded OS |
| [blabel.github.io](http://blabel.github.io) | Library for canonicalising blank node labels in RDF graphs |
| [organicrails.github.io](http://organicrails.github.io) | Ruby on Rails tutorial |
| [esentire.github.io](https://esentire.github.io) | Blog about threats and malware |
| [reactionic.github.io](http://reactionic.github.io) | Create iOS and Android apps with React and Ionic |
| [ja2-stracciatella.github.io](http://ja2-stracciatella.github.io) | Jagged Alliance 2 Stracciatella |
| [PatientOutcomeFunding.org](http://www.patientoutcomefunding.org/) | Patient Outcome Funding |

#### Personal websites

Expand All @@ -176,10 +182,8 @@ Want your website featured here? [Contact me](http://deanattali.com/aboutme#cont
| [deanattali.com](http://deanattali.com) | Dean Attali | Creator of Beautiful Jekyll |
| [ouzor.github.io](http://ouzor.github.io) | Juuso Parkkinen | Data scientist |
| [derekogle.com](http://derekogle.com/) | Derek Ogle | Professor of Mathematical Sciences and Natural Resources |
| [tomwhite.io](http://tomwhite.io) | Thomas White | Ecology PhD student |
| [trappmartin.github.io](http://trappmartin.github.io) | Martin Trapp | Machine learning researcher |
| [melyanna.github.io](http://melyanna.github.io/) | Melyanna | Shows off her nice art |
| [chaitanyajoshi.xyz](http://chaitanyajoshi.xyz/) | Chaitanya Joshi | Computer Science undergrad |
| [chauff.github.io](http://chauff.github.io/) | Claudia Hauff | Professor at Delft University of Technology |
| [kootenpv.github.io](http://kootenpv.github.io/) | Pascal van Kooten | Data analytics |
| [sjackman.ca](http://sjackman.ca) | Shaun Jackman | PhD candidate in bioinformatics |
Expand Down Expand Up @@ -211,7 +215,9 @@ I'd also like to thank [Dr. Jekyll's Themes](http://drjekyllthemes.github.io/),

If you find anything wrong or would like to contribute in any way, feel free to create a pull request/open an issue/send me a message. Any comments are welcome!

If you do fork this project to use as a template for your site, I would appreciate if you keep the link in the footer to this project. I've noticed that several people who forked this repo removed the attribution and I would prefer to get the recognition if you do use this :)
Thank you to [all contributors](https://github.com/daattali/beautiful-jekyll/graphs/contributors). Special thanks to the following people with non-trivial contributions (in chronological order): [@hristoyankov](https://github.com/hristoyankov), [@jamesonzimmer](https://github.com/jamesonzimmer), [@XNerv](https://github.com/XNerv), [@epwalsh](https://github.com/epwalsh), [@rtlee9](https://github.com/rtlee9).

If you do fork or clone this project to use as a template for your site, I would appreciate if you keep the link in the footer to this project. I've noticed that several people who forked this repo removed the attribution and I would prefer to get the recognition if you do use this :)

### Known limitations

Expand Down
14 changes: 13 additions & 1 deletion _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,10 @@ author:
github: yourname # eg. daattali
twitter: yourname # eg. daattali
linkedin: yourname # eg. daattali
xing: yourname # eg. daattali
stackoverflow: yourlink # eg. "3943160/daattali"

instagram: yourname # eg. daattali

# Select which links to show in the footer
footer-links-active:
rss: false
Expand All @@ -55,7 +57,16 @@ footer-links-active:
twitter: true
github: true
linkedin: false
xing: false
stackoverflow: false
instagram: false

# Select which share links to show in posts
share-links-active:
twitter: true
facebook: true
google: false
linkedin: true

# How to display the link to the website in the footer
# Remove this if you don't want a link in the footer
Expand Down Expand Up @@ -90,6 +101,7 @@ defaults:
values:
layout: "post"
comments: true # add comments to all blog posts
social-share: true # add social media sharing buttons to all blog posts
-
scope:
path: "" # all files
Expand Down
20 changes: 20 additions & 0 deletions _includes/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,16 @@
</span>
</a>
</li>
{% endif %}
{% if site.author.xing and site.footer-links-active.xing %}
<li>
<a href="https://www.xing.com/profile/{{ site.author.xing }}" title="Xing">
<span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-xing fa-stack-1x fa-inverse"></i>
</span>
</a>
</li>
{% endif %}
{% if site.author.stackoverflow and site.footer-links-active.stackoverflow %}
<li>
Expand All @@ -62,6 +72,16 @@
</span>
</a>
</li>
{% endif %}
{% if site.author.instagram and site.footer-links-active.instagram %}
<li>
<a href="https://www.instagram.com/{{ site.author.instagram }}" title="Instagram">
<span class="fa-stack fa-lg">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-instagram fa-stack-1x fa-inverse"></i>
</span>
</a>
</li>
{% endif %}
{% if site.footer-links-active.rss %}
<li>
Expand Down
46 changes: 46 additions & 0 deletions _includes/social-share.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<!-- Check if any share-links are active -->
{% assign any-share-links = false %}
{% for links in site.share-links-active %}
{% if links[1] == true %}
{% assign any-share-links = true %}
{% endif %}
{% endfor %}

{% if any-share-links %}
<section id = "social-share-section">

<!--- Share on Twitter -->
{% if site.share-links-active.twitter %}
<a href="https://twitter.com/intent/tweet?text={{ site.url }}{{ page.url }}"
class="btn btn-social-icon btn-twitter" title="Share on Twitter">
<span class="fa fa-fw fa-twitter" aria-hidden="true"></span>
</a>
{% endif %}

<!--- Share on Facebook -->
{% if site.share-links-active.facebook %}
<a href="https://www.facebook.com/sharer/sharer.php?u={{ site.url }}{{ page.url }}"
class="btn btn-social-icon btn-facebook" title="Share on Facebook">
<span class="fa fa-fw fa-facebook" aria-hidden="true"></span>
</a>
{% endif %}

<!--- Share on Google Plus -->
{% if site.share-links-active.google %}
<a href="https://plus.google.com/share?url={{ site.url }}{{ page.url }}"
class="btn btn-social-icon btn-google" title="Share on Google+">
<span class="fa fa-fw fa-google-plus" aria-hidden="true"></span>
</a>
{% endif %}

<!--- Share on LinkedIn -->
{% if site.share-links-active.linkedin %}
<a href="https://www.linkedin.com/shareArticle?mini=true&url={{ site.url }}{{ page.url }}"
class="btn btn-social-icon btn-linkedin" title="Share on LinkedIn">
<span class="fa fa-fw fa-linkedin" aria-hidden="true"></span>
</a>
{% endif %}

</section>

{% endif %}
1 change: 1 addition & 0 deletions _layouts/base.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
common-css:
- "/css/bootstrap.min.css"
- "/css/bootstrap-social.css"
- "/css/main.css"
common-ext-css:
- "//maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css"
Expand Down
2 changes: 1 addition & 1 deletion _layouts/minimal.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

<body>

<div role="main" class="container">
<div role="main" class="container main-content">
{{ content }}
</div>

Expand Down
19 changes: 13 additions & 6 deletions _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,14 @@
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">

<article role="main" class="blog-post">
{{ content }}
</article>

{% if page.tags.size > 0 %}
<div class="blog-tags">
Tags:
Tags:
{% if site.link-tags %}
{% for tag in page.tags %}
<a href="/tag/{{ tag }}">{{ tag }}</a>
Expand All @@ -22,6 +24,11 @@
{% endif %}
</div>
{% endif %}

{% if page.social-share %}
{% include social-share.html %}
{% endif %}

<ul class="pager blog-pager">
{% if page.previous.url %}
<li class="previous">
Expand All @@ -34,12 +41,12 @@
</li>
{% endif %}
</ul>
{% if page.comments %}

{% if page.comments %}
<div class="disqus-comments">
{% include disqus.html %}
{% include disqus.html %}
</div>
{% endif %}
{% endif %}
</div>
</div>
</div>
</div>
Loading

0 comments on commit b907c47

Please sign in to comment.