Skip to content

Commit 99f5d51

Browse files
committed
Initialize Project
0 parents  commit 99f5d51

File tree

8 files changed

+4465
-0
lines changed

8 files changed

+4465
-0
lines changed

.gitignore

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
node_modules
2+
.env
3+
4+
# Hardhat files
5+
/cache
6+
/artifacts
7+
8+
# TypeChain files
9+
/typechain
10+
/typechain-types
11+
12+
# solidity-coverage files
13+
/coverage
14+
/coverage.json

README.md

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Sample Hardhat Project
2+
3+
This project demonstrates a basic Hardhat use case. It comes with a sample contract, a test for that contract, and a script that deploys that contract.
4+
5+
Try running some of the following tasks:
6+
7+
```shell
8+
npx hardhat help
9+
npx hardhat test
10+
REPORT_GAS=true npx hardhat test
11+
npx hardhat node
12+
npx hardhat run scripts/deploy.js
13+
```

contracts/escrow.sol

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
// SPDX-License-Identifier: MIT
2+
pragma solidity 0.8.4;
3+
4+
contract Escrow{
5+
address public payer;
6+
address public receiver;
7+
address public arbiter;
8+
State public state;
9+
10+
enum State{Created, Locked, Released, InDispute}
11+
12+
constructor(address _receiver, address _arbiter){
13+
payer = msg.sender;
14+
receiver = _receiver;
15+
arbiter = _arbiter;
16+
state = State.Created;
17+
}
18+
}

hardhat.config.js

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
require("@nomicfoundation/hardhat-toolbox");
2+
3+
/** @type import('hardhat/config').HardhatUserConfig */
4+
module.exports = {
5+
solidity: "0.8.19",
6+
};

0 commit comments

Comments
 (0)