mirror of
https://github.com/gohugoio/hugo.git
synced 2025-03-20 09:22:29 +00:00
parent
72a66972b6
commit
37676a25c6
1 changed files with 17 additions and 10 deletions
|
@ -37,6 +37,7 @@ The new site will have the following structure
|
||||||
|
|
||||||
▸ archetypes/
|
▸ archetypes/
|
||||||
▸ content/
|
▸ content/
|
||||||
|
▸ data/
|
||||||
▸ layouts/
|
▸ layouts/
|
||||||
▸ static/
|
▸ static/
|
||||||
config.toml
|
config.toml
|
||||||
|
@ -86,10 +87,10 @@ We still lack any templates to tell us how to display the content.
|
||||||
## Step 4. Install some themes
|
## Step 4. Install some themes
|
||||||
|
|
||||||
Hugo has rich theme support and a growing set of themes to choose from.
|
Hugo has rich theme support and a growing set of themes to choose from.
|
||||||
To install all of the available Hugo themes, simply clone the entire **hugoThemes** repository from within your working directory:
|
To install the latest version of all of the available Hugo themes, simply clone the entire **hugoThemes** repository from within your working directory:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ git clone --recursive https://github.com/spf13/hugoThemes themes
|
$ git clone --depth 1 --recursive https://github.com/spf13/hugoThemes.git themes
|
||||||
```
|
```
|
||||||
|
|
||||||
## Step 5. Run Hugo
|
## Step 5. Run Hugo
|
||||||
|
@ -98,13 +99,16 @@ Hugo contains its own high-performance web server. Simply run `hugo
|
||||||
server` and Hugo will find an available port and run a server with
|
server` and Hugo will find an available port and run a server with
|
||||||
your content:
|
your content:
|
||||||
|
|
||||||
$ hugo server --theme=hyde --buildDrafts
|
$ 2 of 2 drafts rendered
|
||||||
|
0 future content
|
||||||
2 pages created
|
2 pages created
|
||||||
|
0 paginator pages created
|
||||||
0 tags created
|
0 tags created
|
||||||
0 categories created
|
0 categories created
|
||||||
in 5 ms
|
in 15 ms
|
||||||
Serving pages from exampleHugoSite/public
|
Watching for changes in /home/user/exampleHugoSite/{data,content,layouts,static,themes}
|
||||||
Web Server is available at http://localhost:1313
|
Serving pages from memory
|
||||||
|
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
|
||||||
Press Ctrl+C to stop
|
Press Ctrl+C to stop
|
||||||
|
|
||||||
We specified two options here:
|
We specified two options here:
|
||||||
|
@ -129,7 +133,7 @@ This even works in mobile browsers.
|
||||||
|
|
||||||
Stop the Hugo process by hitting <kbd>Ctrl</kbd>+<kbd>C</kbd>. Then run the following:
|
Stop the Hugo process by hitting <kbd>Ctrl</kbd>+<kbd>C</kbd>. Then run the following:
|
||||||
|
|
||||||
$ hugo server --theme=hyde --buildDrafts --watch
|
$ hugo server --theme=hyde --buildDrafts
|
||||||
2 pages created
|
2 pages created
|
||||||
0 tags created
|
0 tags created
|
||||||
0 categories created
|
0 categories created
|
||||||
|
@ -148,12 +152,15 @@ you can look at the browser in most cases.
|
||||||
|
|
||||||
Change and save this file. Notice what happened in your terminal:
|
Change and save this file. Notice what happened in your terminal:
|
||||||
|
|
||||||
Change detected, rebuilding site
|
$ Change detected, rebuilding site
|
||||||
|
2015-11-27 15:13 +0100
|
||||||
|
2 of 2 drafts rendered
|
||||||
|
0 future content
|
||||||
2 pages created
|
2 pages created
|
||||||
|
0 paginator pages created
|
||||||
0 tags created
|
0 tags created
|
||||||
0 categories created
|
0 categories created
|
||||||
in 5 ms
|
in 11 ms
|
||||||
|
|
||||||
## Step 7. Have fun
|
## Step 7. Have fun
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue