{"id":16700063,"url":"https://github.com/clok/ghlabels","last_synced_at":"2025-03-21T19:32:53.291Z","repository":{"id":38419718,"uuid":"357749780","full_name":"clok/ghlabels","owner":"clok","description":"Simple CLI tool to help manage labels across repos","archived":false,"fork":false,"pushed_at":"2025-03-11T14:26:28.000Z","size":73,"stargazers_count":2,"open_issues_count":12,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-11T15:39:29.079Z","etag":null,"topics":["cli","github","github-labels","go","golang","labels","sync"],"latest_commit_sha":null,"homepage":"https://clok.sh/ghlabels/","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/clok.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"github":["clok"]}},"created_at":"2021-04-14T02:33:03.000Z","updated_at":"2022-05-16T13:54:24.000Z","dependencies_parsed_at":"2023-11-09T02:24:20.681Z","dependency_job_id":"bbc33a9c-ed72-43ac-bfc2-aa1d46980a21","html_url":"https://github.com/clok/ghlabels","commit_stats":{"total_commits":51,"total_committers":3,"mean_commits":17.0,"dds":0.3529411764705882,"last_synced_commit":"15bc299f7a788904ca3a4c6a316f1e356af463e9"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clok%2Fghlabels","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clok%2Fghlabels/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clok%2Fghlabels/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clok%2Fghlabels/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/clok","download_url":"https://codeload.github.com/clok/ghlabels/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244855678,"owners_count":20521678,"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":["cli","github","github-labels","go","golang","labels","sync"],"created_at":"2024-10-12T18:09:13.344Z","updated_at":"2025-03-21T19:32:52.832Z","avatar_url":"https://github.com/clok.png","language":"Go","readme":"# ghlabels\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-brightgreen.svg)](https://github.com/clok/ghlabels/blob/master/LICENSE)\n[![Go Report Card](https://goreportcard.com/badge/clok/ghlabels)](https://goreportcard.com/report/clok/ghlabels)\n[![Coverage Status](https://coveralls.io/repos/github/clok/ghlabels/badge.svg)](https://coveralls.io/github/clok/ghlabels)\n[![go.dev reference](https://img.shields.io/badge/go.dev-reference-007d9c?logo=go\u0026logoColor=white)](https://pkg.go.dev/github.com/clok/ghlabels?tab=overview)\n\nSimple CLI tool to help manage labels across repos\n\n\u003e Please see [the docs for details on the commands.](./docs/ghlabels.md)\n\n```text\n$ bin/ghlabels \nNAME:\n   ghlabels - label sync for repos and organizations\n\nUSAGE:\n   ghlabels [global options] command [command options] [arguments...]\n\nCOMMANDS:\n   sync     sync labels - rename, sync, delete\n   config   commands for viewing or generating configuration\n   stats    prints out repository stats\n   help, h  Shows a list of commands or help for one command\n\nGLOBAL OPTIONS:\n   --help, -h     show help (default: false)\n   --version, -v  print the version (default: false)\n```\n\n- [Documentation](./docs/ghlabels.md)\n- [Configuration](#configuration)\n    - [Configuration Schema](#configuration-schema)\n- [Installation](#installation)\n    - [Homebrew](#homebrewhttpsbrewsh-for-macos-users)\n    - [curl binary](#curl-binary)\n    - [docker](#dockerhttpswwwdockercom)\n- [Wishlist](#wishlist)\n- [Development](#development)\n- [Versioning](#versioning)\n- [Authors](#authors)\n- [License](#license)\n\n## Configuration\n\nTo view the default configuration, run the `ghlabels config defaults` command.\n\n```text\n$ ghlabels config defaults\n```\n\nThe order of operations is:\n\n1. Rename\n2. Sync\n3. Delete\n\nA custom configuration file can be provided using the `--config, -c` flag. The file passed to this config option must\nuse the following structure. You do not need to have all 3 Top Level sections in the config file for the configuration\nto be valid.\n\nBy default, the `--config, -c` flag will overwrite the default configuration. You can merge the provided configuration\nwith the default using the\n`--merge-with-defaults, -m` boolean flag. This will take the default configuration and merge in the user provided\nconfiguration, with the user config taking precedence.\n\n### Configuration Schema\n\n| Top Level    | Type    | Description                                                                        | Structure                                                    |\n|-----------\t|--------\t|----------------------------------------------------------------------------------\t|-------------------------------------------------------------\t|\n| `rename`    | `List`    | List of Label names to rename `from` a given name `to` a new name.                | `{ from: \"string\", to: \"string\" }`                            |\n| `remove`    | `List`    | List of Labels to be deleted from a Repo.                                            | `string`                                                        |\n| `sync`        | `List`    | List of Label configuration that will be used to create or update a given Label.    | `{ name: \"string\", color: \"sting\", description: \"string\" }`    |\n\n## Installation\n\n### [Homebrew](https://brew.sh) (for macOS users)\n\n```\nbrew tap clok/ghlabels\nbrew install ghlabels\n```\n\n### curl binary\n\n```\n$ curl https://i.jpillora.com/clok/ghlabels! | bash\n```\n\n### [docker](https://www.docker.com/)\n\nThe compiled docker images are maintained\non [GitHub Container Registry (ghcr.io)](https://github.com/orgs/clok/packages/container/package/ghlabels). We maintain\nthe following tags:\n\n- `edge`: Image that is build from the current `HEAD` of the main line branch.\n- `latest`: Image that is built from the [latest released version](https://github.com/clok/ghlabels/releases)\n- `x.y.z` (versions): Images that are build from the tagged versions within GitHub.\n\n```bash\ndocker pull ghcr.io/clok/ghlabels\ndocker run -v \"$PWD\":/workdir ghcr.io/clok/ghlabels --version\n```\n\n## Wishlist\n\nGitHub doesn't support accessing the Organization Repository Defaults via their API\n(found here: `https://github.com/organizations/\u003cORG\u003e/settings/repository-defaults`)\n\nI would love to add commands that would allow:\n\n1. Generating a configuration based the Organization default settings.\n1. Sync the Organization defaults to Repos within it.\n1. Update the default settings based on a configuration manifest.\n\nUnfortunately, the GitHub API does not support interacting with the Organization Repository Defaults, so these items\nhave to remain on the wishlist for now. Please see\nthe [GitHub REST API Discussion thread](https://github.com/github/rest-api-description/discussions/329) that I opened to\nrequest this feature.\n\n## Development\n\n1. Fork the [clok/ghlabels](https://github.com/clok/ghlabels) repo\n1. Use `go \u003e= 1.16`\n1. Branch \u0026 Code\n1. Run linters :broom: `golangci-lint run`\n    - The project uses [golangci-lint](https://golangci-lint.run/usage/install/#local-installation)\n1. Commit with a Conventional Commit\n1. Open a PR\n\n## Versioning\n\nWe employ [git-chglog](https://github.com/git-chglog/git-chglog) to manage the [CHANGELOG.md](CHANGELOG.md). For the\nversions available, see the [tags on this repository](https://github.com/clok/ghlabels/tags).\n\n## Authors\n\n* **Derek Smith** - [@clok](https://github.com/clok)\n\nSee also the list of [contributors](https://github.com/clok/ghlabels/contributors) who participated in this project.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details","funding_links":["https://github.com/sponsors/clok"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclok%2Fghlabels","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclok%2Fghlabels","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclok%2Fghlabels/lists"}