refactor: move personal site to sites/nrd.sh/
Reorganize for monorepo structure: - Move content/, templates/, static/, site.toml → sites/nrd.sh/ - Frees root for sukr docs site - Build with: sukr -c sites/nrd.sh/site.toml
This commit is contained in:
29
sites/nrd.sh/templates/base.html
Normal file
29
sites/nrd.sh/templates/base.html
Normal file
@@ -0,0 +1,29 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<title>{{ title }} | {{ config.title }}</title>
|
||||
<link rel="canonical" href="{{ base_url }}{{ page_path }}" />
|
||||
<link
|
||||
rel="alternate"
|
||||
type="application/atom+xml"
|
||||
title="Atom Feed"
|
||||
href="{{ base_url }}/feed.xml"
|
||||
/>
|
||||
<link rel="stylesheet" href="{{ prefix }}/style.css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<nav>
|
||||
<a href="{{ prefix }}/index.html">{{ config.title }}</a>
|
||||
{% for item in nav %}
|
||||
<a href="{{ prefix }}{{ item.path }}">{{ item.label }}</a>
|
||||
{% endfor %}
|
||||
</nav>
|
||||
<main>{% block content %}{% endblock content %}</main>
|
||||
<footer>
|
||||
<p>© {{ config.author }}</p>
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
9
sites/nrd.sh/templates/content/default.html
Normal file
9
sites/nrd.sh/templates/content/default.html
Normal file
@@ -0,0 +1,9 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<article>
|
||||
<h1>{{ page.title }}</h1>
|
||||
{% if page.description %}
|
||||
<p class="description">{{ page.description }}</p>
|
||||
{% endif %}
|
||||
<section class="content">{{ content | safe }}</section>
|
||||
</article>
|
||||
{% endblock content %}
|
||||
19
sites/nrd.sh/templates/content/post.html
Normal file
19
sites/nrd.sh/templates/content/post.html
Normal file
@@ -0,0 +1,19 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<article class="post">
|
||||
<header>
|
||||
<h1>{{ page.title }}</h1>
|
||||
{% if page.date %}
|
||||
<time class="date">{{ page.date }}</time>
|
||||
{% endif %} {% if page.description %}
|
||||
<p class="description">{{ page.description }}</p>
|
||||
{% endif %} {% if page.tags %}
|
||||
<ul class="tags">
|
||||
{% for tag in page.tags %}
|
||||
<li><a href="{{ prefix }}/tags/{{ tag }}.html">{{ tag }}</a></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
</header>
|
||||
<section class="content">{{ content | safe }}</section>
|
||||
</article>
|
||||
{% endblock content %}
|
||||
9
sites/nrd.sh/templates/homepage.html
Normal file
9
sites/nrd.sh/templates/homepage.html
Normal file
@@ -0,0 +1,9 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<section class="hero">
|
||||
<h1>{{ page.title }}</h1>
|
||||
{% if page.description %}
|
||||
<p class="tagline">{{ page.description }}</p>
|
||||
{% endif %}
|
||||
</section>
|
||||
<section class="content">{{ content | safe }}</section>
|
||||
{% endblock content %}
|
||||
6
sites/nrd.sh/templates/page.html
Normal file
6
sites/nrd.sh/templates/page.html
Normal file
@@ -0,0 +1,6 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<article class="page">
|
||||
<h1>{{ page.title }}</h1>
|
||||
<section class="content">{{ content | safe }}</section>
|
||||
</article>
|
||||
{% endblock content %}
|
||||
18
sites/nrd.sh/templates/section/blog.html
Normal file
18
sites/nrd.sh/templates/section/blog.html
Normal file
@@ -0,0 +1,18 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<h1>{{ section.title }}</h1>
|
||||
<ul class="post-list">
|
||||
{% for item in items %}
|
||||
<li>
|
||||
<a href="./{{ item.slug }}.html">
|
||||
<span class="title">{{ item.frontmatter.title }}</span>
|
||||
{% if item.frontmatter.date %}
|
||||
<time class="date">{{ item.frontmatter.date }}</time>
|
||||
{% endif %}
|
||||
</a>
|
||||
{% if item.frontmatter.description %}
|
||||
<p class="description">{{ item.frontmatter.description }}</p>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock content %}
|
||||
13
sites/nrd.sh/templates/section/default.html
Normal file
13
sites/nrd.sh/templates/section/default.html
Normal file
@@ -0,0 +1,13 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<h1>{{ section.title }}</h1>
|
||||
<ul class="item-list">
|
||||
{% for item in items %}
|
||||
<li>
|
||||
<a href="./{{ item.slug }}.html">{{ item.frontmatter.title }}</a>
|
||||
{% if item.frontmatter.description %}
|
||||
<p>{{ item.frontmatter.description }}</p>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock content %}
|
||||
21
sites/nrd.sh/templates/section/projects.html
Normal file
21
sites/nrd.sh/templates/section/projects.html
Normal file
@@ -0,0 +1,21 @@
|
||||
{% extends "base.html" %} {% block content %}
|
||||
<h1>{{ section.title }}</h1>
|
||||
<ul class="project-cards">
|
||||
{% for item in items %}
|
||||
<li class="card">
|
||||
{% if item.frontmatter.link_to %}
|
||||
<a href="{{ item.frontmatter.link_to }}" target="_blank" rel="noopener">
|
||||
<h2>{{ item.frontmatter.title }}</h2>
|
||||
{% if item.frontmatter.description %}
|
||||
<p>{{ item.frontmatter.description }}</p>
|
||||
{% endif %}
|
||||
</a>
|
||||
{% else %}
|
||||
<h2>{{ item.frontmatter.title }}</h2>
|
||||
{% if item.frontmatter.description %}
|
||||
<p>{{ item.frontmatter.description }}</p>
|
||||
{% endif %} {% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endblock content %}
|
||||
Reference in New Issue
Block a user