{"id":24256078,"url":"https://github.com/kilianpaquier/compare","last_synced_at":"2026-01-20T21:02:11.020Z","repository":{"id":271618261,"uuid":"913995049","full_name":"kilianpaquier/compare","owner":"kilianpaquier","description":"Compare files and directories with Golang internal diff library","archived":false,"fork":false,"pushed_at":"2026-01-10T20:43:40.000Z","size":143,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-11T06:16:41.565Z","etag":null,"topics":["compare-directories","compare-files","compare-text","golang","golang-library"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/kilianpaquier/compare","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kilianpaquier.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-01-08T18:39:58.000Z","updated_at":"2026-01-10T20:43:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"72cc0781-cc57-449a-9384-a639f41743f1","html_url":"https://github.com/kilianpaquier/compare","commit_stats":null,"previous_names":["kilianpaquier/compare"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/kilianpaquier/compare","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kilianpaquier%2Fcompare","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kilianpaquier%2Fcompare/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kilianpaquier%2Fcompare/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kilianpaquier%2Fcompare/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kilianpaquier","download_url":"https://codeload.github.com/kilianpaquier/compare/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kilianpaquier%2Fcompare/sbom","scorecard":{"id":1238582,"data":{"date":"2025-10-06T21:00:55Z","repo":{"name":"github.com/kilianpaquier/compare","commit":"1699614bc88cccd00c8edbca1d46bbcb258206f4"},"scorecard":{"version":"v5.3.0","commit":"c22063e786c11f9dd714d777a687ff7c4599b600"},"score":6,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/24 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#code-review"}},{"name":"Maintained","score":4,"reason":"5 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 4","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#binary-artifacts"}},{"name":"Dependency-Update-Tool","score":10,"reason":"update tool detected","details":["Info: detected update tool: Dependabot: .github/dependabot.yml:1"],"documentation":{"short":"Determines if the project uses a dependency update tool.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#dependency-update-tool"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":10,"reason":"all dependencies are pinned","details":["Info:  23 out of  23 GitHub-owned GitHubAction dependencies pinned","Info:  22 out of  22 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#pinned-dependencies"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":10,"reason":"GitHub workflow tokens follow principle of least privilege","details":["Warn: jobLevel 'contents' permission set to 'write': .github/workflows/dependency-submission.yml:38","Info: jobLevel 'actions' permission set to 'read': .github/workflows/deployment.yml:30","Info: found token with 'none' permissions: .github/workflows/deployment.yml:77","Warn: jobLevel 'contents' permission set to 'write': .github/workflows/deployment.yml:74","Info: found token with 'none' permissions: .github/workflows/deployment.yml:133","Warn: jobLevel 'contents' permission set to 'write': .github/workflows/deployment.yml:130","Info: jobLevel 'pull-requests' permission set to 'read': .github/workflows/integration.yml:43","Info: jobLevel 'pull-requests' permission set to 'read': .github/workflows/integration.yml:114","Warn: jobLevel 'actions' permission set to 'write': .github/workflows/integration.yml:219","Info: jobLevel 'issues' permission set to 'read': .github/workflows/scorecard.yml:34","Info: jobLevel 'pull-requests' permission set to 'read': .github/workflows/scorecard.yml:35","Info: jobLevel 'actions' permission set to 'read': .github/workflows/scorecard.yml:30","Info: jobLevel 'checks' permission set to 'read': .github/workflows/scorecard.yml:31","Info: jobLevel 'contents' permission set to 'read': .github/workflows/scorecard.yml:32","Info: topLevel 'contents' permission set to 'read': .github/workflows/codeql.yml:32","Info: topLevel 'contents' permission set to 'read': .github/workflows/dependency-review.yml:15","Info: topLevel 'contents' permission set to 'read': .github/workflows/dependency-submission.yml:31","Info: topLevel 'contents' permission set to 'read': .github/workflows/deployment.yml:23","Info: topLevel 'contents' permission set to 'read': .github/workflows/integration.yml:33","Info: topLevel 'contents' permission set to 'read': .github/workflows/scorecard.yml:22"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#token-permissions"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#security-policy"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#fuzzing"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact v1.1.0 not signed: https://api.github.com/repos/kilianpaquier/compare/releases/221917364","Warn: release artifact v1.0.3 not signed: https://api.github.com/repos/kilianpaquier/compare/releases/211358856","Warn: release artifact v1.0.2 not signed: https://api.github.com/repos/kilianpaquier/compare/releases/202124130","Warn: release artifact v1.0.1 not signed: https://api.github.com/repos/kilianpaquier/compare/releases/200587566","Warn: release artifact v1.0.0 not signed: https://api.github.com/repos/kilianpaquier/compare/releases/193963854","Warn: release artifact v1.1.0 does not have provenance: https://api.github.com/repos/kilianpaquier/compare/releases/221917364","Warn: release artifact v1.0.3 does not have provenance: https://api.github.com/repos/kilianpaquier/compare/releases/211358856","Warn: release artifact v1.0.2 does not have provenance: https://api.github.com/repos/kilianpaquier/compare/releases/202124130","Warn: release artifact v1.0.1 does not have provenance: https://api.github.com/repos/kilianpaquier/compare/releases/200587566","Warn: release artifact v1.0.0 does not have provenance: https://api.github.com/repos/kilianpaquier/compare/releases/193963854"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#signed-releases"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#license"}},{"name":"Branch-Protection","score":3,"reason":"branch protection is not maximal on development and all release branches","details":["Info: 'allow deletion' disabled on branch 'main'","Info: 'force pushes' disabled on branch 'main'","Info: 'branch protection settings apply to administrators' is required to merge on branch 'main'","Warn: could not determine whether codeowners review is allowed","Warn: no status checks found to merge onto branch 'main'","Warn: PRs are not required to make changes on branch 'main'; or we don't have data to detect it.If you think it might be the latter, make sure to run Scorecard with a PAT or use Repo Rules (that are always public) instead of Branch Protection settings"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#branch-protection"}},{"name":"SAST","score":9,"reason":"SAST tool detected but not run on all commits","details":["Info: SAST configuration detected: CodeQL","Warn: 3 commits out of 4 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#sast"}},{"name":"Contributors","score":3,"reason":"project has 1 contributing companies or organizations -- score normalized to 3","details":["Info: found contributions from: semantic-release"],"documentation":{"short":"Determines if the project has a set of contributors from multiple organizations (e.g., companies).","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#contributors"}},{"name":"CI-Tests","score":10,"reason":"4 out of 4 merged PRs checked by a CI test -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project runs tests before pull requests are merged.","url":"https://github.com/ossf/scorecard/blob/c22063e786c11f9dd714d777a687ff7c4599b600/docs/checks.md#ci-tests"}}]},"last_synced_at":"2025-10-06T23:10:01.216Z","repository_id":271618261,"created_at":"2025-10-06T23:10:01.216Z","updated_at":"2025-10-06T23:10:01.216Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28613659,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T18:56:40.769Z","status":"ssl_error","status_checked_at":"2026-01-20T18:54:26.653Z","response_time":117,"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":["compare-directories","compare-files","compare-text","golang","golang-library"],"created_at":"2025-01-15T04:46:51.994Z","updated_at":"2026-01-20T21:02:11.016Z","avatar_url":"https://github.com/kilianpaquier.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# compare \u003c!-- omit in toc --\u003e\n\n\u003cdiv align=\"center\"\u003e\n  \u003cimg alt=\"GitLab Release\" src=\"https://img.shields.io/gitlab/v/release/kilianpaquier%2Fcompare?gitlab_url=https%3A%2F%2Fgitlab.com\u0026include_prereleases\u0026sort=semver\u0026style=for-the-badge\"\u003e\n  \u003cimg alt=\"GitLab Issues\" src=\"https://img.shields.io/gitlab/issues/open/kilianpaquier%2Fcompare?gitlab_url=https%3A%2F%2Fgitlab.com\u0026style=for-the-badge\"\u003e\n  \u003cimg alt=\"GitLab License\" src=\"https://img.shields.io/gitlab/license/kilianpaquier%2Fcompare?gitlab_url=https%3A%2F%2Fgitlab.com\u0026style=for-the-badge\"\u003e\n  \u003cimg alt=\"GitLab CICD\" src=\"https://img.shields.io/gitlab/pipeline-status/kilianpaquier%2Fcompare?gitlab_url=https%3A%2F%2Fgitlab.com\u0026branch=main\u0026style=for-the-badge\"\u003e\n  \u003cimg alt=\"Go Version\" src=\"https://img.shields.io/gitlab/go-mod/go-version/kilianpaquier/compare?style=for-the-badge\"\u003e\n  \u003cimg alt=\"Go Report Card\" src=\"https://goreportcard.com/badge/gitlab.com/kilianpaquier/compare?style=for-the-badge\"\u003e\n\u003c/div\u003e\n\n---\n\n- [How to use ?](#how-to-use-)\n- [Documentation](#documentation)\n\n## How to use ?\n\n```sh\ngo get github.com/kilianpaquier/compare\n```\n\n## Documentation\n\nCan be found here in a better format: https://pkg.go.dev/github.com/kilianpaquier/compare.\n\n```go\n/*\nPackage compare exposes two functions to compare directories and files between them.\n\nReturned errors can be easily printed to get a easy visual on diffs.\n\nAll diffs are done with Golang internal diff library: https://github.com/golang/go/blob/master/src/internal/diff/diff.go\n\nKindly exported and maintained by go-internal: https://github.com/rogpeppe/go-internal/blob/master/diff/diff.go\n\nDiffs are under the form of:\n\n\tdiff path/to/expected.txt path/to/actual.txt\n\t--- path/to/expected.txt\n\t+++ path/to/actual.txt\n\t@@ -1,1 +1,1 @@\n\t-Some text value that should be equal to the expected one.\n\t\\ No newline at end of file\n\t+Some text value that should be equal to the expected one\n\t\\ No newline at end of file\n\nExamples:\n\n\tfunc main() {\n\t\texpected := \"path/to/expected.txt\"\n\t\tactual := \"path/to/actual.txt\"\n\n\t\terr := compare.Files(expected, actual)\n\t\t// handle err\n\t}\n\n\tfunc main() {\n\t\texpected := \"path/to/expected\"\n\t\tactual := \"path/to/actual\"\n\n\t\terr := compare.Dirs(expected, actual)\n\t\t// handle err\n\t}\n\n\tfunc main() {\n\t\texpected := \"expected content (only useful on multiline contents with the desire to get a pretty diff)\"\n\t\tactual := \"actual content (only useful on multiline contents with the desire to get a pretty diff)\"\n\n\t\terr := compare.Contents(expected, actual)\n\t\t// handle err\n\t}\n*/\npackage compare\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkilianpaquier%2Fcompare","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkilianpaquier%2Fcompare","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkilianpaquier%2Fcompare/lists"}