The following tools are not required but highly recommended for a better coding experience:
- Terminal (Mac OS only): iTerm 2 (download)
- Shell: Oh my ZSH (download)
- Code Editor: VS Code (download)
- VS Code Plugins:
-
Git of course :-)
-
pyenv-virtualenv :
-
Mac OS:
-
Install Homebrew (install)
-
Install package:
brew install pyenv-virtualenv
-
Add it to path (assuming you are using ZSH)
echo 'eval "$(pyenv init --path)"' >> ~/.zprofile
echo 'eval "$(pyenv init -)"' >> ~/.zshrc
echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.zshrc
-
-
Other OS: (Follow instructions to install)
-
-
Clone the repo
git clone git@github.com:VyperTraining/smart-contracts.git
and then:
cd smart-contracts
-
Install python version
pyenv install 3.9.8
-
Create the Python virtual environment (Only needed once)
pyenv virtualenv 3.9.8 vyper-training
-
Update PIP
pip install -U pip
-
Install Vyper
pip install vyper==0.3.3
-
Install Black (Code formatter)
pip install black
-
Install Ape Worx
pip install eth-ape
-
Install Vyper Plugin
ape plugins install vyper
- To Compile the smart-contracts, run:
ape compile
- Run tests with:
ape test