Skip to content

Commit 2eee856

Browse files
authored
Update README.md
Add template instructions
1 parent 84dead8 commit 2eee856

File tree

1 file changed

+18
-30
lines changed

1 file changed

+18
-30
lines changed

README.md

Lines changed: 18 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -2,62 +2,50 @@
22

33
[Docsy](https://github.com/google/docsy) is a Hugo theme for technical documentation sites, providing easy site navigation, structure, and more. This **Docsy Example Project** uses the Docsy theme, as well as providing a skeleton documentation structure for you to use. You can either copy this project and edit it with your own content, or use the theme in your projects like any other [Hugo theme](https://gohugo.io/themes/installing-and-using-themes/).
44

5+
The theme is included in this project as a Git submodule:
6+
7+
```bash
8+
▶ git submodule
9+
a053131a4ebf6a59e4e8834a42368e248d98c01d themes/docsy (heads/master)
10+
```
11+
512
This Docsy Example Project is hosted at [https://example.docsy.dev/](https://example.docsy.dev/).
613

714
You can find detailed theme instructions in the Docsy user guide: https://docsy.dev/docs/
815

916
This is not an officially supported Google product. This project is currently maintained.
1017

11-
## Cloning the Docsy Example Project
12-
13-
The following will give you a project that is set up and ready to use (don't forget to use `--recurse-submodules` or you won't pull down some of the code you need to generate a working site). The `hugo server` command builds and serves the site. If you just want to build the site, run `hugo` instead.
14-
15-
```bash
16-
git clone --recurse-submodules --depth 1 https://github.com/google/docsy-example.git
17-
cd docsy-example
18-
hugo server
19-
```
20-
21-
The theme is included as a Git submodule:
18+
## Using the Docsy Example Project as a template
2219

23-
```bash
24-
▶ git submodule
25-
a053131a4ebf6a59e4e8834a42368e248d98c01d themes/docsy (heads/master)
26-
```
20+
A simple way to get started is to use this project as a template, which gives you a site project that is set up and ready to use. To do this:
2721

28-
If you want to do SCSS edits and want to publish these, you need to install `PostCSS` (not needed for `hugo server`):
22+
1. Click **Use this template**.
2923

30-
```bash
31-
npm install
32-
```
33-
34-
<!--### Cloning the Example from the Theme Project
24+
2. Select a name for your new project and click **Create repository from template**.
3525

26+
3. Make your own local working copy of your new repo using git clone, replacing https://github.com/my/example.git with your repo’s web URL:
3627

3728
```bash
38-
git clone --recurse-submodules --depth 1 https://github.com/docsy.git
39-
cd tech-doc-hugo-theme/exampleSite
40-
HUGO_THEMESDIR="../.." hugo server
29+
git clone --recurse-submodules --depth 1 https://github.com/my/example.git
4130
```
4231

32+
You can now edit your local versions of the site’s source files.
4333

44-
Note that the Hugo Theme Site requires the `exampleSite` to live in a subfolder of the theme itself. To avoid recursive duplication, the example site is added as a Git subtree:
34+
If you want to do SCSS edits and want to publish these, you need to install `PostCSS`
4535

4636
```bash
47-
git subtree add --prefix exampleSite https://github.com/google/docsy.git master --squash
37+
npm install
4838
```
4939

50-
To pull in changes, see `pull-deps.sh` script in the theme.-->
51-
5240
## Running the website locally
5341

54-
Once you've cloned the site repo, from the repo root folder, run:
42+
Once you've cloned or copied the site repo, from the repo root folder, run:
5543

5644
```
5745
hugo server
5846
```
5947

60-
### Running a container locally
48+
## Running a container locally
6149

6250
You can run docsy-example inside a [Docker](ihttps://docs.docker.com/)
6351
container, the container runs with a volume bound to the `docsy-example`

0 commit comments

Comments
 (0)