chore: Update README.md
Signed-off-by: Awiteb <a@4rs.nl>
This commit is contained in:
parent
c51ff88d48
commit
0df1c469e4
1 changed files with 34 additions and 119 deletions
153
README.md
153
README.md
|
@ -1,133 +1,48 @@
|
||||||
# no style, please!
|
# OxideTalis Messaging Protocol (OTMP)
|
||||||
|
|
||||||
A (nearly) no-CSS, fast, minimalist [Zola](https://www.getzola.org/) theme.
|
A simple site explaining the OxideTalis Messaging Protocol (OTMP).
|
||||||
Ported from from [riggraz](https://riggraz.dev/)'s [no style, please! Jekyll theme](https://riggraz.dev/no-style-please/), and you can find the demo [here](https://atgumx.gitlab.io/no-style-please/)
|
|
||||||
|
|
||||||
![screenshot](./screenshot.png)
|
|
||||||
|
|
||||||
## Installation
|
## How to view the site?
|
||||||
|
There are three ways to view the site, you can choose any of them
|
||||||
|
|
||||||
First download this theme to your `themes` directory:
|
### View the site online (if available)
|
||||||
|
You can view the site online by visiting the following link: [https://otmp.4rs.nl](https://otmp.4rs.nl)
|
||||||
|
|
||||||
|
### Build the site locally
|
||||||
|
You can build the site locally by following the steps below:
|
||||||
|
|
||||||
|
> [!NOTE]
|
||||||
|
> My current zola version is `0.18.0`.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
cd themes
|
# Clone the repository
|
||||||
git clone https://gitlab.com/4bcx/no-style-please.git
|
git clone https://git.4rs.nl/awiteb/otmp_site.git
|
||||||
|
|
||||||
|
# Change directory to the repository
|
||||||
|
cd otmp_site
|
||||||
|
|
||||||
|
# Build the site
|
||||||
|
zola build
|
||||||
|
|
||||||
|
The site will be built in the `public` directory (you can view it by opening the `index.html` file in your browser)
|
||||||
```
|
```
|
||||||
|
|
||||||
and then enable it in your `config.toml`:
|
### `site` branch
|
||||||
|
You can view the site by visiting the `site` branch of the repository. The site is built and pushed to the `site` branch automatically by the CI pipeline.
|
||||||
|
|
||||||
```toml
|
## How to contribute?
|
||||||
theme = "no-style-please"
|
Write changes can be made at `templates` directory. You can't change the `content` directory as it contains the protocol itself.
|
||||||
```
|
|
||||||
|
|
||||||
## Options
|
You can open an issue to write a comments or suggestions about the protocol.
|
||||||
|
|
||||||
### Default taxonomies
|
## `deploy.sh` script
|
||||||
|
Simple script to build the site and push it to GitHub pages.
|
||||||
|
|
||||||
Special templates for `tags`, `categories`, and `contexts` taxonomies are provided. However, generic templates exist for custom taxonomies.
|
## Credits
|
||||||
|
|
||||||
To use taxonomies, in a page metadata add
|
This **site** is built on top of Ahmed Alaa [no-style-please](https://gitlab.com/atgumx/no-style-please) theme, with some modifications, you can view the changes at the `templates` directory by running the following command:
|
||||||
|
|
||||||
```toml
|
```bash
|
||||||
[taxonomies]
|
git log --author="Awiteb <a@4rs.nl>" -p templates
|
||||||
tags = [ 'tag1', 'tag2' ]
|
```
|
||||||
categories = [ 'category A', 'B class' ]
|
|
||||||
genre = [ 'rock', 'alternative' ] # custom taxonomy
|
|
||||||
```
|
|
||||||
|
|
||||||
### Pages list in homepage
|
|
||||||
|
|
||||||
To enable listing of pages in homepage add the following in `config.toml`
|
|
||||||
|
|
||||||
```toml
|
|
||||||
[extra]
|
|
||||||
list_pages = true
|
|
||||||
```
|
|
||||||
|
|
||||||
If you do not want the date of the post added next to the title in the list, add the following as well:
|
|
||||||
|
|
||||||
```toml
|
|
||||||
no_list_date = true
|
|
||||||
```
|
|
||||||
|
|
||||||
### Header and footer nav links
|
|
||||||
|
|
||||||
Also in the `extra` section in `config.toml`
|
|
||||||
|
|
||||||
```toml
|
|
||||||
[extra]
|
|
||||||
|
|
||||||
header_nav = [
|
|
||||||
{ name = "~home", url = "/" },
|
|
||||||
{ name = "#tags", url = "/tags" },
|
|
||||||
{ name = "+categories", url = "/categories" },
|
|
||||||
{ name = "@contexts", url = "/contexts" },
|
|
||||||
{ name = "example", url = "http://example.com", new_tab=true },
|
|
||||||
]
|
|
||||||
footer_nav = [
|
|
||||||
{ name = "< previous", url = "#" },
|
|
||||||
{ name = "webring", url = "#" },
|
|
||||||
{ name = "next >", url = "#" },
|
|
||||||
]
|
|
||||||
```
|
|
||||||
|
|
||||||
### Add TOC to pages
|
|
||||||
|
|
||||||
In a page frontmatter, set `extra.add_toc` to `true`
|
|
||||||
|
|
||||||
```toml
|
|
||||||
[extra]
|
|
||||||
add_toc = true
|
|
||||||
```
|
|
||||||
|
|
||||||
### Extra data
|
|
||||||
|
|
||||||
- `author` can be set in both main config and in pages metadata
|
|
||||||
- `image` variable can be used in pages to add an image to HTML `<meta>` tags
|
|
||||||
- Same for `logo` in main config, except this one is also used as the site icon
|
|
||||||
|
|
||||||
### Horizontal rule shortcode `hr()`
|
|
||||||
|
|
||||||
Adds the option to insert text in the thematic break
|
|
||||||
|
|
||||||
```html
|
|
||||||
{{ hr(data_content="footnotes") }}
|
|
||||||
```
|
|
||||||
|
|
||||||
is rendered
|
|
||||||
|
|
||||||
![thematic break screenshot](./hr_footnotes.png)
|
|
||||||
|
|
||||||
### Invertable image `iimg()`
|
|
||||||
|
|
||||||
Images are not inverted in darkmode by default. To add an invertable image use the following
|
|
||||||
|
|
||||||
```html
|
|
||||||
{{ iimg(src="logo.png", alt="alt text") }}
|
|
||||||
```
|
|
||||||
|
|
||||||
In light mode
|
|
||||||
|
|
||||||
![image in light mode](./iimg_light.png)
|
|
||||||
|
|
||||||
In dark mode
|
|
||||||
|
|
||||||
![image in dark mode](./iimg_dark.png)
|
|
||||||
|
|
||||||
### Disable Twitter card
|
|
||||||
|
|
||||||
Twitter metatags are generated by default, to disable them set `extra.twitter_card` to `false` in in your `config.toml`
|
|
||||||
|
|
||||||
```toml
|
|
||||||
[extra]
|
|
||||||
twitter_card = true
|
|
||||||
```
|
|
||||||
|
|
||||||
## TODO
|
|
||||||
|
|
||||||
- [ ] Add RTL support
|
|
||||||
- [ ] Write proper test pages
|
|
||||||
|
|
||||||
## License
|
|
||||||
|
|
||||||
The theme is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
|
Loading…
Reference in a new issue