The package.json
file at the root folder contains dependencies and scripts for managing the program library.
To install the required dependencies, run:
yarn install
Use avm
to install the Anchor CLI. All programs currently use Anchor version 0.30.1
.
cargo install --git https://github.com/coral-xyz/anchor --tag v0.30.1 avm --locked
avm install latest
avm use latest
anchor --version
# Should output: anchor-cli 0.30.1
lint
- Lints JavaScript and TypeScript files.lint:fix
- Fixes lint issues.version
- Creates a changelog using the git history of the repository.clients
- Generates Rust and TypeScript clients for all programs.
Each client has its own README with instructions on how to get started. You can find them in the clients
folder.
To generate the clients, run the following command:
yarn clients
You will need to run yarn clients
again to re-generate the clients whenever there are changes in the program(s).
Versions are determined by the package.json
.
- Run
anchor build
to generate IDLs for the programs/target/idls
. - Increment the package version
<MAJOR>.<MINOR>.<PATCH>
- Run
yarn clients
to re-generate program rust and js SDKs. - Increment
programs
andclients
based on the programs changed. - Commit the version bumps to git.
- Run
yarn version
. This will create a changelog based on the git history of the repository.
After reach out in the WNS Developer Telegram group to publish SDKs. In the future this will be automated using github actions.