1
0
mirror of https://github.com/nvbn/thefuck.git synced 2025-02-23 21:39:32 +00:00
thefuck/thefuck/rules/javac.py

19 lines
357 B
Python
Raw Normal View History

"""Appends .java when compiling java files
Example:
> javac foo
error: Class names, 'foo', are only accepted if annotation
processing is explicitly requested
2015-05-27 15:38:46 +08:00
"""
from thefuck.utils import for_app
@for_app('javac')
def match(command):
return not command.script.endswith('.java')
2015-05-27 15:38:46 +08:00
def get_new_command(command):
return command.script + '.java'