Automatically fix all software bugs.
Automatically fix bugs in the current directory:
autofixPreview all the commands this would run, but don't actually do anything:
autofix --dryAutofix bugs in a GitHub repository, commit fixes into separate branches, and automatically send pull requests (requires gh):
autofix --branches --pull-requestautofix (DIRECTORY|REPOSITORY) [OPTIONS]-
DIRECTORY: Run autofix in a particular directory (defaults to.). -
REPOSITORY: Clone a Git repository, then run autofix in it.
OPTIONS:
-
--dry: Simulate without actually running any fix commands -
--branches: Commit fixes of different types into different branches (e.g.autofix-codespell) -
--tiers=0,1,2: Choose which types of bugs should be autofixed (see details about tiers below) -
--verbose: Log additional information to the console (e.g. for troubleshootingautofixbugs) -
--push=REMOTE: Push fixes to a given GitHub remote (e.g. your GitHub username) -
--pull-request: Automatically open pull requests with pushed commits (requires hub, implies--push=originif unspecified) -
--branch-suffix=SUFFIX: Add a common suffix to generated branch names (i.e.autofix-codespell-SUFFIX) -
--signoff: Use Git's--signoff(or-s) feature when creating commits
Tier 0 (no rework needed):
- Remove trailing whitespace (uses
git,xargsandsed) - Applies
make fmton the coder/coder codebase. - Update version of terraform in the coder/coder codebase.
- Update Git submodules
Tier 1 (some rework might be needed):
Tier 2 (experimental, use with caution):
Tier 3 (you probably don't want to run these):
- TODO
You can also implement your own fixers (similar to the ones found in the ./fixers/ directory) and commit them to your repository under a .autofix/fixers/ directory. Autofix will automatically pick them up; run them on your codebase; and commit new fixes when relevant.