{"id":13759896,"url":"https://github.com/smartcontractkit/huff-starter-kit","last_synced_at":"2025-04-30T18:46:11.877Z","repository":{"id":52481731,"uuid":"520985211","full_name":"smartcontractkit/huff-starter-kit","owner":"smartcontractkit","description":"A template repo to work with huff smart contracts and learn about low level EVM opcodes. Also Horse ♘. ","archived":false,"fork":false,"pushed_at":"2023-02-12T07:24:26.000Z","size":94,"stargazers_count":103,"open_issues_count":1,"forks_count":14,"subscribers_count":9,"default_branch":"main","last_synced_at":"2025-04-19T08:10:31.079Z","etag":null,"topics":["chainlink","ethereum","evm","foundry","huff","smartcontracts"],"latest_commit_sha":null,"homepage":"","language":"Solidity","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/smartcontractkit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2022-08-03T18:08:23.000Z","updated_at":"2025-03-12T02:21:35.000Z","dependencies_parsed_at":"2024-01-17T16:58:15.939Z","dependency_job_id":"6d2cd51c-8c78-4f96-8cce-82b451a984fd","html_url":"https://github.com/smartcontractkit/huff-starter-kit","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartcontractkit%2Fhuff-starter-kit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartcontractkit%2Fhuff-starter-kit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartcontractkit%2Fhuff-starter-kit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smartcontractkit%2Fhuff-starter-kit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/smartcontractkit","download_url":"https://codeload.github.com/smartcontractkit/huff-starter-kit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251765298,"owners_count":21640171,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chainlink","ethereum","evm","foundry","huff","smartcontracts"],"created_at":"2024-08-03T13:01:00.615Z","updated_at":"2025-04-30T18:46:11.831Z","avatar_url":"https://github.com/smartcontractkit.png","language":"Solidity","funding_links":[],"categories":["dApps directory"],"sub_categories":["Smart Contract Tools"],"readme":"\u003cbr/\u003e\n\u003cp align=\"center\"\u003e\n\u003ca href=\"https://chain.link\" target=\"_blank\"\u003e\n\u003cimg src=\"./img/chainlink-huff.png\" width=\"225\" alt=\"Chainlink Huff logo\"\u003e\n\u003c/a\u003e\n\u003c/p\u003e\n\u003cbr/\u003e\n\nA template repository for building a huff based smart contract project with Foundry.\n\nFor more information on using foundry with solidity, check out the [foundry-starter-kit](https://github.com/smartcontractkit/foundry-starter-kit)\n\nImplementation of the following 2 Chainlink features using the [Foundry](https://book.getfoundry.sh/getting-started/installation.html) \u0026 [Huff](https://huff.sh/) development environment:\n\n- [Chainlink Price Feeds](https://docs.chain.link/docs/using-chainlink-reference-contracts)\n- [Chainlink Keepers](https://docs.chain.link/docs/chainlink-keepers/introduction/)\n\n# Table Of Contents\n\n- [Table Of Contents](#table-of-contents)\n- [Getting Started](#getting-started)\n  - [Requirements](#requirements)\n  - [Quickstart](#quickstart)\n  - [Testing](#testing)\n- [Usage](#usage)\n  - [Deploying to a local network](#deploying-to-a-local-network)\n  - [Deploying to a testnet or mainnet network](#deploying-to-a-testnet-or-mainnet-network)\n    - [Setup](#setup)\n    - [Deploying](#deploying)\n- [Misc](#misc)\n  - [Disclaimer](#disclaimer)\n  - [Acknowledgments](#acknowledgments)\n  - [Contributing](#contributing)\n  - [Resources](#resources)\n  - [Helpful Debugging Resources:](#helpful-debugging-resources)\n\n# Getting Started\n\n## Requirements\n\nPlease install the following:\n\n- [Git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git)\n  - You'll know you've done it right if you can run `git --version`\n- [Foundry / Foundryup](https://github.com/gakonst/foundry)\n  - This will install `forge`, `cast`, and `anvil`\n  - You can test you've installed them right by running `forge --version` and get an output like: `forge 0.2.0 (f016135 2022-07-04T00:15:02.930499Z)`\n  - To get the latest of each, just run `foundryup`\n- [Huff Compiler](https://docs.huff.sh/get-started/installing/)\n  - You'll know you've done it right if you can run `huffc --version` and get an output like: `huffc 0.2.0`\n\n## Quickstart\n\n```sh\ngit clone https://github.com/smartcontractkit/huff-starter-kit\ncd huff-starter-kit\nmake # This installs the project's dependencies.\nmake test\n```\n\n## Testing\n\n```\nmake test\n```\n\nor\n\n```\nforge test\n```\n\n# Usage\n\nDeploying to a network uses the [foundry scripting system](https://book.getfoundry.sh/tutorials/solidity-scripting.html), where you write your deploy scripts in solidity!\n\n## Deploying to a local network\n\nFoundry comes with local network [anvil](https://book.getfoundry.sh/anvil/index.html) baked in, and allows us to deploy to our local network for quick testing locally.\n\nTo start a local network run:\n\n```\nmake anvil\n```\n\nThis will spin up a local blockchain with a determined private key, so you can use the same private key each time.\n\nThen, you can deploy it with:\n\n```\nmake deploy-anvil contract=\u003cCONTRACT_NAME\u003e\n```\n\n## Deploying to a testnet or mainnet network\n\n### Setup\n\nWe'll demo using the Sepolia testnet. (Go here for [testnet sepolia ETH](https://faucets.chain.link/).)\n\nYou'll need to add the following variables to a `.env` file:\n\n- `SEPOLIA_RPC_URL`: A URL to connect to the blockchain. You can get one for free from [Infura](https://infura.io/).\n- `PRIVATE_KEY`: A private key from your wallet. You can get a private key from a new [Metamask](https://metamask.io/) account\n  - Additionally, if you want to deploy to a testnet, you'll need test ETH and/or LINK. You can get them from [faucets.chain.link](https://faucets.chain.link/).\n- Optional `ETHERSCAN_API_KEY`: If you want to verify on etherscan.\n\n### Deploying\n\n```\nmake deploy-sepolia contract=\u003cCONTRACT_NAME\u003e\n```\n\nFor example:\n\n```\nmake deploy-sepolia contract=PriceFeedConsumer\n```\n\nThis will run the forge script, the script it's running is:\n\n```\n@forge script script/${contract}.s.sol:Deploy${contract} --rpc-url ${SEPOLIA_RPC_URL}  --private-key ${PRIVATE_KEY} --broadcast --verify --etherscan-api-key ${ETHERSCAN_API_KEY}  -vvvv\n```\n\nIf you don't have an `ETHERSCAN_API_KEY`, you can also just run:\n\n```\n@forge script script/${contract}.s.sol:Deploy${contract} --rpc-url ${SEPOLIA_RPC_URL}  --private-key ${PRIVATE_KEY} --broadcast\n```\n\nThese pull from the files in the `script` folder.\n\n# Misc\n\n## Disclaimer\n\n\u003e None of the contacts have been audited, use at your own risk.\n\n## Acknowledgments\n\n- [Huff Project Template](https://github.com/huff-language/huff-project-template/tree/main/src)\n- [Huff Examples](https://github.com/huff-language/huff-examples)\n\n## Contributing\n\nContributions are always welcome! Open a PR or an issue!\n\nThank You!\n\n## Resources\n\n- [Chainlink Documentation](https://docs.chain.link/)\n- [Foundry Documentation](https://book.getfoundry.sh/)\n- [Huff Documentation](https://docs.huff.sh/)\n\n## Helpful Debugging Resources:\n\n- [evm.codes](https://www.evm.codes/)\n- [evm.codes playground](https://www.evm.codes/playground)\n- [Huff VSCode Debugger \u0026 Highlighter](https://github.com/huff-language/vscode-huff)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmartcontractkit%2Fhuff-starter-kit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsmartcontractkit%2Fhuff-starter-kit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmartcontractkit%2Fhuff-starter-kit/lists"}