https://github.com/postech-dao/polkadot
https://github.com/postech-dao/polkadot
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/postech-dao/polkadot
- Owner: postech-dao
- License: mit
- Created: 2022-06-28T01:19:21.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-09-18T14:41:00.000Z (over 2 years ago)
- Last Synced: 2025-03-24T00:09:53.309Z (about 2 months ago)
- Language: TypeScript
- Size: 111 KB
- Stars: 4
- Watchers: 1
- Forks: 6
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# polkadot
## Reference
[Astar](https://docs.astar.network/) [Polkadot](https://wiki.polkadot.network/)
[Substrate](https://docs.substrate.io/quick-start/)## Run
### Build
```
cargo build --all
```### Format
```
cargo +nightly fmt
```### Lint
```
cargo clippy --all --all-targets --release
```### Test
```
TEST_CONFIG=test_config_example.json cargo test --all
```### Create new contract
```
cargo contract new [contract name]
```### Build contract
To build a contract, execute this command with the path of `Cargo.toml` in the
contract folder to build. Build `simple_counter` with the cargo command and then
upload and instantiate `.contract` file in `target/ink/your_contract/` on
[Polkadot js Apps](https://polkadot.js.org/apps/?rpc=wss%3A%2F%2Frococo-contracts-rpc.polkadot.io#/)```
cargo +nightly contract build --manifest-path ./simple_counter/Cargo.toml
```### Test specific contract
To test specific contract, execute `cargo +nightly contract test` with
`--manifest-path` with the path of `Cargo.toml`.
e.g. Test `simple_counter` with this command.```
cargo +nightly contract test --manifest-path ./simple_counter/Cargo.toml
```