Skip to content

Instantly share code, notes, and snippets.

@nea89o
Created June 5, 2018 12:00
Show Gist options
  • Save nea89o/69efb289a60ba7ecb9c26333ef00e766 to your computer and use it in GitHub Desktop.
Save nea89o/69efb289a60ba7ecb9c26333ef00e766 to your computer and use it in GitHub Desktop.
https://github.com/nvbn/thefuck rule for lowercasing CAPSLOCKED scripts
priority = 1200
requires_output = False
enabled_by_default = True
def match(command):
return sum([ch.isupper() for ch in command.script]) > sum([ch.islower() for ch in command.script])
def get_new_command(command):
return command.script.lower()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment