Skip to content

Commit

Permalink
WIP: Update user guide
Browse files Browse the repository at this point in the history
  • Loading branch information
smainz committed May 10, 2024
1 parent 04f235d commit d776e07
Showing 1 changed file with 56 additions and 2 deletions.
58 changes: 56 additions & 2 deletions userguide/content/en/docs/adding-content/repository-links.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,65 @@ The Docsy [docs and blog layouts](/docs/adding-content/content/#adding-docs-and-

This page shows you how to configure these links.

Currently, Docsy supports only GitHub repository links "out of the box". Since GitLab can handle the same link scheme, it should work as well. If you are using another repository such as Bitbucket and would like generated repository links, feel free to [add a feature request or update our theme](/docs/contribution-guidelines/).
Currently, Docsy supports GitHub, Azure de and Gitea repository links "out of the box". Since GitLab can handle the same link scheme as GitHub, it should work as well. If you are using another repository such as Bitbucket and would like generated repository links, feel free to [add a feature request or update our theme](/docs/contribution-guidelines/).

## Link configuration

There are four site variables you can configure in `hugo.toml`/`hugo.yaml`/`hugo.json` to set up links, as well as one in your page metadata.
There are a few site variables you can configure in `hugo.toml`/`hugo.yaml`/`hugo.json` to set up links, as well as one in your page metadata.

{{< tabpane >}}
{{< tab header="Configuration file:" disabled=true />}}
{{< tab header="hugo.toml" lang="toml" >}}
[params.repo]
type = "github"
url = "https://github.com/google/docsy"
subdir = "userguide"
branch = "release"
project_url = "https://github.com/google/docsy
{{< /tab >}}
{{< tab header="hugo.yaml" lang="yaml" >}}
params:
repo:
type: github
url: https://github.com/google/docsy
subdir: "userguide"
branch: "release"
project_url: "https://github.com/google/docsy
{{< /tab >}}
{{< tab header="hugo.json" lang="json" >}}
{
"params": {
"repo": {
"type": "github",
"url": "https://github.com/google/docsy",
"subdir": "userguide",
"branch"= "release",
"project_url" = "https://github.com/google/docsy
}
}
}
{{< /tab >}}
{{< /tabpane >}}

### `repo.type`

### `repo.url`

### `repo.subdir` (optional)

### `repo.branch` (optional)

### `repo.project_url` (optional)

### Working with git submodules (`path_base_for_subdir`)

## GitHub configuration (deprecated)

{{% alert title="Deprecation note" color="warning" %}}
These setting are deprecated. Use the params described in [Link Configuration][] instead.

[Link Configuration]: #link-configuration
{{% /alert %}}

### `github_repo`

Expand Down

0 comments on commit d776e07

Please sign in to comment.