diff --git a/tests/test_touch.py b/tests/rules/test_touch.py similarity index 100% rename from tests/test_touch.py rename to tests/rules/test_touch.py diff --git a/thefuck/rules/touch.py b/thefuck/rules/touch.py index bede8130..07bbbc8d 100644 --- a/thefuck/rules/touch.py +++ b/thefuck/rules/touch.py @@ -1,6 +1,6 @@ import re +from thefuck import shells from thefuck.utils import for_app -from thefuck.shells import and_ @for_app('touch') @@ -10,4 +10,4 @@ def match(command): def get_new_command(command): path = re.findall(r"touch: cannot touch '(.+)/.+':", command.stderr)[0] - return and_(u'mkdir -p {}'.format(path), command.script) + return shells.and_(u'mkdir -p {}'.format(path), command.script)