Skip to content

Commit

Permalink
Update for applying Documentor
Browse files Browse the repository at this point in the history
  • Loading branch information
jellyterra committed Aug 18, 2024
1 parent f48fc10 commit e4f827b
Show file tree
Hide file tree
Showing 29 changed files with 213 additions and 137 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pagine.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Install Pagine
run: go install github.com/webpagine/pagine/v2/cmd/pagine@v2.1.0
run: go install github.com/webpagine/pagine/v2/cmd/pagine@v2.3.0

- name: Checkout
uses: actions/checkout@v4
Expand Down
6 changes: 6 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
[submodule "templates/genesis"]
path = templates/genesis
url = https://github.com/webpagine/genesis
[submodule "templates/darkmode"]
path = templates/darkmode
url = https://github.com/webpagine/darkmode
[submodule "templates/documentor"]
path = templates/documentor
url = https://github.com/webpagine/documentor
5 changes: 5 additions & 0 deletions assets/img/pagine_icon_fit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion en-US/docs/README.md → docs/en/v2.1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ Example: `page.html`
<html lang="{{ .lang }}">
<head>
<title>{{ .title }}</title>
<link rel="stylesheet" href="{{ (getAttr).templateBase }}/css/base.css" />
<link rel="stylesheet" href="{{ engine.Attr.templateBase }}/css/base.css" />
</head>
<body>
{{ template "header.html" .header }}
Expand Down
2 changes: 2 additions & 0 deletions docs/en/v2.1/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
documentor:
lang: "en"
7 changes: 7 additions & 0 deletions docs/en/v2.1/unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
unit:
- template: "documentor"
template_key: "doc"
output: "/index.html"
define:
title: "Documentation"
content: "/README.md"
32 changes: 32 additions & 0 deletions docs/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
documentor:
root: "/docs"

lang: "en"
theme: "dark"

versions:
- "v2.1"

locales:
- locale: "en"
title: "English"

- locale: "zh"
title: "中文"

header:
title: '<span style="margin: 0 20px; font-size: 24px"><span style="font-weight: bolder">Pagine</span> Docs</span>'

logo:
src: "/assets/img/pagine_icon_fit.svg"
height: 50

nav:
- title: "Repositories"
link: "https://github.com/webpagine"

footer:
copyright:
owner: "Symboltics"
date: "2024"
license: "Text is available under the <a target=\"_blank\" href=\"https://creativecommons.org/licenses/by-sa/4.0/legalcode.en\">Creative Commons Attribution-ShareAlike License 4.0</a>; additional terms may apply."
4 changes: 4 additions & 0 deletions docs/unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
unit:
- template: "documentor"
template_key: "locale"
output: "/index.html"
13 changes: 13 additions & 0 deletions docs/zh/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
documentor:
lang: "zh"

header:
title: '<span style="margin: 0 20px; font-size: 24px"><span style="font-weight: bolder">Pagine</span> Docs</span>'

logo:
src: "/assets/img/pagine_icon_fit.svg"
height: 50

nav:
- title: "Repositories"
link: "https://github.com/webpagine"
6 changes: 6 additions & 0 deletions docs/zh/unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
unit:
- template: "documentor"
template_key: "redirect"
output: "index.html"
define:
target: "v2.1"
2 changes: 1 addition & 1 deletion zh-CN/docs/README.md → docs/zh/v2.1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ export = "post.html" # Export `post.html`
<html lang="{{ .lang }}">
<head>
<title>{{ .title }}</title>
<link rel="stylesheet" href="{{ (getAttr).templateBase }}/css/base.css" />
<link rel="stylesheet" href="{{ engine.Attr.templateBase }}/css/base.css" />
</head>
<body>
{{ template "header.html" .header }}
Expand Down
7 changes: 7 additions & 0 deletions docs/zh/v2.1/unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
unit:
- template: "documentor"
template_key: "doc"
output: "/index.html"
define:
title: "文档"
content: "/README.md"
4 changes: 0 additions & 4 deletions en-US/docs/unit.toml

This file was deleted.

4 changes: 0 additions & 4 deletions en-US/unit.toml

This file was deleted.

7 changes: 7 additions & 0 deletions en-US/unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
unit:
- template: "genesis"
template_key: "page"
output: "/index.html"
define:
title: "Pagine - Web Generator"
content: "mainpage.html"
9 changes: 0 additions & 9 deletions env.toml

This file was deleted.

10 changes: 10 additions & 0 deletions env.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
ignore:
- ".git.*"
- ".*toml"
- ".*html"
- "templates/.*templates/"

use:
genesis: "/templates/genesis"
darkmode: "/templates/darkmode"
documentor: "/templates/documentor"
84 changes: 0 additions & 84 deletions metadata.toml

This file was deleted.

86 changes: 86 additions & 0 deletions metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
genesis:
lang: "en"
locale: "en-US"
theme: "dark"

locales:
- locale: "en-US"
title: "English"

- locale: "zh-CN"
title: "简体中文"

head:
icon: "https://avatars.githubusercontent.com/u/168826426"

header:
logo:
src: "/assets/img/pagine.svg"
height: 50

nav:
- title: "Documentation"
link: "/docs/"

- title: "Repositories"
link: "https://github.com/webpagine"

footer:
logo:
src: "/assets/img/symboltics_mono.svg"
height: 40

copyright:
owner: "Symboltics"
date: "2024"
license: "Text is available under the <a target=\"_blank\" href=\"https://creativecommons.org/licenses/by-sa/4.0/legalcode.en\">Creative Commons Attribution-ShareAlike License 4.0</a>; additional terms may apply."

lists:
- title: "About Symboltics"
links:
- name: "Vision"
link: "https://symboltics.com"

- name: "Mission"
link: "https://symboltics.com"

- name: "Where we go"
link: "https://symboltics.com"

- name: "Where we come"
link: "https://symboltics.com"

- title: "Infrastructure"
links:
- name: "LangVM"
link: "https://github.com/langvm"

- name: "Symonarch"
link: "https://github.com/symonarch"

- name: "HyperArchy"
link: "https://github.com/hyperarchy"

- name: "Web Pagine"
link: "https://github.com/webpagine"

- title: "Services"
links:
- name: "Modularis"
link: "https://github.com/symboltics/modularis"

media:
- icon: "github"
link: "https://github.com/jellyterra"

- icon: "x"
link: "https://x.com/jellyterra"

- icon: "discord"
link: "https://discord.gg/SBbp7M4nus"

- icon: "element"
link: "https://matrix.to/#/#webpagine:matrix.org"

- icon: "telegram"
link: "https://t.me/webpagine"
1 change: 1 addition & 0 deletions templates/darkmode
Submodule darkmode added at 10b086
1 change: 1 addition & 0 deletions templates/documentor
Submodule documentor added at 0e8e69
9 changes: 0 additions & 9 deletions unit.toml

This file was deleted.

12 changes: 12 additions & 0 deletions unit.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
unit:
- template: "genesis"
template_key: "page"
output: "/404.html"
define:
title : "Pagine - Web Generator"
content: "404.html"
- template: "genesis"
template_key: "locale"
output: "/index.html"
define:
title: "Pagine - Web Generator"
4 changes: 0 additions & 4 deletions zh-CN/docs/unit.toml

This file was deleted.

15 changes: 0 additions & 15 deletions zh-CN/metadata.toml

This file was deleted.

3 changes: 3 additions & 0 deletions zh-CN/metadata.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
genesis:
lang: "zh"
locale: "zh-CN"
4 changes: 0 additions & 4 deletions zh-CN/unit.toml

This file was deleted.

Loading

0 comments on commit e4f827b

Please sign in to comment.