Skip to content

Commit 17f6a76

Browse files
committed
feat: modern toolchain setup and simple RNG smart contracts
1 parent 5b9a8f1 commit 17f6a76

File tree

1,599 files changed

+62195
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,599 files changed

+62195
-0
lines changed

.depcheckrc

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
ignores: ["lint-*", "prettier-*", "eslint-*", "babel-*", "solhint-*", "@commitlint/*", "conventional-changelog-cli"]
2+
skip-missing: true

.editorconfig

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
root = true
2+
3+
[*]
4+
end_of_line = lf
5+
trim_trailing_whitespace = true
6+
insert_final_newline = true
7+
charset = utf-8
8+
9+
[*.{html,js,.json,mjs,rjson,ts}]
10+
indent_style = space
11+
indent_size = 2
12+
13+
[*.sol]
14+
indent_style = space
15+
indent_size = 4

.eslintignore

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
node_modules/
2+
**/node_modules/
3+
!**/*.js
4+
!*.js

.eslintrc.json

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"parserOptions": {
3+
"ecmaVersion": 2020
4+
},
5+
"env": {
6+
"browser": true,
7+
"es6": true,
8+
"node": true,
9+
"mocha": true,
10+
"es2020": true
11+
},
12+
"extends": [
13+
"eslint:recommended",
14+
"plugin:prettier/recommended",
15+
"plugin:import/recommended"
16+
],
17+
"plugins": [
18+
"prettier",
19+
"import"
20+
],
21+
"rules": {
22+
"no-unused-vars": [
23+
"error",
24+
{
25+
"varsIgnorePattern": "(^_+[0-9]*$)|([iI]gnored$)|(^ignored)",
26+
"argsIgnorePattern": "(^_+[0-9]*$)|([iI]gnored$)|(^ignored)"
27+
}
28+
],
29+
"prettier/prettier": "error",
30+
"import/no-unresolved": [
31+
"error",
32+
{
33+
"commonjs": true
34+
}
35+
]
36+
}
37+
}

.gitattributes

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.sol linguist-language=Solidity

.gitignore

+190
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,190 @@
1+
# Created by https://www.toptal.com/developers/gitignore/api/vim,node,visualstudiocode,yarn
2+
# Edit at https://www.toptal.com/developers/gitignore?templates=vim,node,visualstudiocode,yarn
3+
4+
### Node ###
5+
# Logs
6+
logs
7+
*.log
8+
npm-debug.log*
9+
yarn-debug.log*
10+
yarn-error.log*
11+
lerna-debug.log*
12+
.pnpm-debug.log*
13+
14+
# Diagnostic reports (https://nodejs.org/api/report.html)
15+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
16+
17+
# Runtime data
18+
pids
19+
*.pid
20+
*.seed
21+
*.pid.lock
22+
23+
# Directory for instrumented libs generated by jscoverage/JSCover
24+
lib-cov
25+
26+
# Coverage directory used by tools like istanbul
27+
coverage
28+
*.lcov
29+
30+
# nyc test coverage
31+
.nyc_output
32+
33+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
34+
.grunt
35+
36+
# Bower dependency directory (https://bower.io/)
37+
bower_components
38+
39+
# node-waf configuration
40+
.lock-wscript
41+
42+
# Compiled binary addons (https://nodejs.org/api/addons.html)
43+
build/Release
44+
45+
# Dependency directories
46+
node_modules/
47+
jspm_packages/
48+
49+
# Snowpack dependency directory (https://snowpack.dev/)
50+
web_modules/
51+
52+
# TypeScript cache
53+
*.tsbuildinfo
54+
55+
# Optional npm cache directory
56+
.npm
57+
58+
# Optional eslint cache
59+
.eslintcache
60+
61+
# Microbundle cache
62+
.rpt2_cache/
63+
.rts2_cache_cjs/
64+
.rts2_cache_es/
65+
.rts2_cache_umd/
66+
67+
# Optional REPL history
68+
.node_repl_history
69+
70+
# Output of 'npm pack'
71+
*.tgz
72+
73+
# Yarn Integrity file
74+
.yarn-integrity
75+
76+
# dotenv environment variables file
77+
.env
78+
.env.test
79+
.env.production
80+
81+
# parcel-bundler cache (https://parceljs.org/)
82+
.cache
83+
.parcel-cache
84+
85+
# Next.js build output
86+
.next
87+
out
88+
89+
# Nuxt.js build / generate output
90+
.nuxt
91+
dist
92+
93+
# Gatsby files
94+
.cache/
95+
# Comment in the public line in if your project uses Gatsby and not Next.js
96+
# https://nextjs.org/blog/next-9-1#public-directory-support
97+
# public
98+
99+
# vuepress build output
100+
.vuepress/dist
101+
102+
# Serverless directories
103+
.serverless/
104+
105+
# FuseBox cache
106+
.fusebox/
107+
108+
# DynamoDB Local files
109+
.dynamodb/
110+
111+
# TernJS port file
112+
.tern-port
113+
114+
# Stores VSCode versions used for testing VSCode extensions
115+
.vscode-test
116+
117+
# yarn v2
118+
.yarn/cache
119+
.yarn/unplugged
120+
.yarn/build-state.yml
121+
.yarn/install-state.gz
122+
.pnp.*
123+
124+
### Node Patch ###
125+
# Serverless Webpack directories
126+
.webpack/
127+
128+
# Optional stylelint cache
129+
.stylelintcache
130+
131+
# SvelteKit build / generate output
132+
.svelte-kit
133+
134+
### Vim ###
135+
# Swap
136+
[._]*.s[a-v][a-z]
137+
!*.svg # comment out if you don't need vector files
138+
[._]*.sw[a-p]
139+
[._]s[a-rt-v][a-z]
140+
[._]ss[a-gi-z]
141+
[._]sw[a-p]
142+
143+
# Session
144+
Session.vim
145+
Sessionx.vim
146+
147+
# Temporary
148+
.netrwhist
149+
*~
150+
# Auto-generated tag files
151+
tags
152+
# Persistent undo
153+
[._]*.un~
154+
155+
### VisualStudioCode ###
156+
.vscode/*
157+
!.vscode/settings.json
158+
!.vscode/tasks.json
159+
!.vscode/launch.json
160+
!.vscode/extensions.json
161+
*.code-workspace
162+
163+
# Local History for Visual Studio Code
164+
.history/
165+
166+
### VisualStudioCode Patch ###
167+
# Ignore all local history of files
168+
.history
169+
.ionide
170+
171+
# Support for Project snippet scope
172+
!.vscode/*.code-snippets
173+
174+
### yarn ###
175+
# https://yarnpkg.com/advanced/qa#which-files-should-be-gitignored
176+
177+
.yarn/*
178+
!.yarn/releases
179+
!.yarn/plugins
180+
!.yarn/sdks
181+
!.yarn/versions
182+
183+
# if you are NOT using Zero-installs, then:
184+
# comment the following lines
185+
!.yarn/cache
186+
187+
# and uncomment the following lines
188+
# .pnp.*
189+
190+
# End of https://www.toptal.com/developers/gitignore/api/vim,node,visualstudiocode,yarn

.husky/commit-msg

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
4+
yarn commitlint --edit $1

.husky/pre-commit

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
4+
yarn lint-staged \
5+
&& yarn depcheck \
6+
&& yarn changelog \
7+
&& git add CHANGELOG.md

.lintstagedrc.json

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"*.js": "eslint --cache --fix",
3+
"*.{md,html,json}": "prettier --write",
4+
"*.sol": [
5+
"prettier --write",
6+
"solhint --fix"
7+
]
8+
}

.nvmrc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
lts/fermium

.prettierrc.json

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
{
2+
"htmlWhitespaceSensitivity": "css",
3+
"printWidth": 120,
4+
"trailingComma": "es5",
5+
"overrides": [
6+
{
7+
"files": [
8+
"*.json"
9+
],
10+
"options": {
11+
"parser": "json-stringify"
12+
}
13+
}
14+
]
15+
}

.solhint.json

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"extends": "solhint:recommended",
3+
"plugins": [
4+
"prettier"
5+
],
6+
"rules": {
7+
"prettier/prettier": "error",
8+
"max-line-length": "off",
9+
"check-send-result": "off",
10+
"not-rely-on-time": "off",
11+
"multiple-sends": "off",
12+
"compiler-version": "off",
13+
"quotes": "warn",
14+
"func-visibility": [
15+
"error",
16+
{
17+
"ignoreConstructors": true
18+
}
19+
]
20+
}
21+
}

.vscode/settings.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"solidity.compileUsingRemoteVersion": "v0.8.9+commit.e5eed63a"
3+
}
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)