Skip to content

pooltogether/pooltogether-contracts-template

Repository files navigation

PoolTogether Brand


PoolTogether Contracts Template

Coverage Status

Tests

Usage

  1. Clone this repo: git clone git@github.com:pooltogether/pooltogether-contracts-template.git <DESTINATION REPO>
  2. Create repo using Github GUI
  3. Set remote repo (git remote add origin git@github.com:pooltogether/<NAME_OF_NEW_REPO>.git),
  4. Checkout a new branch (git checkout -b name_of_new_branch)
  5. Begin implementing as appropriate.
  6. Update this README

Usage

This repo is setup to compile (nvm use && yarn compile) and successfully pass tests (yarn test)

Preset Packages

Generic Proxy Factory

The minimal proxy factory is a powerful pattern used throughout PoolTogethers smart contracts. A typescript package is available to use a generic deployed instance. This is typically used in the deployment script.

Generic Registry

The generic registry is a iterable singly linked list data structure that is commonly used throughout PoolTogethers contracts. Consider using this where appropriate or deploying in a seperate repo such as the (Prize Pool Registry)[https://github.com/pooltogether/pooltogether-prizepool-registry.

Installation

Install the repo and dependencies by running: yarn

Deployment

These contracts can be deployed to a network by running: yarn deploy <networkName>

Verification

These contracts can be verified on Etherscan, or an Etherscan clone, for example (Polygonscan) by running: yarn etherscan-verify <ethereum network name> or yarn etherscan-verify-polygon matic

Testing

Run the unit tests locally with: yarn test

Coverage

Generate the test coverage report with: yarn coverage

About

Template opinionated repo to setup contract projects

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published