Run code change campaigns to remove legacy code, fix critical security issues, and pay down tech debt. Compute changes, create branches, and track pull requests across all affected repositories.
“Google invests significant effort in maintaining code health to address some issues related to codebase complexity and dependency management. For instance, special tooling automatically detects and removes dead code, splits large refactorings, … and marks APIs as deprecated.”
“… [Google] infrastructure teams must do the work to move their internal users to new versions themselves or do the update in place, in backwards-compatible fashion. This policy, which we've called the "Churn Rule," scales better: dependent projects are no longer spending progressively greater effort to just keep up.”
“[At Facebook], analyzers participate as bots in code review, making automatic comments when an engineer submits a code modification. … [This automation] saw a 70% fix rate, where a more traditional "offline" or "batch" deployment (where bug lists are presented to engineers, outside their workflow) saw a 0% fix rate.”
You need a way to improve and change APIs used across all of your organization's code, to spend less time and effort in the migration period between the old and new API or service.
You need to be able to identify everywhere that a vulnerable package or API is used, and open issues or pull requests on all affected projects. Then you can monitor the progress of fixing, merging, and deploying.
Keep your library dependencies and how you use those libraries up to date and consistent across all of your organization's code, to avoid old bugs or security problems in old dependencies, and problems arising from inconsistent dependency version use across your codebase.
Increase adoption of linters and enable progressively stricter rules across all of your organization's code, so you can continuously improve the quality of all of your code. Developers will see diagnostics and fixes in their editor and on their code host to gently nudge them toward adherence, and you can enforce rules after a certain time period.
Keep the build and deployment configurations up to date and consistent across all of your organization's code, so that you can iterate and deploy continuously and reliably with DevOps self-sufficiency.
Sourcegraph lets you create campaigns, which compute diffs and create branches and pull requests across multiple repositories. Use it for these common types of campaigns:
When you create a campaign, Sourcegraph creates branches and pull requests as needed with the correct reviewers and context—and keeps them up to date. You can track the progress of the campaign with the burndown chart and see all related activity across all repositories. All this makes completing the campaign as fast and painless as possible.
Watch how to use Sourcegraph code change campaigns to fix code across multiple repositories.