{"id":25015204,"url":"https://github.com/cowprotocol/ethflowcontract","last_synced_at":"2025-04-12T23:13:49.446Z","repository":{"id":56753275,"uuid":"523246028","full_name":"cowprotocol/ethflowcontract","owner":"cowprotocol","description":null,"archived":false,"fork":false,"pushed_at":"2025-02-06T18:06:12.000Z","size":7332,"stargazers_count":5,"open_issues_count":5,"forks_count":5,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-04-12T23:13:45.128Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Solidity","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cowprotocol.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":"audits/2022-12_G0-group.pdf","citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-08-10T07:33:56.000Z","updated_at":"2025-02-06T18:04:18.000Z","dependencies_parsed_at":"2024-10-24T15:19:53.071Z","dependency_job_id":"013f3fbd-1668-487e-bed4-faf1a3a1153b","html_url":"https://github.com/cowprotocol/ethflowcontract","commit_stats":null,"previous_names":[],"tags_count":23,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cowprotocol%2Fethflowcontract","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cowprotocol%2Fethflowcontract/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cowprotocol%2Fethflowcontract/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cowprotocol%2Fethflowcontract/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cowprotocol","download_url":"https://codeload.github.com/cowprotocol/ethflowcontract/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248643006,"owners_count":21138355,"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":[],"created_at":"2025-02-05T08:18:16.639Z","updated_at":"2025-04-12T23:13:49.419Z","avatar_url":"https://github.com/cowprotocol.png","language":"Solidity","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ETH flow contracts\n\nSmart contracts that enable native ETH sell orders on CoW Swap.\n\n## Deployed contracts\n\nThe ETH-flow contract has been deployed on all networks that are supported by CoW Swap (currently Ethereum mainnet, Gnosis Chain, Görli).\nThere are two deployments of the ETH-flow contract for each network: one is used in the production environment and one is used in the barn (staging/testing) environment.\nThe bytecode and parameters are the same for all contracts in the same network.\n\nYou can find deployment details by network id in `broadcast/Deploy.sol/`.\n\nWe also release all current contract addresses together with our build artifacts.\nThe addresses of the ETH-flow's latest deployments can be found [here (production)](https://github.com/cowprotocol/ethflowcontract/blob/main-artifacts/networks.prod.json) and [here (barn)](https://github.com/cowprotocol/ethflowcontract/blob/main-artifacts/networks.barn.json)\n\nYou can also retrieve the deployed contract for any tagged version.\nFor example, for version v1.0.0 you can find the contract addresses for production [here](https://github.com/cowprotocol/ethflowcontract/blob/v1.0.0-artifacts/networks.prod.json) and for barn [here](https://github.com/cowprotocol/ethflowcontract/blob/v1.0.0-artifacts/networks.barn.json).\n\n## Development\n\n### Install\n\nThis project uses Foundry for development and testing.\nInstructions on how to install this framework can be found [here](https://book.getfoundry.sh/getting-started/installation.html).\n\nOther required NPM-based dev toolings can be installed using yarn.\n\n```sh\nyarn install\n```\n\n### Build\n\n```sh\nforge build\n```\n\n#### Build artifacts\n\nBuild artifacts are automatically generated for every tagged version.\n\nA version of the code at tag `tag-name` with build artifacts included can ba found at tag `tag-name-artifacts`.\nArtifacts are stored in the folder `artifacts` in the root directory.\n\nThe tag `main-artifacts` is kept up to date with the latest working version of current main and provides up-to-date artifacts.\n\nTo manually generate the build artifacts, run:\n\n```sh\nforge build -o artifacts\n```\n\n### Deploy\n\nThe ETH flow contract has a dedicated deployment script. To simulate a deployment, run:\n\n```sh\nforge script script/Deploy.sol --rpc-url \"$RPC_URL\" -vvvv\n```\n\nYou can find a list of supported RPC URLs in `foundry.toml` under `[rpc_endpoints]`.\n\nTo broadcast the deployment onchain you must also add the private key of the deployer and the broadcast flag: `--private-key \"$PK\" --broadcast`.\n\nYou can verify a contract you deployed with the deployment script on the block explorer of the current chain with:\n\n```sh\nexport ETHERSCAN_API_KEY=\u003cyour Etherscan API key\u003e # Only needed if the default chain explorer is Etherscan\nforge script script/Deploy.sol --rpc-url \"$RPC_URL\" -vvvv --verify  \n```\n\n### Code formatting\n\n```sh\nyarn fmt\n```\n\n### Test\n\n```sh\nforge test\n```\nAdd an increased number of verbosity flags for debugging. For example:\n```sh\nforge test -vvv\n```\n\nFor seeing line coverage results, run:\n```\nforge coverage\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcowprotocol%2Fethflowcontract","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcowprotocol%2Fethflowcontract","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcowprotocol%2Fethflowcontract/lists"}