@5ive-tech/cli 1.0.6 → 1.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +62 -72
  2. package/package.json +4 -4
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Five CLI
1
+ # 5IVE CLI
2
2
 
3
3
  CLI for building, testing, deploying, and executing 5ive DSL programs.
4
4
 
@@ -6,7 +6,7 @@ CLI for building, testing, deploying, and executing 5ive DSL programs.
6
6
 
7
7
  ```bash
8
8
  npm install -g @5ive-tech/cli
9
- five --version
9
+ 5ive --version
10
10
  ```
11
11
 
12
12
  Or run without global install:
@@ -20,14 +20,14 @@ npx @5ive-tech/cli --help
20
20
  ### 1) Initialize a project
21
21
 
22
22
  ```bash
23
- five init my-program
23
+ 5ive init my-program
24
24
  cd my-program
25
25
  ```
26
26
 
27
27
  ### 2) Compile to a `.five` artifact (recommended)
28
28
 
29
29
  ```bash
30
- five compile src/main.v -o build/main.five
30
+ 5ive compile src/main.v -o build/main.five
31
31
  ```
32
32
 
33
33
  The `.five` artifact contains bytecode and ABI and is the best default for deployment and SDK integration.
@@ -35,29 +35,29 @@ The `.five` artifact contains bytecode and ABI and is the best default for deplo
35
35
  ### 3) Run locally
36
36
 
37
37
  ```bash
38
- five execute build/main.five --local -f 0
38
+ 5ive execute build/main.five --local -f 0
39
39
  ```
40
40
 
41
41
  ### 4) Configure on-chain target
42
42
 
43
43
  ```bash
44
- five config init
45
- five config set --target devnet
46
- five config set --keypair ~/.config/solana/id.json
47
- five config set --program-id <FIVE_VM_PROGRAM_ID> --target devnet
44
+ 5ive config init
45
+ 5ive config set --target devnet
46
+ 5ive config set --keypair ~/.config/solana/id.json
47
+ 5ive config set --program-id <FIVE_VM_PROGRAM_ID> --target devnet
48
48
  ```
49
49
 
50
50
  ### 5) Deploy and execute on-chain
51
51
 
52
52
  ```bash
53
- five deploy build/main.five --target devnet
54
- five execute build/main.five --target devnet -f 0
53
+ 5ive deploy build/main.five --target devnet
54
+ 5ive execute build/main.five --target devnet -f 0
55
55
  ```
56
56
 
57
57
  If you already have a deployed script account:
58
58
 
59
59
  ```bash
60
- five execute --script-account <SCRIPT_ACCOUNT_PUBKEY> --target devnet -f 0
60
+ 5ive execute --script-account <SCRIPT_ACCOUNT_PUBKEY> --target devnet -f 0
61
61
  ```
62
62
 
63
63
  ## Program ID Resolution
@@ -66,7 +66,7 @@ For on-chain commands (`deploy`, `execute`, `deploy-and-execute`, `namespace`),
66
66
 
67
67
  1. `--program-id` flag
68
68
  2. `five.toml` `[deploy].program_id`
69
- 3. `five config` stored value for current target
69
+ 3. `5ive config` stored value for current target
70
70
  4. `FIVE_PROGRAM_ID` environment variable
71
71
 
72
72
  If none are set, on-chain commands fail fast with a program ID setup error.
@@ -76,139 +76,129 @@ If none are set, on-chain commands fail fast with a program ID setup error.
76
76
  ### Project build flow
77
77
 
78
78
  ```bash
79
- five build
80
- five deploy build/main.five --project .
81
- five execute build/main.five --project . -f 0
79
+ 5ive build
80
+ 5ive deploy build/main.five --project .
81
+ 5ive execute build/main.five --project . -f 0
82
82
  ```
83
83
 
84
- `five build` / `--project` use `five.toml` and the generated manifest to resolve artifacts.
84
+ `5ive build` / `--project` use `five.toml` and the generated manifest to resolve artifacts.
85
85
 
86
- ### One-command deploy+execute (great for smoke tests)
86
+ ### One-command deploy+execute (smoke tests)
87
87
 
88
88
  ```bash
89
- five deploy-and-execute build/main.five --target devnet -f 0
89
+ 5ive deploy-and-execute build/main.five --target devnet -f 0
90
90
  ```
91
91
 
92
92
  ### Run tests
93
93
 
94
94
  ```bash
95
- five test --sdk-runner
96
- five test tests/ --on-chain --target devnet
95
+ 5ive test --sdk-runner
96
+ 5ive test tests/ --on-chain --target devnet
97
97
  ```
98
98
 
99
99
  ### Namespace operations
100
100
 
101
101
  ```bash
102
- five namespace register @your-domain
103
- five namespace bind @your-domain/program --script <SCRIPT_ACCOUNT_PUBKEY>
104
- five namespace resolve @your-domain/program
102
+ 5ive namespace register @your-domain
103
+ 5ive namespace bind @your-domain/program --script <SCRIPT_ACCOUNT_PUBKEY>
104
+ 5ive namespace resolve @your-domain/program
105
105
  ```
106
106
 
107
- ## Advanced CLI Workflows (Optional)
107
+ ## Advanced Workflows (Optional)
108
108
 
109
- Most teams can stay on the quick-start path. Use these features when you need deeper control.
110
-
111
- ### 1) Compile diagnostics and machine-readable metrics
109
+ ### Compile diagnostics and machine-readable metrics
112
110
 
113
111
  ```bash
114
- five compile src/main.v \
112
+ 5ive compile src/main.v \
115
113
  --analyze \
116
114
  --metrics-output build/compile-metrics.json \
117
115
  --metrics-format json \
118
116
  --error-format json
119
117
  ```
120
118
 
121
- ### 2) Project-aware execution from `five.toml` context
119
+ ### Project-aware execution from `five.toml` context
122
120
 
123
121
  ```bash
124
- five execute --project . -f 0
125
- five execute --project . -f 0 --params params.json --target devnet
122
+ 5ive execute --project . -f 0
123
+ 5ive execute --project . -f 0 --params params.json --target devnet
126
124
  ```
127
125
 
128
- ### 3) Deploy large artifacts with chunk/optimization controls
126
+ ### Deploy large artifacts with chunk/optimization controls
129
127
 
130
128
  ```bash
131
- five deploy build/main.five --target devnet --optimized --progress
132
- five deploy build/main.five --target devnet --force-chunked --chunk-size 900
133
- five deploy build/main.five --target devnet --dry-run --format json
129
+ 5ive deploy build/main.five --target devnet --optimized --progress
130
+ 5ive deploy build/main.five --target devnet --force-chunked --chunk-size 900
131
+ 5ive deploy build/main.five --target devnet --dry-run --format json
134
132
  ```
135
133
 
136
- ### 4) Deploy-and-execute for fast integration checks
134
+ ### Deploy-and-execute for fast integration checks
137
135
 
138
136
  ```bash
139
- five deploy-and-execute build/main.five --target devnet -f 0 -p "[100]"
140
- five deploy-and-execute src/main.v --target local --debug --cleanup
137
+ 5ive deploy-and-execute build/main.five --target devnet -f 0 -p "[100]"
138
+ 5ive deploy-and-execute src/main.v --target local --debug --cleanup
141
139
  ```
142
140
 
143
- ### 5) Advanced test modes
141
+ ### Advanced test modes
144
142
 
145
143
  ```bash
146
- five test --sdk-runner --format json
147
- five test test-scripts/ --on-chain --target devnet --batch --analyze-costs
148
- five test --watch --parallel 4
144
+ 5ive test --sdk-runner --format json
145
+ 5ive test test-scripts/ --on-chain --target devnet --batch --analyze-costs
146
+ 5ive test --watch --parallel 4
149
147
  ```
150
148
 
151
- ### 6) Namespace manager and lockfile modes
149
+ ### Namespace manager and lockfile modes
152
150
 
153
151
  ```bash
154
152
  # On-chain manager flow
155
- five namespace register @acme --manager <MANAGER_SCRIPT_ACCOUNT>
156
- five namespace bind @acme/payments --script <SCRIPT_ACCOUNT_PUBKEY> --manager <MANAGER_SCRIPT_ACCOUNT>
153
+ 5ive namespace register @acme --manager <MANAGER_SCRIPT_ACCOUNT>
154
+ 5ive namespace bind @acme/payments --script <SCRIPT_ACCOUNT_PUBKEY> --manager <MANAGER_SCRIPT_ACCOUNT>
157
155
 
158
156
  # Local lockfile-only flow (no manager RPC)
159
- five namespace resolve @acme/payments --local
157
+ 5ive namespace resolve @acme/payments --local
160
158
  ```
161
159
 
162
- ### 7) Config layering and explicit RPC overrides
160
+ ### Config layering and explicit RPC overrides
163
161
 
164
162
  ```bash
165
- five config set --rpc-url https://api.devnet.solana.com --target devnet
166
- five config set --show-config true
167
- five deploy build/main.five --target devnet --network https://your-rpc.example.com
163
+ 5ive config set --rpc-url https://api.devnet.solana.com --target devnet
164
+ 5ive config set --show-config true
165
+ 5ive deploy build/main.five --target devnet --network https://your-rpc.example.com
168
166
  ```
169
167
 
170
168
  ## Artifact and SDK Interop
171
169
 
172
- `@5ive-tech/cli` and `@5ive-tech/sdk` work best with `.five` artifacts:
173
-
174
- - Compile with CLI to `.five`
175
- - Load and interact in SDK via ABI-aware helpers
176
- - Use the same artifact in frontend flows on [5ive.tech](https://5ive.tech)
177
-
178
- You can still use `.bin` where needed, but `.five` is the preferred default.
170
+ `@5ive-tech/cli` and `@5ive-tech/sdk` work best with `.five` artifacts.
179
171
 
180
172
  ## Common Commands
181
173
 
182
174
  ```bash
183
- five help <command>
184
- five help compile
185
- five help deploy
186
- five help execute
187
- five help config
175
+ 5ive help <command>
176
+ 5ive help compile
177
+ 5ive help deploy
178
+ 5ive help execute
179
+ 5ive help config
188
180
  ```
189
181
 
190
182
  ## Troubleshooting
191
183
 
192
184
  ### `Program ID required` or `owner/program mismatch`
193
185
 
194
- Set or override the VM program ID:
195
-
196
186
  ```bash
197
- five config set --program-id <FIVE_VM_PROGRAM_ID> --target devnet
187
+ 5ive config set --program-id <FIVE_VM_PROGRAM_ID> --target devnet
198
188
  # or
199
- five deploy build/main.five --program-id <FIVE_VM_PROGRAM_ID> --target devnet
189
+ 5ive deploy build/main.five --program-id <FIVE_VM_PROGRAM_ID> --target devnet
200
190
  ```
201
191
 
202
192
  ### `Keypair file not found`
203
193
 
204
194
  ```bash
205
- five config set --keypair ~/.config/solana/id.json
195
+ 5ive config set --keypair ~/.config/solana/id.json
206
196
  ```
207
197
 
208
- ### Command-specific help from global help flow
198
+ ### Command-specific help
209
199
 
210
200
  ```bash
211
- five compile --help
212
- five execute --help
213
- five config --help
201
+ 5ive compile --help
202
+ 5ive execute --help
203
+ 5ive config --help
214
204
  ```
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@5ive-tech/cli",
3
- "version": "1.0.6",
3
+ "version": "1.0.7",
4
4
  "description": "High-performance CLI for Five VM development with WebAssembly integration",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "bin": {
8
- "five": "dist/index.js",
9
- "five-cli": "dist/index.js"
8
+ "5ive": "dist/index.js",
9
+ "five": "dist/index.js"
10
10
  },
11
11
  "engines": {
12
12
  "node": ">=18.0.0"
@@ -79,7 +79,7 @@
79
79
  "ora": "^8.0.1",
80
80
  "semver": "^7.6.0",
81
81
  "ws": "^8.16.0",
82
- "@5ive-tech/sdk": "^1.1.3"
82
+ "@5ive-tech/sdk": "^1.1.4"
83
83
  },
84
84
  "devDependencies": {
85
85
  "@types/fs-extra": "^11.0.4",