From ab6643b7759869ea39823e8264b1afbeacac4cd6 Mon Sep 17 00:00:00 2001 From: Jared Wasinger Date: Mon, 17 Feb 2025 16:34:53 -0800 Subject: [PATCH] cmd/abigen: remove regression: ensure that either --abi or --combined-json are set. --- cmd/abigen/main.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/abigen/main.go b/cmd/abigen/main.go index 5d9f5712a9..0c5bd3c7f1 100644 --- a/cmd/abigen/main.go +++ b/cmd/abigen/main.go @@ -97,6 +97,9 @@ func generate(c *cli.Context) error { if c.String(pkgFlag.Name) == "" { utils.Fatalf("No destination package specified (--pkg)") } + if c.String(abiFlag.Name) == "" && c.String(jsonFlag.Name) == "" { + utils.Fatalf("Either contract ABI source (--abi) or combined-json (--combined-json) are required") + } // If the entire solidity code was specified, build and bind based on that var ( abis []string