Skip to content

Commit

Permalink
Add support for twitch profiles
Browse files Browse the repository at this point in the history
Fixes #256

Signed-off-by: Matt Stratton <[email protected]>
  • Loading branch information
mattstratton committed Apr 5, 2020
1 parent a8e14f1 commit 9322ae2
Show file tree
Hide file tree
Showing 11 changed files with 37 additions and 1 deletion.
11 changes: 10 additions & 1 deletion REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ These are the social network parameters for your overall site. They should be se
|------------------|----------|------------------------------------------------------------------------------------------------------------------|----------------------|
| `github` | No | GitHub username only. | "mattstratton" |
| `gitlab` | No | GitLab username only. | "mattstratton" |
| `facebook` | No | Name of the Facebook page (not the URL). | "Arresteddevops" |
| `facebook` | No | Name of the Facebook page (not the URL). | "Arresteddevops" |
| `facebook_admin` | No | This needs to be one or more page admins to get domain insights. | ["500557137","1234"] |
| `twitter` | No | Twitter name without the `@` sign. | "arresteddevops" |
| `twitter_domain` | Yes | This domain shows in twitter cards as "View on `twitter_domain`". | "arresteddevops.com" |
Expand All @@ -98,6 +98,7 @@ These are the social network parameters for your overall site. They should be se
| `instagram` | No | Instagram username. | "nozzleio" |
| `youtube` | No | Name of the YouTube channel. | "arresteddevops" |
| `linkedin` | No | LinkedIn profile name. This is the part that comes after the `https://www.linkedin.com/in/` in your profile URL. | "mattstratton" |
| `twitch` | No | Twitch channel/profile for your site. This is the part that comes after `https://twitch.tv/` | "mattstratton" |

### Host/Author Parameters

Expand Down Expand Up @@ -129,6 +130,7 @@ You also will set the social parameters (all are optional) under `[params.author
| `pinterest` | No | Pinterest username. | "nozzleio" |
| `instagram` | No | Instagram username. | "nozzleio" |
| `youtube` | No | Name of the user's YouTube profile. | mattstratton |
| `twitch` | No | Name of the user's Twitch profile. | mattstratton |
| `linkedin` | No | LinkedIn profile name. This is the part that comes after the `https://www.linkedin.com/in/` in your profile URL. | "mattstratton" |
| `homepage` | No | The user's website, including the `http` at the beginning. | "https://www.mattstratton.com" |

Expand Down Expand Up @@ -174,6 +176,7 @@ I recommend the following permalink settings, although the theme will work just
about = "/:filename/"
episode = "/:filename/"
```

### Menus

Castanet supports menus with up to one submenu per menu item. The menu name must be "Main", and the menus are sorted based upon their identifier. At this time, you must have at least one menu item, or the theme will error out.
Expand Down Expand Up @@ -289,6 +292,7 @@ Graphical user interface influencer value proposition startup hackathon iPad ana
| `youtube` | No | The ID of the YouTube video (not the full URL). This will display the video on the episode page, and if you are using the row layout, it will display for the latest episode. | "8ClZXJsgpHY" |
| `truncate` | No | The number of characters to truncate the summary on the row layout.. The default value (if not set) is 600 characters. | "700" |
| `guid` | No | A fixed, globally unique identifier for the episode which should never change. If one is not specified the URL of the `podcast_file` will be used instead. | "aae20190418" |

## Guests

If you don't have guests on your episodes, feel free to ignore this section.
Expand All @@ -309,6 +313,8 @@ Facebook = "johndoe"
Linkedin = "johndoe"
GitHub = "johndoe"
Thumbnail = "img/guest/jdoe.jpg"
Twitch = "johndoe"
YouTube = "johndoe"
Aka = ["jsmith", "jsmith2"]
+++
Spoon fresh pie ingredients groceries oranges luncheon farm. Broth chick peas Chinese food indie foods. Cream heating cheese food locally grown first class caramelize restaurant grocery shopping savory chick peas. Recommendations lovely starter soda herbes fridge chocolate eat better quinoa sausage java chef locally grown wholesome. Broil sweet sushi lasagna cream indian. Desert sour vegetarian sous-chef soda oven tasty eat better rice recommendations relish salt butter grape. Grocery shopping delicious Chinese food beets conserve ginger. Authentic blend drink sausage. Groceries sour desert. Take away lasagna consumer luncheon scent cookie beer groceries meals restaurants java cheese vegan chick peas.
Expand All @@ -327,6 +333,7 @@ Spoon fresh pie ingredients groceries oranges luncheon farm. Broth chick peas Ch
| `Pinterest` | No | Pinterest profile name. | "mattstratton" |
| `Instagram` | No | Instagram profile name. | "mattstratton" |
| `YouTube` | No | YouTube profile/channel name | "mattstratton" |
| `Twitch` | No | Twitch profile/channel name | "mattstratton" |
| `Aka` | No | The name(s) of another guest file which is an alternate identity for this guest (for example, if the bio changes, name changes, etc). This should be set in both directions (i.e., the `Aka` field should be set on `mstratton.md` and `mstratton2.md` pointing to each other). | Aka = ["jsmith", "jsmith2"] |

## Hosts
Expand All @@ -353,6 +360,7 @@ Thumbnail = "img/host/johndoe.png"
Pinterest = "johndoe"
Instagram = "johndoe"
YouTube = "johndoe"
Twitch = "johndoe"
+++
Spoon fresh pie ingredients groceries oranges luncheon farm. Broth chick peas Chinese food indie foods. Cream heating cheese food locally grown first class caramelize restaurant grocery shopping savory chick peas. Recommendations lovely starter soda herbes fridge chocolate eat better quinoa sausage java chef locally grown wholesome. Broil sweet sushi lasagna cream indian. Desert sour vegetarian sous-chef soda oven tasty eat better rice recommendations relish salt butter grape. Grocery shopping delicious Chinese food beets conserve ginger. Authentic blend drink sausage. Groceries sour desert. Take away lasagna consumer luncheon scent cookie beer groceries meals restaurants java cheese vegan chick peas.
```
Expand All @@ -369,6 +377,7 @@ Spoon fresh pie ingredients groceries oranges luncheon farm. Broth chick peas Ch
| `Pinterest` | No | Pinterest profile name. | "mattstratton" |
| `Instagram` | No | Instagram profile name. | "mattstratton" |
| `YouTube` | No | YouTube profile/channel name | "mattstratton" |
| `Twitch` | No | Twitch profile/channel name | "mattstratton" |

## Sponsors

Expand Down
1 change: 1 addition & 0 deletions archetypes/guest.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ Thumbnail = ""
Pinterest = ""
Instagram = ""
YouTube = ""
Twitch = ""
#Aka = []
+++
1 change: 1 addition & 0 deletions archetypes/host.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ Thumbnail = ""
Pinterest = ""
Instagram = ""
YouTube = ""
Twitch = ""
+++
2 changes: 2 additions & 0 deletions exampleSite/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ disqusShortname = ""
instagram = "nozzleio"
youtube = "arresteddevops"
linkedin = "mattstratton"
twitch = "mattstratton"

[params.authors]
[params.authors.Matt]
Expand All @@ -127,6 +128,7 @@ disqusShortname = ""
pinterest = "mattstratton"
instagram = "instagram"
youtube = "mattstratton"
twitch = "mattstratton"
[params.authors.Trevor]
name = "Trevor Hess"
thumbnail = "https://www.arresteddevops.com/img/trevor.png"
Expand Down
1 change: 1 addition & 0 deletions exampleSite/content/guest/scox.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@ Thumbnail = "img/guest/scox.jpg"
Pinterest = ""
Instagram = ""
YouTube = ""
Twitch = "mattstratton"
+++
non et ad nesciunt dignissimos quod suscipit similique alias. fugiat aut asperiores delectus corporis.
1 change: 1 addition & 0 deletions exampleSite/content/host/mstratton.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@ Thumbnail = "img/host/matt.png"
Pinterest = "mattstratton"
Instagram = "mattstratton"
YouTube = ""
Twitch = "mattstratton"
+++
Matt Stratton is a solutions architect at Chef, where he demonstrates how Chef’s automation platform provides speed and flexibility to clients’ infrastructure. He is devoted to concepts like Continuous Delivery and Infrastructure as Code, and his license plate actually says “DevOps”. He lives in Chicago and has an unhealthy obsession with Doctor Who, Firefly, and Game of Thrones. And whiskey.
3 changes: 3 additions & 0 deletions layouts/guest/list.html
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ <h3><a href = "{{(printf "guest/%s" .File.BaseFileName) | absURL }}">{{ .Title }
{{ with .Params.YouTube }}
<a href = "https://www.youtube.com/{{ . }}"><i class="fab fa-youtube-square fa-2x"></i></a>
{{ end }}
{{ with .Params.Twitch }}
<a href = "https://twitch.tv/{{ . }}"><i class="fab fa-twitch fa-2x"></i></a>
{{ end }}
</div>
</div>
{{ end }}
Expand Down
5 changes: 5 additions & 0 deletions layouts/guest/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,11 @@ <h1>{{ title .Title }}</h1>
<i class="fab fa-youtube-square fa-2x"></i>
</a>
{{ end }}
{{ if .Params.Twitch }}
<a href="https://www.twitch.tv/{{ .Params.Twitch}}">
<i class="fab fab fa-twitch fa-2x"></i>
</a>
{{ end }}
</div>
</div>
</div>
Expand Down
5 changes: 5 additions & 0 deletions layouts/host/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,11 @@ <h1>{{ title .Title }}</h1>
<i class="fab fa-youtube-square fa-2x"></i>
</a>
{{ end }}
{{ if .Params.Twitch }}
<a href="https://twitch.tv/{{ .Params.Twitch}}">
<i class="fab fa-twitch fa-2x"></i>
</a>
{{ end }}
</div>
</div>
</div>
Expand Down
5 changes: 5 additions & 0 deletions layouts/partials/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,11 @@
<a class = "social-links" href="https://gitlab.com/{{ .Site.Params.social.gitlab }}"><i class="fab fa-gitlab fa-2x"></i></a>
</li>
{{ end }}
{{ if (isset .Site.Params.social "twitch" ) }}
<li>
<a class = "social-links" href="https://twitch.tv/{{ .Site.Params.social.twitch }}"><i class="fab fa-twitch fa-2x"></i></a>
</li>
{{ end }}
</ul>
</div>
</div>
Expand Down
3 changes: 3 additions & 0 deletions layouts/partials/hosts.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ <h3><a href = "{{(printf "host/%s" .File.BaseFileName) | absURL }}">{{ .Title }}
{{ with .Params.YouTube }}
<a href = "https://www.youtube.com/{{ . }}"><i class="fab fa-youtube-square fa-2x"></i></a>
{{ end }}
{{ with .Params.Twitch }}
<a href = "https://twitch.tv/{{ . }}"><i class="fab fa-twitch fa-2x"></i></a>
{{ end }}
</div>
</div>
{{- end -}}
Expand Down

0 comments on commit 9322ae2

Please sign in to comment.