Skip to content

Commit 3cfbf65

Browse files
docs: add setup documentation for Oasis CLI for mac
docs: move macos installation section to setup.md docs: link to macos installation instructions feat: add different platfrom Instructions tabs fix: match config info order with tabs above fix: doc review updates
1 parent e86381a commit 3cfbf65

3 files changed

Lines changed: 151 additions & 85 deletions

File tree

docs/README.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,10 @@ description: Powerful CLI for managing Oasis networks, nodes, tokens and dApps
66
# Oasis Command Line Interface
77

88
Oasis command-line interface (CLI) is a powerful all-in-one tool for
9-
interacting with the Oasis Network. You can download the latest release
10-
binaries from the [GitHub repository].
9+
interacting with the Oasis Network.
10+
Head to the **[installation instructions]** to download and install it!
11+
12+
[installation instructions]: setup.mdx
1113

1214
It boasts a number of handy features:
1315

@@ -19,8 +21,8 @@ It boasts a number of handy features:
1921
- connecting to remote (via TCP/IP) or local (Unix socket) Oasis node
2022
instance
2123
- Powerful wallet features:
22-
- standard token operations (transfers, allowances, deposits, withdrawals and
23-
balance queries)
24+
- standard token operations (transfers, allowances, deposits, withdrawals
25+
and balance queries)
2426
- file-based wallet with password protection
2527
- full Ledger hardware wallet support
2628
- address book
@@ -32,7 +34,7 @@ It boasts a number of handy features:
3234
schemes
3335
- raw, BIP-44, ADR-8 and Ledger's legacy derivation paths
3436
- Node operator features:
35-
- Oasis node inspection and healthchecks
37+
- Oasis node inspection and health-checks
3638
- network governance transactions
3739
- staking reward schedule transactions
3840
- Developer features:
@@ -43,5 +45,4 @@ It boasts a number of handy features:
4345
calls
4446
- debugging tools for deployed Wasm contracts
4547
- inspection of blocks, transactions, results and events
46-
47-
[GitHub repository]: https://github.com/oasisprotocol/cli/releases
48+

docs/setup.md

Lines changed: 0 additions & 78 deletions
This file was deleted.

docs/setup.mdx

Lines changed: 143 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,143 @@
1+
import Tabs from '@theme/Tabs';
2+
import TabItem from '@theme/TabItem';
3+
4+
# Setup
5+
6+
## Download and Run
7+
8+
Download the latest release from our [GitHub repository][cli-releases] and
9+
follow the instructions for **your platform** below:
10+
11+
The Oasis team provides CLI binaries for Linux, macOS and Windows operating systems. If you want to run it on another platform, you can [build the CLI from source][cli-source].
12+
13+
<Tabs>
14+
<TabItem value="Linux" label="Linux">
15+
#### Prerequisites
16+
17+
- amd64 or arm64 Linux.
18+
- Ensure `~/.local/bin` is on your `PATH`:
19+
```shell
20+
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
21+
source ~/.bashrc
22+
mkdir -p ~/.local/bin
23+
```
24+
25+
#### Installation
26+
27+
1. Download the latest **Linux** archive (e.g. `oasis_cli_X.Y.Z_linux_amd64.tar.gz`).
28+
2. Extract it:
29+
```shell
30+
cd ~/Downloads
31+
tar -xzf oasis_cli_X.Y.Z_linux_amd64.tar.gz # adjust version and architecture
32+
```
33+
3. Move the binary to your path:
34+
```shell
35+
mv oasis ~/.local/bin/
36+
```
37+
4. Verify:
38+
```shell
39+
oasis --version
40+
```
41+
</TabItem>
42+
43+
<TabItem value="macOS" label="macOS">
44+
#### Prerequisites
45+
46+
- macOS (Apple Silicon & Intel).
47+
- Ensure `~/.local/bin` is on your `PATH` (add it in `~/.zshrc` or `~/.bashrc`):
48+
```shell
49+
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
50+
source ~/.zshrc
51+
mkdir -p ~/.local/bin
52+
```
53+
54+
#### Installation
55+
56+
1. Download the latest **macOS** archive (e.g. `oasis_cli_X.Y.Z_darwin_all.tar.gz`) from the releases page.
57+
2. Extract it:
58+
```shell
59+
cd ~/Downloads
60+
tar -xzf oasis_cli_X.Y.Z_darwin_all.tar.gz # adjust version
61+
```
62+
3. Move the binary to your path:
63+
```shell
64+
mv oasis ~/.local/bin/
65+
```
66+
4. Bypass Gatekeeper (first run only):
67+
```shell
68+
xattr -d com.apple.quarantine ~/.local/bin/oasis
69+
```
70+
If a dialog appears, open **System Settings → Privacy & Security** and click **Open Anyway**.
71+
5. Verify:
72+
```shell
73+
oasis --version
74+
```
75+
</TabItem>
76+
77+
<TabItem value="Windows" label="Windows">
78+
#### Prerequisites
79+
80+
- Windows 10/11 (x86-64).
81+
- Decide on a folder already in your `PATH` (e.g. `%USERPROFILE%\bin`) or add one.
82+
83+
#### Installation
84+
85+
1. Download the latest **Windows** ZIP file (e.g. `oasis_cli_X.Y.Z_windows_amd64.zip`).
86+
2. Extract it (double-click or `tar -xf` in PowerShell).
87+
3. Copy `oasis.exe` to a directory on your `PATH`, for example:
88+
```powershell
89+
New-Item -ItemType Directory -Force "$env:USERPROFILE\bin"
90+
Copy-Item .\oasis.exe "$env:USERPROFILE\bin\"
91+
```
92+
If that folder isn’t on the `PATH`, add it via **System Properties → Environment Variables**.
93+
4. Verify:
94+
```powershell
95+
oasis --version
96+
```
97+
</TabItem>
98+
</Tabs>
99+
100+
When running the Oasis CLI for the first time, it will generate a configuration
101+
file and populate it with the current Mainnet and Testnet networks. It will also
102+
configure all [ParaTimes supported by the Oasis Foundation][paratimes].
103+
104+
## Configuration
105+
106+
The configuration folder of Oasis CLI is located:
107+
108+
- on Linux:
109+
- `$HOME/.config/oasis/`
110+
- on macOS:
111+
- `/Users/$USER/Library/Application Support/oasis/`
112+
- on Windows:
113+
- `%USERPROFILE%\AppData\Local\oasis\`
114+
115+
There, you will find `cli.toml` which contains the configuration of the
116+
networks, ParaTimes and your wallet. Additionally, each file-based account in
117+
your wallet will have a separate, password-encrypted JSON file in the same
118+
folder named after the name of the account with the `.wallet` extension.
119+
120+
## Multiple Profiles
121+
122+
You can utilize multiple profiles of your Oasis CLI. To create a new profile,
123+
move your existing configuration folder to another place, for example:
124+
125+
```shell
126+
mv $HOME/.config/oasis $HOME/.config/oasis_dev
127+
```
128+
129+
You can always use the old `oasis_dev` config by passing the `--config` parameter
130+
with a location of a desired `cli.toml`:
131+
132+
![code shell](../examples/setup/wallet-list-config.in.static)
133+
134+
![code](../examples/setup/wallet-list-config.out.static)
135+
136+
## Back Up Your Wallet
137+
138+
To back up your complete Oasis CLI configuration including your wallet, archive
139+
the configuration folder containing `cli.toml` and `.wallet` files.
140+
141+
[cli-releases]: https://github.com/oasisprotocol/cli/releases
142+
[cli-source]: https://github.com/oasisprotocol/cli
143+
[paratimes]: https://github.com/oasisprotocol/docs/blob/main/docs/build/tools/other-paratimes/README.mdx

0 commit comments

Comments
 (0)