Skip to content

Commit

Permalink
(#6) Add solution for favicon (#189)
Browse files Browse the repository at this point in the history
Prior to this commit the favicon for a castanet site was
not set by the theme. This commit adds a tag for the
favicon to the header partial, defaulting to `icons/favicon.ico`
but allowing an override in the site configuration.

Resolves #6

Signed-off-by: Michael T Lombardi <michael.t.lombardi@outlook.com>
  • Loading branch information
michaeltlombardi authored and mattstratton committed Aug 3, 2018
1 parent ea22083 commit 43a3d45
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions REFERENCE.md
Expand Up @@ -46,6 +46,7 @@ These should be set under the `[params]` section:
| `truncate` | No | The number of characters to truncate the summary on the row layout. This can be overridden per-episode as well. The default value (if not set) is 600 characters. | "700" |
| `custom_css` | No | Array of custom CSS files for over-riding theme settings or adding your own classes. These files should be put into your `static` directory (not the `static` directory of the theme). | ["custom.css", "other_custom.css"] |
| `about_logo` | No | The logo (250px x 250px) you would like to appear on your About page. If not set, this will default to your iTunes image. This path should be relative to your main URL, for example, a file put in your `static` directory. This path should not start with a `/`. | "img/my_logo.png" |
| `favicon` | No | The favicon file you would like to use for your site. If not set, this will default to the file `icons/favicon.ico`. This file should be put into your static directory (not the `static` directory of the theme). | "icon/favicon_x32.png" |
| `copyright_notice` | Yes | Your copyright information for the footer of the page. Can contain Markdown. | `"Copyright 2016 [Matt Stratton](https://www.mattstrattion.io)"` |
| `itunes_subscribe` | No | The URL of your podcast in the iTunes store. | "http://itunes.apple.com/us/podcast/arrested-devops/id773888088?mt=2&uo=4&at=11lsCi" |
| `android_subscribe` | No | The URL for your podcast for Android users. You can generate this URL at [Subscribe on Android](https://subscribeonandroid.com). | "http://subscribeonandroid.com/feeds.podtrac.com/VGAulpN7MY1U" |
Expand Down
5 changes: 5 additions & 0 deletions layouts/partials/head_includes.html
@@ -1,3 +1,8 @@
{{ if isset $.Site.Params "favicon"}}
<link rel="icon" href="{{ $.Site.Params.favicon | absURL }}">
{{ else }}
<link rel="icon" href="icons/favicon.ico">
{{ end }}
{{ if isset $.Site.Params "site_theme"}}
<link href="{{ printf "css/%s.css" $.Site.Params.site_theme | absURL}}" rel="stylesheet">
{{ else }}
Expand Down

0 comments on commit 43a3d45

Please sign in to comment.