Why is Git Autocorrect too fast for Formula One drivers?

The author shares a surprising Git functionality where mistyped commands are autocorrected after a 0.1-second delay, suggested by the Git maintainer 17 years ago. Initially, unknown commands would prompt an error message, until a patch in 2008 introduced the autocorrect feature, later configurable via help.autocorrect. The setting can now be adjusted to immediately run the suggested command, prompt for confirmation, or never show any suggestions. The autocorrect mechanism uses a modified Levenshtein distance algorithm for string similarity. The author presents a potential fix to interpret a boolean string value, like “1” or “true”, as “immediately” rather than a 0.1-second delay, aiming to improve future versions of Git.

https://blog.gitbutler.com/why-is-git-autocorrect-too-fast-for-formula-one-drivers/

To top