Skip to content

Commit 5a44f3c

Browse files
vinckralnr
andauthored
chore: remove duplicate in sidebar, fix install cli docs (#2276)
* chore: remove duplicate sidebar * chore: add command option to macos install snippet * chore: use install cli snippet * chore: apply suggestions from code review Co-authored-by: Arne Luenser <[email protected]> --------- Co-authored-by: Arne Luenser <[email protected]>
1 parent d0848d9 commit 5a44f3c

File tree

5 files changed

+14
-71
lines changed

5 files changed

+14
-71
lines changed

docs/_common/install-cli.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import Windows from '@site/src/components/Install/Windows'
1616
<Linux repo="ory" name="the Ory CLI" />
1717
</TabItem>
1818
<TabItem value="macos">
19-
<MacOS repo="cli" name="the Ory CLI" />
19+
<MacOS repo="cli" command="ory" name="the Ory CLI" />
2020
</TabItem>
2121
<TabItem value="windows">
2222
<Windows repo="ory" name="the Ory CLI" />

docs/_common/install.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import Linux from '@site/src/components/Install/Linux'
2222
```mdx-code-block
2323
import MacOS from '@site/src/components/Install/MacOS'
2424
25-
<MacOS repo={props.repo} name={props.name} />
25+
<MacOS repo={props.repo} command={props.command} name={props.name} />
2626
```
2727

2828
## Windows

docs/guides/cli/01_installation.mdx

Lines changed: 5 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -13,58 +13,13 @@ Network to self-hosted setups alike.
1313

1414
## Installation
1515

16-
You can install the Ory CLI directly on your machine, or run the tool in Docker.
16+
```mdx-code-block
17+
import Install from '@site/docs/_common/install-cli.mdx'
1718
18-
### macOS
19-
20-
Run this command to install the Ory CLI using Homebrew:
21-
22-
```shell
23-
brew install ory/tap/cli
24-
```
25-
26-
Verify the installation:
27-
28-
```shell
29-
ory help
30-
```
31-
32-
### Linux
33-
34-
The Ory CLI works on all Linux distributions. Run this command to install:
35-
36-
```shell
37-
bash <(curl https://raw.githubusercontent.com/ory/meta/master/install.sh) -b . ory
38-
```
39-
40-
You may want to move the Ory CLI to your `$PATH`:
41-
42-
```shell
43-
sudo mv ./ory /usr/local/bin/
44-
```
45-
46-
Verify the installation after moving to `$PATH`:
47-
48-
```shell
49-
ory help
50-
```
51-
52-
### Windows
53-
54-
To install the CLI on Windows, use [scoop](https://scoop.sh). Run:
55-
56-
```shell
57-
> scoop bucket add ory https://github.com/ory/scoop.git
58-
> scoop install ory
59-
```
60-
61-
Verify the installation:
62-
63-
```shell
64-
ory help
19+
<Install />
6520
```
6621

67-
### Docker
22+
#### Docker
6823

6924
```shell
7025
### Pull Ory CLI image
@@ -74,7 +29,7 @@ docker pull oryd/ory
7429
docker run --rm -it oryd/ory help
7530
```
7631

77-
### Binary
32+
#### Binary
7833

7934
You can download the server and client binaries from the [GitHub "releases" tab](https://github.com/ory/cli/releases).
8035

src/components/Install/MacOS.tsx

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
11
import React from "react"
22
import CodeBlock from "@theme/CodeBlock"
33

4-
export default function MacOS(props: { repo: string; name: string }) {
5-
const { repo, name } = props
4+
export default function MacOS(props: {
5+
repo: string
6+
name: string
7+
command: string
8+
}) {
9+
const { repo, name, command } = props
610
return (
711
<>
812
<p>
913
Install {name} using <a href={"https://brew.sh"}>homebrew</a> on macOS:
1014
</p>
1115
<CodeBlock language="shell">{`brew install ory/tap/${repo}
12-
${repo} help`}</CodeBlock>
16+
${command} help`}</CodeBlock>
1317
</>
1418
)
1519
}

src/sidebar.ts

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -731,22 +731,6 @@ const hydra: SidebarItemsConfig = [
731731
items: [
732732
"hydra/self-hosted/deploy-hydra-example",
733733
"hydra/self-hosted/upgrade",
734-
"hydra/reference/api",
735-
{
736-
"Command Line Interface (CLI)": [
737-
{
738-
type: "autogenerated",
739-
dirName: "hydra/cli",
740-
},
741-
],
742-
},
743-
{
744-
SDK: [
745-
"hydra/sdk/overview",
746-
"hydra/self-hosted/go",
747-
"hydra/self-hosted/js",
748-
],
749-
},
750734
],
751735
},
752736
{

0 commit comments

Comments
 (0)