You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
lead: "The command-line interface (CLI) is a straightforward way to experiment with the Entropy network and explore common workflows."
4
4
aliases:
5
-
- "url"
5
+
- "cli"
6
6
---
7
7
8
8
{{< cards cols=2 >}}
9
9
10
-
{{< card
11
-
link="#interactive-cli"
12
-
title="Interactive CLI"
13
-
image="/images/entropy-tui-terminal.png"
14
-
subtitle="Use the text-based user interface (TUI) to interact with the CLI tool."
15
-
>}}
16
-
17
10
{{< card
18
11
link="#programmatic-cli"
19
12
title="Programmatic CLI"
20
13
image="/images/entropy-cli-terminal.png"
21
14
subtitle="Pass arguments directly to the CLI as single-line terminal commands."
22
15
>}}
23
16
24
-
{{< /cards >}}
17
+
{{< card
18
+
link="#interactive-cli"
19
+
title="Interactive CLI"
20
+
image="/images/entropy-tui-terminal.png"
21
+
subtitle="Use the text-based user interface (TUI) to interact with the CLI tool."
22
+
>}}
25
23
26
-
After installing, running `entropy` without any arguments will take you to the text-based user interface. If you pass any arguments, however, the CLI will assume you want to run the CLI as a single command.
24
+
{{< /cards >}}
27
25
28
26
## Install
29
27
@@ -49,31 +47,12 @@ Follow these steps to install Entropy globally using NPM:
49
47
npm install --global @entropyxyz/cli
50
48
```
51
49
52
-
1. You can now run the text-based interface anywhere using `entropy`:
50
+
1. You can now run the CLI from anywhere using `entropy`:
53
51
54
52
```shell
55
53
entropy
56
54
```
57
55
58
-
```output
59
-
? Select Action (Use arrow keys)
60
-
61
-
❯ Manage Accounts
62
-
Balance
63
-
Register
64
-
Sign
65
-
Transfer
66
-
Deploy Program
67
-
User Programs
68
-
Exit
69
-
```
70
-
71
-
1. You can also interact with the CLI through one-line commands by adding any of the arguments listed in the help section:
72
-
73
-
```shell
74
-
entropy --help
75
-
```
76
-
77
56
```output
78
57
Usage: entropy [options] [command]
79
58
@@ -100,119 +79,25 @@ Follow these steps to install Entropy globally using NPM:
100
79
a signature (string)
101
80
```
102
81
103
-
## Interactive CLI
104
-
105
-
The following functions are available within the CLI using the text-based user interface (TUI). To start the TUI, simply enter `entropy` without any arguments into your terminal:
106
-
107
-
### Manage Accounts
108
-
109
-
Create a new Entropy account to store locally. List all Entropy accounts stored locally. Import an account into the CLI using a seed.
110
-
111
-
```output
112
-
> Create/Import Account
113
-
Select Account
114
-
List Accounts
115
-
```
116
-
117
-
#### Create or Import Account
118
-
119
-
Create a new Entropy account or import an existing account using a seed.
120
-
121
-
#### Select Account
122
-
123
-
Select an account to use within other functions. This is relevant if you have multiple accounts.
124
82
125
-
For example, assume you have three accounts, and you want to check the balance of `account 2`. You would:
83
+
1. You can also interact with the CLI through the TUI by adding `tui`:
126
84
127
-
1. Start the CLI.
128
-
1. Navigate to **Manage Accounts**.
129
-
1. Navigate to **Select Account**.
130
-
1. Choose the account that you would like to selectand use within other functions:
131
-
132
-
```output
133
-
? Choose account: (Use arrow keys)
134
-
> Gael (5CrFp9txcb5UECpNKsD6DTBsG4cj1z58DA43YikSVeeJqXJR)
The following functions are available within the CLI using the text-based user interface (TUI). To start the TUI, simply enter `entropy tui` without any arguments into your terminal:
251
+
252
+
```shell
253
+
entropy tui
254
+
```
255
+
256
+
```output
257
+
? Select Action (Use arrow keys)
258
+
259
+
❯ Manage Accounts
260
+
Balance
261
+
Register
262
+
Sign
263
+
Transfer
264
+
Deploy Program
265
+
User Programs
266
+
Exit
267
+
```
268
+
269
+
### Manage Accounts
270
+
271
+
Create a new Entropy account to store locally. List all Entropy accounts stored locally. Import an account into the CLI using a seed.
272
+
273
+
```output
274
+
> Create/Import Account
275
+
Select Account
276
+
List Accounts
277
+
```
278
+
279
+
#### Create or Import Account
280
+
281
+
Create a new Entropy account or import an existing account using a seed.
282
+
283
+
#### Select Account
284
+
285
+
Select an account to use within other functions. This is relevant if you have multiple accounts.
286
+
287
+
For example, assume you have three accounts, and you want to check the balance of `account 2`. You would:
288
+
289
+
1. Start the CLI.
290
+
1. Navigate to **Manage Accounts**.
291
+
1. Navigate to **Select Account**.
292
+
1. Choose the account that you would like to selectand use within other functions:
293
+
294
+
```output
295
+
? Choose account: (Use arrow keys)
296
+
> Gael (5CrFp9txcb5UECpNKsD6DTBsG4cj1z58DA43YikSVeeJqXJR)
> charlie (5Ck5SLSHYac6WFt5UZRSsdJjwmpSZq85fd5TRNAdZQVzEAPT)
349
+
Other
350
+
```
351
+
352
+
### Deploy Program
353
+
354
+
Deploy a program from a locally stored account.
355
+
356
+
```output
357
+
? Select Action Deploy Program
358
+
? Select your action: (Use arrow keys)
359
+
> Deploy
360
+
Get Program Pointers
361
+
362
+
Exit
363
+
```
364
+
365
+
### User Programs
366
+
367
+
View all programs deployed to the network from locally stored accounts.
368
+
369
+
```output
370
+
? Select Action User Programs
371
+
? What would you like to do? (Use arrow keys)
372
+
> View My Programs
373
+
Add a Program to My List
374
+
Remove a Program from My List
375
+
Check if Program Exists
376
+
Exit to Main Menu
377
+
```
378
+
363
379
## Configuration
364
380
365
381
The CLI uses a configuration file to set and store basic information. This CLI uses [env-paths](https://www.npmjs.com/package/env-paths) to determine where configurations files should be stored:
0 commit comments