Compare commits

..

No commits in common. "main" and "07f1b3ecfd4202a69847d47c89ece4e4d01278c4" have entirely different histories.

15 changed files with 106 additions and 58 deletions

36
.github/workflows/gh-pages.yml vendored Normal file
View File

@ -0,0 +1,36 @@
name: github pages
on:
push:
branches:
- main
pull_request:
jobs:
deploy:
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
path: risotto
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: '0.85.0'
# extended: true
- name: Build
working-directory: ./risotto/exampleSite
run: hugo --minify --themesDir="../.." -t risotto
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
if: ${{ github.ref == 'refs/heads/main' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./risotto/exampleSite/public
cname: risotto.joeroe.io

View File

@ -1,26 +1,26 @@
# Thurstylark Wiki Hugo Theme # risotto
The style and layout for [Thurstylark's Wiki](https://wiki.thurstylark.com/). risotto is a minimalist, responsive [hugo](https://gohugo.io) theme inspired by terminal ricing aesthetics.
A fork of [risotto](https://github.com/joeroe/risotto). ![Screenshot of the risotto theme](https://raw.githubusercontent.com/joeroe/risotto/master/images/screenshot.png)
## Install ## Install
The easiest way to install the theme is to clone this repository into your site's `themes` directory: The easiest way to install the theme is to clone this repository into your site's `themes` directory:
```shell ```shell
git clone https://git.thurstylark.com/thurstylark/tlwiki-hugo-theme.git themes/tlwiki git clone https://github.com/joeroe/risotto themes/risotto
``` ```
If your site is already a git repository, you can add the theme as a submodule instead: If your site is already a git repository, you can add the theme as a submodule instead:
```shell ```shell
git submodule add https://git.thurstylark.com/thurstylark/tlwiki-hugo-theme.git themes/tlwiki git submodule add https://github.com/joeroe/risotto.git themes/risotto
``` ```
## Configure ## Configure
To use the theme, add `theme = tlwiki` to your site's `config.toml` or `config.yaml`. To use the theme, add `theme = risotto` to your site's `config.toml` or `config.yaml`.
See `exampleSite/config.toml` for the theme-specific parameters you need to add to your site's `config.toml` or `config.yaml` to configure the theme. See `exampleSite/config.toml` for the theme-specific parameters you need to add to your site's `config.toml` or `config.yaml` to configure the theme.
@ -29,7 +29,7 @@ See `exampleSite/config.toml` for the theme-specific parameters you need to add
If you installed the theme using `git clone`, pull the repository to get the latest version: If you installed the theme using `git clone`, pull the repository to get the latest version:
```shell ```shell
cd themes/tlwiki cd themes/risotto
git pull git pull
``` ```
@ -39,8 +39,3 @@ Or, if you added it as a git submodule:
git submodule update --remote git submodule update --remote
``` ```
## License
See: [./LICENSE](./LICENSE)
TL;DR: MIT. go nuts.

View File

@ -1,8 +1,8 @@
baseURL = "https://wiki.thurstylark.com/" baseURL = "https://risotto.joeroe.io"
theme = "tlwiki" theme = "risotto"
title = "tlwiki demo" title = "risotto demo"
author = "Thurstylark" author = "Joe Roe"
copyright = "© 2021 Thurstylark" copyright = "© 2021 Joe Roe"
paginate = 3 paginate = 3
languageCode = "en" languageCode = "en"
DefaultContentLanguage = "en" DefaultContentLanguage = "en"
@ -22,8 +22,8 @@ mode = "dark-mode"
# Sidebar: about/bio # Sidebar: about/bio
[params.about] [params.about]
title = "tlwiki" title = "risotto"
description = "A [hugo](https://gohugo.io) theme for Thurstylark's Wiki." description = "A [hugo](https://gohugo.io) theme inspired by terminal ricing."
logo = "images/rice.svg" logo = "images/rice.svg"
# Sidebar: social links # Sidebar: social links
@ -31,6 +31,11 @@ logo = "images/rice.svg"
# * FontAwesome 5 <https://fontawesome.com/> ('fas fa-' or 'fab-fa' for brands) # * FontAwesome 5 <https://fontawesome.com/> ('fas fa-' or 'fab-fa' for brands)
# * Academicons <https://jpswalsh.github.io/academicons> ('ai ai-') # * Academicons <https://jpswalsh.github.io/academicons> ('ai ai-')
[[params.socialLinks]]
icon = "fab fa-github"
title = "GitHub"
url = "https://github.com/joeroe/risotto"
[[params.socialLinks]] [[params.socialLinks]]
icon = "fas fa-envelope" icon = "fas fa-envelope"
title = "Email" title = "Email"

BIN
images/screenshot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 181 KiB

BIN
images/tn.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 KiB

View File

@ -1,4 +1,12 @@
{{ define "main" }} {{ define "main" }}
{{ partial "title_and_desc.html" . }} <h1 id="{{ .Title | urlize }}">{{ .Title | markdownify }}</h2>
{{ partial "postlist.html" . }}
{{ .Content }}
<ul>
{{ range .Pages }}
{{ .Render "li" }}
{{ end }}
</ul>
{{ end }} {{ end }}

View File

@ -8,3 +8,12 @@
<footer class="content__footer"></footer> <footer class="content__footer"></footer>
{{ end }} {{ end }}
{{define "aside" }}
{{ if .Params.description }}<p>{{ .Params.description }}</p>{{ end }}
{{ if or (.Params.author) (.Params.date) }}
<p>
{{ if .Params.author }}By {{ .Params.author }}{{ if .Date }}, {{ end }}{{ end }}
{{ if .Date }}{{ .Date.Format "2006-01-02" }}{{ end }}
</p>
{{ end }}
{{ end }}

View File

@ -1,5 +1,4 @@
{{ define "main" }} {{ define "main" }}
{{ partial "title_and_desc.html" . }} {{ .Content }}
{{ partial "postlist.html" . }}
{{ end }} {{ end }}

View File

@ -1,6 +0,0 @@
{{define "aside" }}
{{ if .Params.description }}<p>{{ .Params.description }}</p>{{ end }}
<p>
{{ if .Lastmod }}Last Modified: {{ .Lastmod.Format "2006-01-02" }}{{ end }}
</p>
{{ end }}

View File

@ -1 +1,2 @@
<p class="copyright">{{ .Site.Copyright }}</p> <p class="copyright">{{ .Site.Copyright }}</p>
<p class="advertisement">Powered by <a href="https://gohugo.io/">hugo</a> and <a href="https://github.com/joeroe/risotto">risotto</a>.</p>

View File

@ -1,14 +0,0 @@
{{ range .Pages }}
{{ with .Params.hide }}
{{ else }}
<article class="post">
<header class="post__header">
<h2><a href="{{ .Permalink }}">{{ .Title | markdownify }}</a></h2>
</header>
<section class="post__summary">
{{ .Description }}
</section>
</article>
{{ end }}
{{ end }}

View File

@ -1,4 +0,0 @@
<header class="content__header">
<h1>{{ .Title | markdownify }}</h1>
{{ .Content }}
</header>

View File

@ -1,4 +0,0 @@
<header class="content__header">
<h1>{{ .Title | markdownify }}</h1>
{{ .Description }}
</header>

22
layouts/post/list.html Normal file
View File

@ -0,0 +1,22 @@
{{ define "main" }}
<header class="content__header">
<h1>{{ .Title | markdownify }}</h1>
{{ .Content }}
</header>
{{ range .Pages }}
<article class="post">
<header class="post__header">
<h1><a href="{{ .Permalink }}">{{ .Title | markdownify }}</a></h1>
<p class="post__meta">
{{ .Params.author }},
<span class="date">{{ .Date.Format "2 January 2006" }}</span>
</p>
</header>
<section class="post__summary">
{{ .Summary }}
</section>
</article>
{{ end }}
{{ end }}

View File

@ -1,15 +1,16 @@
name = "tlwiki" name = "risotto"
license = "MIT" license = "MIT"
licenselink = "https://git.thurstylark.com/thurstylark/tlwiki-hugo-theme/src/branch/main/LICENSE" licenselink = "https://github.com/joeroe/risotto/blob/master/LICENSE"
description = "The style and layout for Thurstylark's Wiki" description = "A minimalist, responsive theme inspired by terminal ricing aesthetics."
homepage = "https://git.thurstylark.com/thurstylark/tlwiki-hugo-theme" homepage = "https://github.com/joeroe/risotto"
demosite = "https://wiki.thurstylark.com/" demosite = "https://risotto.joeroe.io"
tags = ["responsive", "minimal", "dark mode"] tags = ["responsive", "minimal", "dark mode"]
features = [] features = []
min_version = "0.41.0" min_version = "0.41.0"
[author] [author]
name = "Thurstylark" name = "Joe Roe"
homepage = "https://wiki.thurstylark.com/" homepage = "https://joeroe.io"