Skip to content

Commit bc7eb99

Browse files
authored
copy zola example from vercel/vercel (#1004)
1 parent 2dba884 commit bc7eb99

File tree

11 files changed

+107
-0
lines changed

11 files changed

+107
-0
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/public
2+
/.vercel
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Zola
2+
3+
This directory is a brief example of a Zola site that can be deployed to Vercel with zero configuration.
4+
5+
## Deploy Your Own
6+
7+
Deploy your own Zola project with Vercel.
8+
9+
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https://github.com/vercel/examples/tree/main/framework-boilerplates/zola&template=zola)
10+
11+
_Live Example: https://zola-template.vercel.app_
12+
13+
### Deploying From Your Terminal
14+
15+
You can deploy your new Zola project with a single command from your terminal using [Vercel CLI](https://vercel.com/download):
16+
17+
```shell
18+
$ vercel
19+
```
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# The URL the site will be built for
2+
base_url = "/"
3+
4+
# Whether to automatically compile all Sass files in the sass directory
5+
compile_sass = true
6+
7+
# Whether to build a search index to be used later on by a JavaScript library
8+
build_search_index = false
9+
10+
[markdown]
11+
# Whether to do syntax highlighting
12+
# Theme can be customised by setting the `highlight_theme` variable to a theme supported by Zola
13+
highlight_code = false
14+
15+
[extra]
16+
# Put all your custom variables here
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
+++
2+
title = "List of blog posts"
3+
sort_by = "date"
4+
template = "blog.html"
5+
page_template = "blog-page.html"
6+
+++
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
+++
2+
title = "My first post"
3+
date = 2019-11-27
4+
+++
5+
6+
This is my first blog post.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
+++
2+
title = "My second post"
3+
date = 2019-11-28
4+
+++
5+
6+
This is my second blog post.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta charset="utf-8">
6+
<title>MyBlog</title>
7+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.8.0/css/bulma.min.css">
8+
</head>
9+
10+
<body>
11+
<section class="section">
12+
<div class="container">
13+
{% block content %} {% endblock %}
14+
</div>
15+
</section>
16+
</body>
17+
18+
</html>
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{% extends "base.html" %}
2+
3+
{% block content %}
4+
<h1 class="title">
5+
{{ page.title }}
6+
</h1>
7+
<p class="subtitle"><strong>{{ page.date }}</strong></p>
8+
{{ page.content | safe }}
9+
{% endblock content %}
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{% extends "base.html" %}
2+
3+
{% block content %}
4+
<h1 class="title">
5+
{{ section.title }}
6+
</h1>
7+
<ul>
8+
{% for page in section.pages %}
9+
<li><a href="{{ page.permalink | safe }}">{{ page.title }}</a></li>
10+
{% endfor %}
11+
</ul>
12+
{% endblock content %}
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{% extends "base.html" %}
2+
3+
{% block content %}
4+
<h1 class="title">
5+
This is my blog made with Zola.
6+
</h1>
7+
<p>Click <a href="/blog/">here</a> to see my posts.</p>
8+
{% endblock content %}

0 commit comments

Comments
 (0)