diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..fed918ad --- /dev/null +++ b/.gitignore @@ -0,0 +1,25 @@ +# Ignore all Visual Studio Code settings +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json +!.vscode/*.code-snippets + +# Local history for Visual Studio Code +.history + +# Built Visual Studio Code extensions +*.vsix + +# dotenv environment variable files +.env +.env.development.local +.env.test.local +.env.production.local +.env.local + +# Foundry files +bin +cache +out diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 00000000..f67502a8 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "lib/forge-std"] + path = lib/forge-std + url = https://github.com/foundry-rs/forge-std.git diff --git a/README.md b/README.md index 02cb9560..1af4acc5 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,3 @@ # 🐍 snekmate + State-of-the-art, highly opinionated, hyper-optimised, and secure Vyper smart contract building blocks. diff --git a/foundry.toml b/foundry.toml new file mode 100644 index 00000000..2c5d162a --- /dev/null +++ b/foundry.toml @@ -0,0 +1,12 @@ +## defaults for all profiles +[default] +src = 'src' # the source directory +test = 'test' # the test directory +out = 'out' # the output directory (for artifacts) +libs = ['lib'] # a list of library directories +remappings = ['ds-test/=lib/ds-test/src/'] # a list of remappings +cache = true # whether to cache builds or not +cache_path = 'cache' # where the cache is stored if enabled +force = true # whether to ignore the cache (clean build) +ffi = true # whether to enable foreign function interface (ffi) cheatcodes or not +verbosity = 3 # the verbosity of tests diff --git a/lib/forge-std b/lib/forge-std new file mode 160000 index 00000000..27e14b7f --- /dev/null +++ b/lib/forge-std @@ -0,0 +1 @@ +Subproject commit 27e14b7f2448e5f5ac32719f51fe652aa0b0733e diff --git a/src/SimpleStore.vy b/src/SimpleStore.vy new file mode 100644 index 00000000..34370c5f --- /dev/null +++ b/src/SimpleStore.vy @@ -0,0 +1,15 @@ + +val: uint256 + +@external +def __init__(_val: uint256): + self.val = _val + + +@external +def store(_val: uint256): + self.val = _val + +@external +def get() -> uint256: + return self.val diff --git a/test/.gitkeep b/test/.gitkeep new file mode 100644 index 00000000..e69de29b