Skip to content

Commit c91b7ca

Browse files
authored
Merge pull request #675 from oasisprotocol/njelich/document-github-action
Add GitHub action link for Oasis CLI
2 parents f4015f0 + a4faf23 commit c91b7ca

File tree

3 files changed

+45
-1
lines changed

3 files changed

+45
-1
lines changed

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ This is the official command-line interface (CLI) for interacting with the
1717
[Oasis Runtime SDK]:
1818
https://github.com/oasisprotocol/oasis-sdk/tree/main/runtime-sdk
1919

20+
## Installation
21+
22+
For multiple Oasis CLI installation methods, please
23+
refer to the [Setup Guide](docs/setup.mdx).
24+
2025
## Building
2126

2227
To build the CLI, run the following:

docs/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,6 @@ It boasts a number of handy features:
4545
calls
4646
- debugging tools for deployed Wasm contracts
4747
- inspection of blocks, transactions, results and events
48+
- install via
49+
[GitHub Action](https://github.com/oasisprotocol/setup-cli-action)
4850

docs/setup.mdx

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ import TabItem from '@theme/TabItem';
1010
## Download and Run
1111

1212
The Oasis team provides CLI binaries for Linux,
13-
macOS and Windows operating systems.
13+
macOS and Windows operating systems, as well as
14+
a GitHub Action for CI/CD installs.
1415
If you want to run it on another platform,
1516
you can [build the CLI from source][cli-source].
1617

@@ -140,6 +141,42 @@ follow the instructions for **your platform** below:
140141
oasis --version
141142
```
142143
</TabItem>
144+
145+
<TabItem value="gh-action" label="GitHub Action">
146+
To setup Oasis CLI for GitHub CI/CD workflows, we recommend using
147+
our [setup-cli-action](https://github.com/oasisprotocol/setup-cli-action)
148+
GitHub Action.
149+
150+
#### Setup
151+
152+
Simply add a Setup Oasis CLI step to your workflow:
153+
154+
```yaml
155+
steps:
156+
- name: Setup Oasis CLI
157+
uses: oasisprotocol/setup-cli-action
158+
```
159+
160+
#### Verify
161+
162+
```yaml
163+
- name: Check Oasis CLI version
164+
run: oasis --version
165+
```
166+
167+
#### Configuration
168+
169+
Optionally you can use the version parameter to install a different version of the CLI.
170+
171+
```yaml
172+
steps:
173+
- name: Setup Oasis CLI
174+
uses: oasisprotocol/setup-cli-action
175+
with:
176+
version: '0.14.3'
177+
```
178+
</TabItem>
179+
143180
</Tabs>
144181
145182
## Update

0 commit comments

Comments
 (0)