All Projects → asseth → dao1901

asseth / dao1901

Licence: other
French 1901's Law for non-profit organizations, now on Ethereum

Programming Languages

javascript
184084 projects - #8 most used programming language
typescript
32286 projects
HTML
75241 projects
CSS
56736 projects

Projects that are alternatives of or similar to dao1901

ethdock
Ethereum development package in docker.
Stars: ✭ 25 (-13.79%)
Mutual labels:  truffle, testrpc, geth
docker-eth-dev
Hacking together a containerized environment for Ethereum development with Truffle using Parity
Stars: ✭ 22 (-24.14%)
Mutual labels:  truffle, testrpc
svelte-box
A truffle box for svelte
Stars: ✭ 60 (+106.9%)
Mutual labels:  truffle, testrpc
web3j-example
Android web3j example
Stars: ✭ 27 (-6.9%)
Mutual labels:  truffle, geth
solidity-contracts
📦 Resources for the Ethereum Smart Contract Development tutorial series.
Stars: ✭ 64 (+120.69%)
Mutual labels:  truffle, testrpc
Ethermint Archive
Ethereum on Tendermint using Cosmos-SDK!
Stars: ✭ 667 (+2200%)
Mutual labels:  truffle, geth
Truffle Next
🛰️ A boilerplate Truffle Box project with Next.js for rapid Ethereum Dapp development
Stars: ✭ 130 (+348.28%)
Mutual labels:  truffle
Erc20 Generator
Create an ERC20 Token for FREE in less than a minute with the most used Smart Contract Generator for ERC20 Token. No login. No setup. No coding required.
Stars: ✭ 202 (+596.55%)
Mutual labels:  truffle
Truffle
A tool for developing smart contracts. Crafted with the finest cacaos.
Stars: ✭ 11,909 (+40965.52%)
Mutual labels:  truffle
Web3 Vs Ethers
A basic cheatsheet of Web3.js vs Ethers (along w/ example apps!)
Stars: ✭ 103 (+255.17%)
Mutual labels:  truffle
payroll
A payroll system developed with React and Solidity for Ethereum
Stars: ✭ 28 (-3.45%)
Mutual labels:  truffle
resources
A living collection of resources for participants (and anyone who's interested) in Truffle University's courses 📚
Stars: ✭ 27 (-6.9%)
Mutual labels:  truffle
Armors Solidity
Armors-solidity is a framework to build secure smart contracts on Ethereum.
Stars: ✭ 184 (+534.48%)
Mutual labels:  truffle
Truffle Plugin Verify
✅ Verify your smart contracts on Etherscan from the Truffle CLI
Stars: ✭ 144 (+396.55%)
Mutual labels:  truffle
Sparkle Proof Of Loyalty
Sparkle Proof of Loyalty Contract
Stars: ✭ 216 (+644.83%)
Mutual labels:  truffle
Truffle Assertions
🛠 Assertions and utilities for testing Ethereum smart contracts with Truffle unit tests
Stars: ✭ 109 (+275.86%)
Mutual labels:  truffle
atomic-markets
Generalized atomic swap marketplaces for ERC-777(advanced token standard) and ERC-721 (non-fungible tokens)
Stars: ✭ 30 (+3.45%)
Mutual labels:  truffle
Contracts
A set of reusable smart-contracts
Stars: ✭ 101 (+248.28%)
Mutual labels:  truffle
Angular Truffle Starter Dapp
Angular CLI + Truffle Starter Dapp; write, compile & deploy smart contracts on Ethereum blockchains
Stars: ✭ 174 (+500%)
Mutual labels:  truffle
Graalphp
An efficient PHP implementation built on GraalVM
Stars: ✭ 233 (+703.45%)
Mutual labels:  truffle

Requirements:

  • node ^8.1.4
  • npm ^5.3.0
  • python 3.5
  • solc ^0.4.11
  • Truffle ^3.4.4
  • Testrpc ^4.0.1

Trello: https://trello.com/b/bVfPFfjM/tasks

Introduction

This application is divided in two sections, protocol and ui. Protocol folder manage all things related to Ethereum, whereas ui will import protocol as a npm module. This architecture offers a clean separation between front and back.

The UI is built with React, Redux, Redux-Saga, Bootstrap 4, Fusebox, etc.

Run the app with Testrpc and Truffle (recommended way)

At the root level, install all dependencies

npm install

In a separate tab, run testrpc

testrpc [-m yourMnemonic]
or node_modules/.bin/testrpc

In a separate tab, compile and migrate the contracts

cd customModules/protocol
[npm install]
[truffle compile --compile-all]
truffle migrate

Attach a console

truffle console
or geth attach http://localhost:8545

Serve the app

npm run dev

=> Go to http://localhost:8085/

Run UI tests (using Jest)

npm run testUI

Run Smart Contract tests (using Mocha and Chai under the hood)

npm run testProtocol

If you work on the protocol, you may want to use npm link to avoid reinstalling the lib at each change.

npm run linkprotocol

Run the app with Geth

Launch the Geth node

geth --dev --rpc --rpcapi 'web3,eth,debug' --rpccorsdomain="*" --datadir /tmp/ethereum_dev_mode

To load the auto setup

geth --dev --preload autoSetupForGeth.js attach ipc:/tmp/ethereum_dev_mode/geth.ipc

Prepare contracts to be deployed, with python, based on a template

run

npm run compile

which is equivalent to

cd ./protocol/customDeploy
python3.5 compile.py ../contracts/Owned.sol
python3.5 compile.py ../contracts/Dao1901Members.sol
python3.5 compile.py ../contracts/Dao1901Votes.sol

Three files are created (one per contracts)

Then you need to do the following boilerplate stuff, either using autoSetup or manually

Auto Setup for Geth

In the geth console, load script "autoSetupForGeth.js" It will:

  • create 3 accounts if not already 3 (alias name alice, bob, carol)
  • run the miner (2 CPU)
  • load contract deployment functions
    loadScript("autoSetupForGeth.js");

then deploy contracts

var Dao1901Members = deployDao1901Members();
// when Dao1901Members is mined
var Dao1901Votes = deployDao1901Votes(Dao1901Members.address);

then serve the app

npm run start

The manual way with Geth

In the geth console

// check if accounts exists
personal.listAccounts 
// create account if no one exists
// it will set eth.coinbase automatically
personal.newAccount("");
// check eth.coinbase
eth.coinbase
// unlock your account
personal.unlockAccount(eth.accounts[0], "", 3600);

run the miner

miner.start(2)

Deploy the contracts

load the Dao1901Members deploy function and run it

loadScript("Dao1901Members.js");
var Dao1901Members = deployDao1901Members();

Wait Dao1901Members to be mined, then: same for Dao1901Votes

loadScript("Dao1901Votes.js");
var Dao1901Votes = deployDao1901Votes(Dao1901Members.address);

Wait Dao1901Votes to be mined

Type exit to quit the console

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].