Crowdship is an open source project built with simplicity in mind for anyone looking to setup their own crowdfunding initiative, with inspiration from the likes of kickstarter, indiegogo e.t.c Crowdship aims to be familiar while adding on concepts from the blockchain e.g
- Governance Protocol
- Concensus Mechanism
- Private Campaigns
- Backers vote on fund management
- Censorship resistant
- Reward delivery assurance
- Contract documentation on methods, events and variables can be found here.
- Crowdship UI - https://github.com/carterax/crowdship-v1-interface
- Crowdship Subgraph - https://github.com/carterax/crowdship-v1-subgraph
To work on the contracts locally there are a few requirements
In the terminal, clone https://github.com/carterax/crowdship and install dependencies
git clone https://github.com/carterax/crowdship.git
cd crowdship
npm i
Compile and generate the contracts
npm run postinstall
After npm run migrate
take note of the contract addresses returned in the terminal
ganache-cli --deterministic
npm run migrate
This opens up truffle console on the default development network; Open the console on rinkeby scroll to scripts.
npm run truffle-console
factory = await Factory.at("0x00") //replace 0x00 with your contract address
deployedCampaignCount = await factory.deployedCampaignCount()
Deploying to Remix
Make sure you have Metamask installed and setup
- In the select input under workspaces select
connect to localhost
, Follow the instruction given in the modal. - Open and compile all contracts under
./contracts/*.sol
usingsolc v0.8.0
- Under compiler configuration enable
optimization
with a runs value of1
, hit the compile button - Under deploy & run transactions from the select dropdown, choose
Injected web3
- Deploy
Factory.sol
CampaignFactory.sol
CampaignReward.sol
andCampaign.sol
, after deploying these contracts please take note of their addresses as they would be required for various implementations across some contracts. - After deployment you can now interact with the contract methods 🎉
Ensure ganche is running
npm run test
Script | Feature |
---|---|
npm run docs |
Generates documentation for the contracts, using Openzeppelin's docgen |
npm run coverage |
Generates test coverage |
npm run contract-size |
Outputs the contract size so far, run after compiling contracts |
npm run truffle-console:rinkeby |
Opens truffle console with the network set to rinkeby |
MIT