We would need to wrap the cli call in the first step in our own create-dao call.
In short, the steps to reproduce the app and dependencies that are in the \template subfolder are as follows (these are also in the README):
Use the cli to generate the scaffold: npx create-next-app --example=https://github.com/henripal/create-dao/tree/main/template (replace this with the github address of the template in our own repo. parametrizable when we wrap this call in another cli)
Compile the existing contract: npx hardhat compile (right now this is just a fill-in contract: template/contracts/Greeter.sol)
Deploy a local network: npx hardhat node && Deploy your contract to the local network: npx hardhat run scripts/sample-script.js --network localhost Note the address of the contract.
Change the greeterAddress in pages/index.js to the one your contract was deployed to in 5. above.
Start your app: npm run dev
With this template in place, to get to create-dao we would need to:
Wrap the cli call in 1. above in our own cli
Change the /template folder to the template for the DAO we want (including the contracts subfolderr)
This is to make concrete @with-heart proposal in Issue #3
steps I followed to create this:
next
app withcreate-next-app
in atemplate
subfolderhardhat
,waffle
,etherjs
)README
to get a basic app running using this template +create-next-app
as suggested by @with-heart.Note that steps 2. and 3. are only slight modifications from @dabit3's setup here: https://github.com/dabit3/full-stack-ethereum and are just intended to serve as placeholders.
proposed usage
We would need to wrap the cli call in the first step in our own
create-dao
call. In short, the steps to reproduce the app and dependencies that are in the\template
subfolder are as follows (these are also in theREADME
):npx create-next-app --example=https://github.com/henripal/create-dao/tree/main/template
(replace this with the github address of the template in our own repo. parametrizable when we wrap this call in another cli)npx hardhat compile
(right now this is just a fill-in contract:template/contracts/Greeter.sol
)npx hardhat node
&& Deploy your contract to the local network:npx hardhat run scripts/sample-script.js --network localhost
Note the address of the contract.greeterAddress
inpages/index.js
to the one your contract was deployed to in 5. above.npm run dev
With this template in place, to get to
create-dao
we would need to:contracts
subfolderr)