mirror of
https://github.com/nvbn/thefuck.git
synced 2025-01-18 12:06:04 +00:00
Added rule for misspelled cd.. command
This commit is contained in:
parent
636ce7c507
commit
99e418f852
14
thefuck/rules/cd_parent.py
Normal file
14
thefuck/rules/cd_parent.py
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
# Adds the missing space between the cd command and the target directory
|
||||||
|
# when trying to cd to the parent directory.
|
||||||
|
#
|
||||||
|
# Does not really save chars, but is fun :D
|
||||||
|
#
|
||||||
|
# Example:
|
||||||
|
# > cd..
|
||||||
|
# cd..: command not found
|
||||||
|
|
||||||
|
def match(command, settings):
|
||||||
|
return command.script == 'cd..'
|
||||||
|
|
||||||
|
def get_new_command(command, settings):
|
||||||
|
return 'cd ..'
|
Loading…
Reference in New Issue
Block a user