Skip to content

Yashiru/open-huff

Repository files navigation

Open Huff

doc license coverage solidity

A library for secure Huff smart contract development. Directly inspired by OpenZeppelin contracts, this library is an implementation of the openzeppelin's concepts, written in Huff and thus much more economic in terms of gas usage.

This library is under development and you won't find all the openzeppelin designs yet.

Overview

Installation

git submodule add https://github.com/Yashiru/open-huff

Usage

Once installed, you can use the contracts in the library by importing them:

#include "@open-huff/contracts/ERC20.sol"

Security

This project is maintained by Yashiru. Open Huff Contracts is meant to provide tested and community-audited code, but please use common sense when doing anything that deals with real money! We take no responsibility for your implementation decisions and any security problems you might experience.

⚠️ No audit has been done yet. ⚠️

Contribute

Open Huff Contracts exists thanks to its contributors. There are many ways you can participate and help build high quality software. Check out the issues panel.

Requirements

The following will need to be installed in order to work on this project. Please follow the links and instructions.

  • Foundry / Foundryup
    • This will install forge, cast, and anvil
    • To get the latest of each, just run foundryup
  • Huff Compiler
    • You'll know you've done it right if you can run huffc --version and get an output like: huffc 0.3.0

Quickstart

  1. Install dependencies

Once you've cloned and entered into your repository, you need to install the necessary dependencies. In order to do so, simply run:

forge install
  1. Build & Test

To build and test your contracts with foundry, you can run:

forge build
forge test # To simply run tests
forge test -vvv # To run tests and print execution traces of failing tests

To compile your contract using Huff, you can run:

huffc ./path/to/your/contract.huff

For more information on how to use Foundry, check out the Foundry Github Repository and the foundry-huff library repository.

For mor information on how to use Huff, check out the Huff documentation and the Huff language repository.

License

Open Huff Contracts is released under the MIT License.

About

Open huff is a library for secure Huff smart contract development.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published