Skip to content

Commit

Permalink
Pin Docsy version in other installation options (#1439)
Browse files Browse the repository at this point in the history
  • Loading branch information
chalin authored Mar 2, 2023
1 parent 26d4d11 commit 37c2273
Showing 1 changed file with 19 additions and 6 deletions.
25 changes: 19 additions & 6 deletions userguide/content/en/docs/get-started/other-options.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,15 @@ your project's root directory:
1. Install Docsy as a Git submodule:
```sh
git submodule add https://github.com/google/docsy.git themes/docsy
cd themes/docsy
git checkout v{{% param version %}}
```
To work from the development version of Docsy (not recommended),
run the following command instead:
```sh
git submodule add --depth 1 https://github.com/google/docsy.git themes/docsy
```
Expand Down Expand Up @@ -215,17 +224,21 @@ maintain your own copy of the theme directly, or your deployment choice requires
you to include a copy of the theme in your repository), you can clone the theme
into your project's `themes` subdirectory.

To clone Docsy into your project's `theme` folder, run the following commands
from your project's root directory:
To clone Docsy at v{{% param version %}} into your project's `theme` folder, run
the following commands from your project's root directory:

```sh
cd themes
git clone https://github.com/google/docsy
git clone -b v{{% param version %}} https://github.com/google/docsy
cd docsy
npm install
```

Consider setting up an NPM [prepare][] script, as documented in Option 1.
To work from the development version of Docsy (not recommended unless, for
example, you plan to upstream changes to Docsy), omit the `-b v{{% param version
%}}` argument from the clone command above.

Then consider setting up an NPM [prepare][] script, as documented in Option 1.

For more information, see
[Theme Components](https://gohugo.io/hugo-modules/theme-components/) on the
Expand All @@ -245,8 +258,8 @@ You can use Docsy as an NPM module as follows:

2. Install Docsy, and postCSS (as [instructed earlier](#install-postcss)):

```sh
npm install --save-dev google/docsy autoprefixer postcss-cli postcss
```console
npm install --save-dev google/docsy#semver:{{% param version %}} autoprefixer postcss-cli postcss
```

3. Build or serve your new site using the usual Hugo commands, specifying the
Expand Down

0 comments on commit 37c2273

Please sign in to comment.