https://github.com/pooltogether/aave-v3-yield-source
Aave V3 Yield Source
https://github.com/pooltogether/aave-v3-yield-source
Last synced: 24 days ago
JSON representation
Aave V3 Yield Source
- Host: GitHub
- URL: https://github.com/pooltogether/aave-v3-yield-source
- Owner: pooltogether
- Created: 2022-04-13T21:45:23.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2022-07-07T19:46:49.000Z (almost 4 years ago)
- Last Synced: 2025-01-12T13:14:31.728Z (over 1 year ago)
- Language: TypeScript
- Size: 1.1 MB
- Stars: 3
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# PoolTogether Aave V3 Yield Source 👻


[](https://coveralls.io/github/pooltogether/aave-v3-yield-source)
[](https://docs.openzeppelin.com/)
[](http://perso.crans.org/besson/LICENSE.html)
PoolTogether Yield Source that uses [Aave](https://aave.com) V3 to generate yield by lending any ERC20 token deposited into the Yield Source to Aave.
## Development
Clone this repository and enter the directory:
```
cd aave-v3-yield-source
```
### Installation
Install dependencies:
```
yarn
```
### Env
We use [direnv](https://direnv.net) to manage environment variables. You'll likely need to install it.
Copy `.envrc.example` and write down the env variables needed to run this project.
```
cp .envrc.example .envrc
```
Once your env variables are setup, load them with:
```
direnv allow
```
### Compile
Run the following command to compile the contract:
```
yarn compile
```
### Test
We use the [Hardhat](https://hardhat.org) ecosystem to test our contracts.
To run unit tests:
```
yarn test
```
To run coverage:
```
yarn coverage
```
### Polygon fork
Before deploying, you can make sure your implementation works by deploying a Yield Source Prize Pool on a fork of Polygon.
To do so, run the following command:
```
yarn run-yield-source-fork
```
### Code quality
[Prettier](https://prettier.io) is used to format TypeScript and Solidity code. Use it by running:
```
yarn format
```
[Solhint](https://protofire.github.io/solhint/) is used to lint Solidity files. Run it with:
```
yarn hint
```
[TypeChain](https://github.com/ethereum-ts/Typechain) is used to generates types for scripts and tests. Generate types by running:
```
yarn typechain
```