0.0.20 • Published 24 days ago

@rev-net/core v0.0.20

Weekly downloads
-
License
MIT
Repository
github
Last release
24 days ago

Revnet

This repo provides tools for deploying Revnets: Retailistic networks, using the Juicebox and Uniswap protocols for its implementation.

For a Retailism TLDR, see https://jango.eth.limo/9E01E72C-6028-48B7-AD04-F25393307132/.

For more Retailism information, see:

A Retailistic View on CAC and LTV https://jango.eth.limo/572BD957-0331-4977-8B2D-35F84D693276/

Modeling Retailism https://jango.eth.limo/B762F3CC-AEFE-4DE0-B08C-7C16400AF718/

Retailism for Devs, Investors, and Customers https://jango.eth.limo/3EB05292-0376-4B7D-AFCF-042B70673C3D/

Observations: Network dynamics similar between atoms, cells, organisms, groups, dance parties. https://jango.eth.limo/CF40F5D2-7BFE-43A3-9C15-1C6547FBD15C/

Join the conversation here: https://discord.gg/nT3XqbzNEr

In this repo, you'll find:

  • a basic revnet design implemented in BasicRevnetDeployer.
  • a design that accepts other pay hooks implemented in PayHookRevnetDeployer, which accepts other pay hooks that'll get used throughout the revnet's lifetime as it receives payments.
  • a design that supports tiered 721 pay hooks implemented in Tiered721RevnetDeployer, which accepts data to deploy a tiered 721 pay hook that'll get used throughout the network's lifetime as people pay in, alongside other pay hooks that may also be specified.
  • a design supports croptop, implemented in CroptopRevnetDeployer, which accepts data to deploy a tiered 721 pay hook that'll get used throughout the project's lifetime as people pay in that can also be posted to by the public through the croptop publisher contract. See https://croptop.eth.limo for more context.

You can use these contracts to deploy treasuries from etherscan, or wherever else they've been exposed from.

Install

For npm projects (recommended):

npm install @bananapus/721-hook

For forge projects (not recommended):

forge install Bananapus/nana-721-hook

Add @bananapus/721-hook/=lib/nana-721-hook/ to remappings.txt. You'll also need to install nana-721-hook's dependencies and add similar remappings for them.

Develop

nana-721-hook uses npm for package management and the Foundry development toolchain for builds, tests, and deployments. To get set up, install Node.js and install Foundry:

curl -L https://foundry.paradigm.xyz | sh

You can download and install dependencies with:

npm install && forge install

If you run into trouble with forge install, try using git submodule update --init --recursive to ensure that nested submodules have been properly initialized.

Some useful commands:

CommandDescription
forge buildCompile the contracts and write artifacts to out.
forge fmtLint.
forge testRun the tests.
forge build --sizesGet contract sizes.
forge coverageGenerate a test coverage report.
foundryupUpdate foundry. Run this periodically.
forge cleanRemove the build artifacts and cache directories.

To learn more, visit the Foundry Book docs.

Scripts

For convenience, several utility commands are available in package.json.

CommandDescription
npm testRun local tests.
npm run coverage:lcovGenerate an LCOV test coverage report.
npm run deploy:ethereum-mainnetDeploy to Ethereum mainnet
npm run deploy:ethereum-sepoliaDeploy to Ethereum Sepolia testnet
npm run deploy:optimism-mainnetDeploy to Optimism mainnet
npm run deploy:optimism-testnetDeploy to Optimism testnet
0.0.20

24 days ago

0.0.16

2 months ago

0.0.17

1 month ago

0.0.18

1 month ago

0.0.19

1 month ago

0.0.15

2 months ago

0.0.14

2 months ago

0.0.13

2 months ago

0.0.12

3 months ago

0.0.10

3 months ago

0.0.11

3 months ago

0.0.9

3 months ago

0.0.3

3 months ago

0.0.8

3 months ago

0.0.4

3 months ago

0.0.7

3 months ago

0.0.6

3 months ago

0.0.2

3 months ago

0.0.1

3 months ago