Skip to content

Commit a815632

Browse files
committed
Updated README
1 parent 4074fb4 commit a815632

File tree

1 file changed

+15
-9
lines changed

1 file changed

+15
-9
lines changed

README.md

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ rustup show
3131

3232
确保在'installed targets'下显示'wasm32-unknown-unknown'。
3333

34-
### 1.3 接着安装[cargo-generate](https://github.com/ashleygwilliams/cargo-generate)和cargo-run-script
34+
### 1.3 接着安装[cargo-generate](https://github.com/ashleygwilliams/cargo-generate)和cargo-run-script
3535

3636
```sh
3737
cargo install cargo-generate --features vendored-openssl
@@ -46,7 +46,7 @@ cargo --list
4646

4747
确保命令列表中显示'generate'和'run-script'。
4848

49-
### 1.4 最后安装Injectived
49+
### 1.4 最后安装Injectived
5050

5151
```sh
5252
wget https://github.com/InjectiveLabs/injective-chain-releases/releases/download/v1.15.0-1748457819/linux-amd64.zip
@@ -63,9 +63,9 @@ injectived version
6363

6464
## 2. 创建Counter项目
6565

66-
### 2.1 创建Counter合约
66+
### 2.1 创建项目
6767

68-
现在,创建Counter项目,转到放置它的文件夹并运行:
68+
创建Counter项目,并转到它的文件夹:
6969

7070
```sh
7171
cargo generate --git https://github.com/CosmWasm/cw-template.git --name counter
@@ -99,7 +99,7 @@ docker run --rm -v "$(pwd)":/code \
9999
cosmwasm/optimizer:0.16.0
100100
```
101101

102-
或者,如果你在arm64机器上,你应该使用为arm64构建的docker镜像
102+
或者,如果你在arm64机器上,你应该使用为arm64构建的docker镜像
103103

104104
```sh
105105
docker run --rm -v "$(pwd)":/code \
@@ -125,7 +125,7 @@ injectived config set client node https://k8s.testnet.tm.injective.network:443
125125
injectived q bank balances ACCOUNT_ADDRESS
126126
```
127127

128-
确保显示账户余额
128+
确保账户余额能正确显示
129129

130130
### 3.2 添加钱包账户:
131131

@@ -142,6 +142,12 @@ injectived keys unsafe-import-eth-key ACCOUNT_NAME $PRIVATE_KEY
142142
injectived keys list
143143
```
144144

145+
确保账户内有INJ测试币:
146+
147+
```sh
148+
injectived q bank balances ACCOUNT_ADDRESS
149+
```
150+
145151
### 3.3 上传WSAM合约:
146152

147153
```sh
@@ -159,7 +165,7 @@ yes $KEYRING_PASSWORD | injectived tx wasm store artifacts/counter.wasm \
159165
injectived query tx $TRANSACTION_HASH --node=https://testnet.sentry.tm.injective.network:443
160166
```
161167

162-
记下node id。
168+
记下code id。
163169

164170
## 4. 与合约交互:
165171

@@ -194,7 +200,7 @@ injectived query wasm contract-state smart $CONTRACT_ADDRESS "$GET_COUNT_QUERY"
194200
--output json
195201
```
196202

197-
## 4.4 执行Increment程序:
203+
### 4.4 执行Increment程序:
198204

199205
```sh
200206
INCREMENT='{"increment":{}}'
@@ -205,7 +211,7 @@ yes $KEYRING_PASSWORD | injectived tx wasm execute $CONTRACT_ADDRESS "$INCREMENT
205211
--output json
206212
```
207213

208-
验证Increment:
214+
再次获取合约计数以验证:
209215

210216
```sh
211217
GET_COUNT_QUERY='{"get_count":{}}'

0 commit comments

Comments
 (0)