mirror of
https://github.com/nvbn/thefuck.git
synced 2025-03-28 13:38:38 +00:00
The rule was in a non-working state. And the tests needed some bit of simplification. Certain degree of repetition is oftentimes a good thing.
13 lines
309 B
Python
13 lines
309 B
Python
import re
|
|
from thefuck.shells import shell
|
|
from thefuck.specific.git import git_support
|
|
|
|
|
|
@git_support
|
|
def match(command):
|
|
return bool(re.search(r"src refspec \w+ does not match any", command.output))
|
|
|
|
|
|
def get_new_command(command):
|
|
return shell.and_('git commit -m "Initial commit"', command.script)
|