inkdevhub / swanky-cli

The all-in-one developer environment for Parity pallet-contracts based smart contracts!
https://docs.astar.network/docs/build/wasm/swanky-suite/cli/
MIT License
70 stars 29 forks source link

add `env` command #178

Closed codespool closed 3 months ago

codespool commented 1 year ago

Overview (What and Why)

We should provide an easy way to install the dev environment locally. It makes sense to move the check command under the env command, and also add something like env install with optional --all or --deps flags to install everything or specify single deps.

All the install commands can be taken from the base-image Docker file.

swanky.config should keep track of the env deps in the new env field, and the command should read from there, or overwrite it if a version is specified when the command is invoked

How

Definition of Done

Open Issues and Blockers

vsofiya commented 6 months ago

https://github.com/inkdevhub/swanky-cli/pull/190

pmikolajczyk41 commented 4 months ago

since #190 is already merged, I will express my approval here, although with one question:

when I try to install just a single dependency, swanky seems to be installing all of them:

../bin/run.js env install -d cargo-dylint
✔ Installing rust OK
✔ Installing cargo-dylint OK
⠋   Installing cargo-contract^

is this because my local versions differ from the default ones? @ipapandinas

ipapandinas commented 4 months ago

thank you for your review @pmikolajczyk41, the command was always installing all dependencies again. I've updated it to make the --all flag implicit and have removed it. If specific dependencies are provided using the --deps flag, only those specified dependencies will be installed