{"id":20518620,"url":"https://github.com/ramizpolic/equl","last_synced_at":"2026-05-16T13:02:12.622Z","repository":{"id":176863829,"uuid":"659646178","full_name":"ramizpolic/equl","owner":"ramizpolic","description":"Dynamic and performant rule-based object equality comparator","archived":false,"fork":false,"pushed_at":"2023-07-14T13:56:16.000Z","size":35,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-02T12:25:16.650Z","etag":null,"topics":["checker","comparator","equality","go","kubernetes"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ramizpolic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-06-28T09:06:22.000Z","updated_at":"2025-08-27T12:34:36.000Z","dependencies_parsed_at":"2025-01-16T10:10:46.500Z","dependency_job_id":"138b1086-068a-491d-a90d-42342d8d0bab","html_url":"https://github.com/ramizpolic/equl","commit_stats":null,"previous_names":["ramizpolic/map-differ"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ramizpolic/equl","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ramizpolic%2Fequl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ramizpolic%2Fequl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ramizpolic%2Fequl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ramizpolic%2Fequl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ramizpolic","download_url":"https://codeload.github.com/ramizpolic/equl/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ramizpolic%2Fequl/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33103970,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-16T04:41:52.686Z","status":"ssl_error","status_checked_at":"2026-05-16T04:41:52.009Z","response_time":115,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["checker","comparator","equality","go","kubernetes"],"created_at":"2024-11-15T21:45:23.205Z","updated_at":"2026-05-16T13:02:12.601Z","avatar_url":"https://github.com/ramizpolic.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# equl\nequl is a dynamic and performant rule-based object equality comparator best suited for checks of mutating objects often\nfound in Kubernetes environments.\n\n## Usage\n```go\npackage main\n\nimport (\n\t\"github.com/ramizpolic/equl\"\n\t\"strings\"\n)\n\ntype Parent struct {\n\tName  string\n\tChild string\n}\n\ntype Object struct {\n\tBase   int\n\tParent Parent\n}\n\nfunc main() {\n\tobjA := Object{\n\t\tBase:   1,\n\t\tParent: Parent{Name: \"same\", Child: \"diff-A\"},\n\t}\n\tobjB := Object{\n\t\tBase:   1,\n\t\tParent: Parent{Name: \"same\", Child: \"diff-B\"},\n\t}\n\n\t// By default, all fields between objects will be compared\n\t//\n\tresult, _ := equl.Diff(objA, objB)\n\tresult.Equal() // False\n\tresult.Diffs() // map[.Parent.Child:[diff-A diff-B]]\n\n\t// Fields specified using WithFields will be compared, including all their children\n\t//\n\tresult, _ = equl.Diff(objA, objB, equl.WithFields(\".Base\", \".Parent\"))\n\tresult.Equal() // False\n\tresult.Diffs() // map[.Parent.Child:[diff-A diff-B]]\n\n\t// Fields specified using WithoutFields will be ignored, including all their children\n\t//\n\tresult, _ = equl.Diff(objA, objB, equl.WithoutFields(\".Parent.Child\"))\n\tresult.Equal() // True\n\n\t// Specifying both WithFields and WithoutFields allows to create dynamic rule-based comparisons,\n\t// for example: compare the whole .Base and .Parent structs, but ignore everything in .Parent.Child\n\t//\n\tresult, _ = equl.Diff(objA, objB, equl.WithFields(\".Base\", \".Parent\"), equl.WithoutFields(\".Parent.Child\"))\n\tresult.Equal() // True\n\n\t// It is also possible to specify a custom field fitler function to decide which fields should be\n\t// compared and which ones ignored.\n\t//\n\tresult, _ = equl.Diff(objA, objB, equl.WithFieldFilter(func(key string) bool {\n\t\treturn strings.HasPrefix(key, \".Parent\") // Anything that starts with .Parent\n\t}))\n\tresult.Equal() // False\n\tresult.Diffs() // map[.Parent.Child:[diff-A diff-B]]\n\n\t// Equal dynamically compares if two objects are equal. This is faster that Diff\n\t// since it does not need to calculate difference map. Same rules apply.\n\t//\n\tequal, _ := equl.Equal(objA, objB)                                      // False\n\tequal, _ := equl.Equal(objA, objB, equl.WithoutFields(\".Parent.Child\")) // True\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Framizpolic%2Fequl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Framizpolic%2Fequl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Framizpolic%2Fequl/lists"}