Giter Club home page Giter Club logo

autofix's Introduction

Autofix

Gitpod Ready-to-Code NPM version NPM dependencies

Automatically fix all software bugs.

Examples

Automatically fix bugs in the current directory:

autofix

Preview all the commands this would run, but don't actually do anything:

autofix --dry

Autofix bugs, commit fixes into separate branches, push branches to a GitHub remote:

autofix --branches --push=myremote

Autofix bugs in a GitHub repository:

autofix https://github.com/nodejs/node

Autofix bugs in a GitHub repository, commit fixes, and automatically send pull requests (requires hub):

autofix https://github.com/nodejs/node --pull-request

Try it online

Open in Gitpod

Install

With npm do:

npm install -g autofix

Or run it directly via npx:

npx autofix

Command line options

autofix (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 troubleshooting autofix bugs)
  • --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=origin if 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
  • --circle-ci: Run this autofix weekly on CircleCI (adds a .circleci/config.yml file)

Types of bugs that can be fixed

Tier 0 (no rework needed):

  • Remove trailing whitespace (uses git, xargs and sed)
  • Update pinned pyenv tool versions in Dockerfiles (requires pyenv)
  • Update pinned nvm tool versions in Dockerfiles (requires nvm)
  • Update pinned sdkman tool versions in Dockerfiles (requires sdkman)
  • Update pinned rr versions in Dockerfiles
  • Update some pinned Go module versions in Dockerfiles
  • Update Git submodules

Tier 1 (some rework might be needed):

  • Fix typos & spelling mistakes (requires codespell)

Tier 2 (experimental, use with caution):

Tier 3 (you probably don't want to run these):

  • TODO

autofix's People

Contributors

dependabot[bot] avatar jankeromnes avatar renovate-bot avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.