This repository contains the smart contracts for the Krystal Vault. The contracts are written in Solidity and are designed to work with the Ethereum blockchain and other EVM-compatible chains. The contracts should work well with all Uniswap V3 Liquidity Pool types.
To install the dependencies, run:
yarn install
To compile the smart contracts, run:
yarn compile
To run the tests, use:
yarn test
To deploy the contracts, use:
yarn deploy -c base -n mainnet
The deployment scripts logic are located in the scripts
directory. The main deployment logic script is
deployLogic.ts
. The main deployment script is cmd.sh
. The deployment script uses the hardhat
framework to deploy
the contracts.
The main contracts in this repository are:
KrystalVault
: The main vault contract.KrystalVaultFactory
: Factory contract to create new vault instances.
The contracts emit various events. Some of the key events are:
AddLiquidity
Approval
Compound
EIP712DomainChanged
FeeCollected
Initialized
OwnershipTransferred
SetFee
SetWhitelist
Transfer
VaultDeposit
VaultExit
VaultPositionMint
VaultRebalance
VaultWithdraw
OwnershipTransferred
Paused
Unpaused
VaultCreated