feat: init
This commit is contained in:
commit
aaa02408a0
|
@ -0,0 +1 @@
|
|||
/.hugo_build.lock
|
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
title: "{{ replace .Name "-" " " | title }}"
|
||||
date: {{ .Date }}
|
||||
draft: true
|
||||
---
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
baseURL = "https://flinner.nand.sh"
|
||||
title = "I don't know what I am doing!"
|
||||
theme = "emacsy"
|
||||
|
||||
[menu]
|
||||
[[menu.main]]
|
||||
identifier = "posts"
|
||||
name = "Posts"
|
||||
url = "/posts"
|
||||
weight = 10
|
||||
|
||||
[[menu.main]]
|
||||
identifier = "about"
|
||||
name = "About"
|
||||
url = "/about"
|
||||
weight = 20
|
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
title: "Home"
|
||||
---
|
||||
|
||||
# Hi there
|
||||
|
||||
Welcome to your new Hugo site.
|
||||
|
||||
Now go build something great.
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: "About"
|
||||
---
|
||||
|
||||
Here's a bit about me.
|
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
title: "My First Post"
|
||||
date: 2020-09-03T17:27:59+07:00
|
||||
---
|
||||
|
||||
Here's an example blog post.
|
|
@ -0,0 +1,4 @@
|
|||
---
|
||||
title: "{{ replace .Name "-" " " | title }}"
|
||||
date: {{ .Date }}
|
||||
---
|
|
@ -0,0 +1,16 @@
|
|||
baseURL = "https://mynewhugosite.com"
|
||||
title = "My New Hugo Site"
|
||||
theme = "hugo-starter"
|
||||
|
||||
[menu]
|
||||
[[menu.main]]
|
||||
identifier = "posts"
|
||||
name = "Posts"
|
||||
url = "/posts"
|
||||
weight = 10
|
||||
|
||||
[[menu.main]]
|
||||
identifier = "about"
|
||||
name = "About"
|
||||
url = "/about"
|
||||
weight = 20
|
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
title: "Home"
|
||||
---
|
||||
|
||||
# Hi there
|
||||
|
||||
Welcome to your new Hugo site.
|
||||
|
||||
Now go build something great.
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
title: "About"
|
||||
---
|
||||
|
||||
Here's a bit about me.
|
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
title: "My First Post"
|
||||
date: 2020-09-03T17:27:59+07:00
|
||||
---
|
||||
|
||||
Here's an example blog post.
|
|
@ -0,0 +1,9 @@
|
|||
{{ partial "header.html" . }}
|
||||
|
||||
<h1>Page Not Found</h1>
|
||||
|
||||
<p>This page doesn't exist.</p>
|
||||
|
||||
<p><a href="/">Go back to the home page</a></p>
|
||||
|
||||
{{ partial "footer.html" . }}
|
|
@ -0,0 +1,18 @@
|
|||
{{ partial "header.html" . }}
|
||||
|
||||
<h1>{{ .Title }}</h1>
|
||||
|
||||
{{ .Content }}
|
||||
|
||||
{{ range.Data.Pages }}
|
||||
<article class="post-snippet">
|
||||
<h3>
|
||||
<a href="{{ .RelPermalink }}">{{ .Title }}</a>
|
||||
</h3>
|
||||
<time datetime="{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}">
|
||||
{{ .Date.Format "January 2, 2006" }}
|
||||
</time>
|
||||
</article>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "footer.html" . }}
|
|
@ -0,0 +1,7 @@
|
|||
{{ partial "header.html" . }}
|
||||
|
||||
<h1>{{ .Title }}</h1>
|
||||
|
||||
{{ .Content }}
|
||||
|
||||
{{ partial "footer.html" . }}
|
|
@ -0,0 +1,5 @@
|
|||
{{ partial "header.html" . }}
|
||||
|
||||
{{ .Content }}
|
||||
|
||||
{{ partial "footer.html" . }}
|
|
@ -0,0 +1,8 @@
|
|||
</main>
|
||||
|
||||
<footer>
|
||||
<p>©{{ dateFormat "2006" now }} {{ .Site.Title }}</p>
|
||||
</footer>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,22 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
|
||||
<title>{{ if not .IsHome }}{{ .Title }} | {{ end }}{{ .Site.Title }}</title>
|
||||
|
||||
<link rel="stylesheet" href="/css/style.css" type="text/css" media="all" />
|
||||
|
||||
{{ with .OutputFormats.Get "rss" -}}
|
||||
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
|
||||
{{ end -}}
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
{{ partial "nav.html" . }}
|
||||
|
||||
<main class="content">
|
|
@ -0,0 +1,14 @@
|
|||
<header class="site-header">
|
||||
<nav class="site-nav">
|
||||
<a class="logo" href="{{ .Site.BaseURL }}">
|
||||
{{ .Site.Title }}
|
||||
</a>
|
||||
<ul class="main-menu">
|
||||
{{ range.Site.Menus.main }}
|
||||
<li>
|
||||
<a href="{{ .URL }}">{{ .Name }}</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</nav>
|
||||
</header>
|
|
@ -0,0 +1,20 @@
|
|||
# Hugo Starter Theme
|
||||
|
||||
Dead-simple Hugo theme with everything you need to get started. Intended to be a starter for creating your own theme without including useless bloat like most Hugo themes.
|
||||
|
||||
## Getting started
|
||||
|
||||
Inside your project folder, copy the theme to your `themes` folder. Since you're just using it as a starter for your theme, remove the git history.
|
||||
|
||||
```bash
|
||||
git clone https://github.com/ericmurphyxyz/hugo-starter-theme themes/your-theme-name
|
||||
rm -rf themes/your-theme-name/.git
|
||||
```
|
||||
|
||||
If you'd like some example content and an example config file to get started, you can copy the `exampleSite` directory into your root Hugo directory.
|
||||
|
||||
```bash
|
||||
cp -r themes/your-theme-name/exampleSite/* ./
|
||||
```
|
||||
|
||||
To learn more about building themes in Hugo, refer to Hugo's [templating documentation](https://gohugo.io/templates/).
|
|
@ -0,0 +1,59 @@
|
|||
/* LAYOUT */
|
||||
|
||||
body {
|
||||
color: #333;
|
||||
font-size: 125%;
|
||||
line-height: 1.5;
|
||||
max-width: 45rem;
|
||||
padding: 1rem;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.content {
|
||||
margin-bottom: 2rem;
|
||||
}
|
||||
|
||||
/* NAVIGATION */
|
||||
|
||||
.site-nav {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.site-nav a {
|
||||
display: block;
|
||||
padding: 1rem;
|
||||
}
|
||||
|
||||
.site-nav .logo {
|
||||
font-weight: bold;
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
.main-menu {
|
||||
display: flex;
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 48rem) {
|
||||
.site-nav,
|
||||
.main-menu {
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.site-nav a {
|
||||
padding: 0.5rem;
|
||||
padding-left: 0;
|
||||
}
|
||||
}
|
||||
|
||||
/* LISTS */
|
||||
|
||||
.post-snippet {
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
.post-snippet h3 {
|
||||
margin-bottom: 0.25rem;
|
||||
}
|
Loading…
Reference in New Issue