{"id":23340158,"url":"https://github.com/sierrasoftworks/blmain","last_synced_at":"2025-10-18T04:26:46.521Z","repository":{"id":37890109,"uuid":"272048874","full_name":"SierraSoftworks/blmain","owner":"SierraSoftworks","description":"Migrate your GitHub repositories to use a \"main\" branch instead of \"master\" (supports Azure DevOps and Travis CI)","archived":false,"fork":false,"pushed_at":"2025-04-09T00:16:05.000Z","size":259,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-09T01:23:25.159Z","etag":null,"topics":["black-lives-matter","github","hacktoberfest","migration"],"latest_commit_sha":null,"homepage":"","language":"C#","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/SierraSoftworks.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-06-13T16:49:33.000Z","updated_at":"2025-04-09T00:14:28.000Z","dependencies_parsed_at":"2023-09-25T03:58:56.790Z","dependency_job_id":"15086189-150e-49a1-99c5-2fe1cd945716","html_url":"https://github.com/SierraSoftworks/blmain","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SierraSoftworks%2Fblmain","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SierraSoftworks%2Fblmain/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SierraSoftworks%2Fblmain/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SierraSoftworks%2Fblmain/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SierraSoftworks","download_url":"https://codeload.github.com/SierraSoftworks/blmain/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248131470,"owners_count":21052819,"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":["black-lives-matter","github","hacktoberfest","migration"],"created_at":"2024-12-21T04:19:47.878Z","updated_at":"2025-10-18T04:26:46.457Z","avatar_url":"https://github.com/SierraSoftworks.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BLMain\n**Rename your `master` branch to `main` across your GitHub repositories**\n\nAs a society and as an industry, we're currently being asked an important question:\n**What will we do to stand against systemic injustice?**\nThe answers to that question will rarely be easy or simple and many of them will require us to\nstep away from the technology we build our careers upon and instead work with people. Most of\nthese challenges cannot be solved by writing code, but in some small cases we can still help.\n\nThis tool is designed to make the process of migrating your GitHub repositories to a `main` branch\nsimple, straightforward and (relatively) painless. My intent is that, by providing this tool,\nwe can all spend a bit more time working on the hard problems and less on the small ones.\n\n## Usage\nBy default the application runs in a read-only mode, printing out the steps it would take on each repository but not\nactually making these changes. When you are happy with the changes that will be applied, you can supply the `--apply true`\ncommand line parameter to make them.\n\n**NOTE** You'll need a [Personal Access Token](https://github.com/settings/tokens/new) if you wish to make\nchanges to your repositories. When generating one, please ensure that you grant access to the `repo` scope.\n\nThe easiest way to run this tool is using `docker run --rm -it sierrasoftworks/blmain $OPTS`, however\nyou can also build it using `dotnet publish -o ./out` if you've got the .NET Core 3.1 SDK installed.\n\n#### For a User\nIf you're running this against your own GitHub account, you can specify your account\nname with `--user $YOUR_USERNAME`.\n\n```bash\nblmain --token $YOUR_ACCESS_TOKEN --user $YOUR_USERNAME --apply true\n```\n\n#### For an Organization\n```bash\nblmain --token $YOUR_ACCESS_TOKEN --org $YOUR_ORG --apply true\n```\n\n#### For a Specific set of Repositories\nYou can limit the repositories that this tool runs against by providing a regex `--filter`\nparameter. This will apply against the repository name.\n\n```bash\nblmain --token $YOUR_ACCESS_TOKEN --org $YOUR_ORG --apply true --filter \"^prefix-\"\n```\n\n#### Include Forks\nBy default this tool will not make changes to forks of repositories, with the expectation that\nthe upstream repository will need to make these changes. If you'd prefer to make these changes\nanyway, you can do so by passing `--update-forks true`.\n\n```bash\nblmain --token $YOUR_ACCESS_TOKEN --user $YOUR_USERNAME --apply true --update-forks true\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsierrasoftworks%2Fblmain","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsierrasoftworks%2Fblmain","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsierrasoftworks%2Fblmain/lists"}