Skip to content

Latest commit

 

History

History
111 lines (91 loc) · 3.33 KB

README.md

File metadata and controls

111 lines (91 loc) · 3.33 KB

Firm Protocol

Firm protocol

A protocol to create and run internet-native companies.

Background

Firm protocol is our interpretation of what the software core of internet-native companies should be. The protocol is non-custodial and allows founders to create and run a company whose basic rules and rights are controlled and enforced with code.

See the full protocol documentation.

Development

Install Foundry

curl -L https://foundry.paradigm.xyz | bash
foundryup

Build and test

git clone https://github.com/firm-org/firm-protocol.git
forge install
forge build
forge test
forge coverage --report lcov

Local environment

Start Anvil:

anvil

Run the deployment script for the contracts; the sender address will be 0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266 which is anvil's default:

scripts/deploy-local

The forge script will return the addresses of both FirmFactory and the modules factory. This will be at the beginning of script's output (before the transaction broadcasting)

The FirmFactory is the last deployed contract, you can verify that it was correctly deployed by performing a call to it:

cast call [FirmFactory address] "moduleFactory()(address)"

Live deployments

Make sure the git repo is not dirty and force a clean build:

forge build --force

Use FirmFactoryDeploy script to deploy to a live network (add flags to forge script for your deployment account to be used):

forge script scripts/FirmFactoryDeploy.s.sol:FirmFactoryDeployLive --broadcast --fork-url [JSON-RPC for network to deploy to]

Audits

Firm protocol v1 has been audited prior to release. See audits directory.

License

GPL 3.0