{"id":28395198,"url":"https://github.com/databiosphere/sync-github-labels","last_synced_at":"2025-06-27T01:31:10.798Z","repository":{"id":39838786,"uuid":"251681858","full_name":"DataBiosphere/sync-github-labels","owner":"DataBiosphere","description":"Synchronize Github issue and PR labels between two repositories","archived":false,"fork":false,"pushed_at":"2024-11-26T22:07:43.000Z","size":21,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":5,"default_branch":"develop","last_synced_at":"2025-06-01T06:52:27.944Z","etag":null,"topics":["boardwalk"],"latest_commit_sha":null,"homepage":"","language":"Python","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/DataBiosphere.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":"2020-03-31T17:36:40.000Z","updated_at":"2024-11-26T21:38:00.000Z","dependencies_parsed_at":"2024-11-26T22:25:31.945Z","dependency_job_id":"5aca7e94-2c32-4df4-8140-c13de7cd4960","html_url":"https://github.com/DataBiosphere/sync-github-labels","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/DataBiosphere/sync-github-labels","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DataBiosphere%2Fsync-github-labels","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DataBiosphere%2Fsync-github-labels/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DataBiosphere%2Fsync-github-labels/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DataBiosphere%2Fsync-github-labels/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DataBiosphere","download_url":"https://codeload.github.com/DataBiosphere/sync-github-labels/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DataBiosphere%2Fsync-github-labels/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262172343,"owners_count":23269987,"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":["boardwalk"],"created_at":"2025-05-31T19:39:28.114Z","updated_at":"2025-06-27T01:31:10.786Z","avatar_url":"https://github.com/DataBiosphere.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Sync Github Labels\n\nThis script will synchronize labels idempotently between two Github repositories.\n\n## Before You Begin\n\nBefore using this script, it requires the use of a Gitub API key. This can be created\nby logging into Github (using an account that has the ability to create/remove labels\nfrom the source and destination repositories), going to Settings \u003e Developer \u003e Access Tokens,\nand creating a new access token with the ability to control repositories.\n\nOnce you have the API key, set the `GITHUB_API_KEY` environment variable to the access\ntoken you created.\n\n## Basic Usage\n\nCall this script on the command line, and pass it the source and destination repo:\n\n```\n./sync_labels.py [--FLAGS] SOURCE_REPO DEST_REPO\n```\n\n## Normal Operation\n\nThe basic mode of operation is to pass the script the full name of a source repository \nand a destination repository:\n\n```\n./sync_labels.py foo/hello-world bar/hello-world\n```\n\n## `--dry-run`: Dry Run Mode\n\nTo do a dry-run of the label sync actions and see a summary of what labels would be added or deleted,\nuse the `--dry-run` or `-n` flag:\n\n```\n./sync_labels.py --dry-run foo/hello-world bar/hello-world\n./sync_labels.py -n foo/hello-world bar/hello-world\n```\n\nThis will run the script but will skip any API calls that create or delete labels.\n\n## `--delete`: Delete Mode\n\nThe default behavior of the script is to look for labels that are in the source repo and \nnot in the destination repo. Labels that are in the destination repo but not in the source repo\nare ignored.\n\nBy adding the `--delete` flag, the script will delete any label that is in the destination repo\nthat is not in the source repo.\n\n```\n./sync_labels --delete foo/hello-world bar/hello-world\n./sync_labels -d foo/hello-world bar/hello-world\n```\n\n**Warning: This operation is destructive! Make sure to use the `--dry-run` flag first.**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatabiosphere%2Fsync-github-labels","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdatabiosphere%2Fsync-github-labels","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdatabiosphere%2Fsync-github-labels/lists"}