{"id":30450176,"url":"https://github.com/nochso/bytesort","last_synced_at":"2025-08-23T13:25:40.243Z","repository":{"id":57487671,"uuid":"93239175","full_name":"nochso/bytesort","owner":"nochso","description":"Package bytesort encodes common types as binary/byte slices that are bytewise sortable.","archived":false,"fork":false,"pushed_at":"2017-09-18T19:05:10.000Z","size":19,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-13T22:29:05.300Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/nochso.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":null,"security":null,"support":null}},"created_at":"2017-06-03T09:47:16.000Z","updated_at":"2022-03-21T13:37:00.000Z","dependencies_parsed_at":"2022-08-29T13:30:07.072Z","dependency_job_id":null,"html_url":"https://github.com/nochso/bytesort","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/nochso/bytesort","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nochso%2Fbytesort","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nochso%2Fbytesort/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nochso%2Fbytesort/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nochso%2Fbytesort/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nochso","download_url":"https://codeload.github.com/nochso/bytesort/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nochso%2Fbytesort/sbom","scorecard":{"id":691697,"data":{"date":"2025-08-11","repo":{"name":"github.com/nochso/bytesort","commit":"3c6f8391bc94162223c20f640411ea315964eb7f"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-22T02:27:06.885Z","repository_id":57487671,"created_at":"2025-08-22T02:27:06.885Z","updated_at":"2025-08-22T02:27:06.885Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271749048,"owners_count":24814115,"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","status":"online","status_checked_at":"2025-08-23T02:00:09.327Z","response_time":69,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2025-08-23T13:25:37.948Z","updated_at":"2025-08-23T13:25:40.230Z","avatar_url":"https://github.com/nochso.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bytesort\n\n[![GoDoc](https://godoc.org/github.com/nochso/bytesort?status.svg)](https://godoc.org/github.com/nochso/bytesort)\n[![Build Status](https://travis-ci.org/nochso/bytesort.svg?branch=master)](https://travis-ci.org/nochso/bytesort)\n[![Coverage Status](https://coveralls.io/repos/github/nochso/bytesort/badge.svg?branch=master)](https://coveralls.io/github/nochso/bytesort?branch=master)\n[![Go Report Card](https://goreportcard.com/badge/github.com/nochso/bytesort)](https://goreportcard.com/report/github.com/nochso/bytesort)\n\nPackage bytesort encodes common Go types as binary/byte slices that are bytewise\nsortable.\n\nThe output is intended for binary/bytewise comparison and sorting.\nMore specifically for creating the keys used in indexes of key value stores.\n\n- [Install](#install)\n- [Usage](#usage)\n\t- [Output example](#output-example)\n- [Change log and versioning](#change-log-and-versioning)\n- [License](#license)\n\n## Install\n\n```sh\ngo get github.com/nochso/bytesort\n```\n\n## Usage\n\n[Full documentation is available at godoc.org](https://godoc.org/github.com/nochso/bytesort).\n\n### Output example\n\n```go\nvv := []interface{}{\n\t\"abc\",\n\tint16(math.MinInt16),\n\tint16(0),\n\tint16(math.MaxInt16),\n\tfalse,\n\ttrue,\n}\nfor _, v := range vv {\n\tb, err := bytesort.Encode(v)\n\tif err != nil {\n\t\tfmt.Println(err)\n\t\treturn\n\t}\n\tfmt.Printf(\"% 8X %-6T %#v\\n\", b, v, v)\n}\n// Output:\n// 61 62 63 string \"abc\"\n//    00 00 int16  -32768\n//    80 00 int16  0\n//    FF FF int16  32767\n//       00 bool   false\n//       01 bool   true\n```\n\nUse [bytes.Compare](https://godoc.org/bytes#Compare) and\n[sort.Slice](https://godoc.org/sort#Slice) to sort a slice of `[]byte`:\n\n```go\ninput := [][]byte{ ... }\nsort.Slice(s, func(i, j int) bool {\n\treturn bytes.Compare(s[i], s[j]) \u003c 0\n})\n```\n\nUsing [sort.Sort](https://godoc.org/sort#Sort) on structs that implement\n[sort.Interface](https://godoc.org/sort#Interface) might be faster.\n\n[sort.Search](https://godoc.org/sort#Search) might also be of interest.\n\n## Change log and versioning\n\nThis project adheres to [Semantic Versioning](http://semver.org/).\n\nSee the [CHANGELOG](CHANGELOG.md) for a full history of releases.\n\n## License\n\n[MIT](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnochso%2Fbytesort","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnochso%2Fbytesort","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnochso%2Fbytesort/lists"}