command = "rm" [[match_err]] pattern = [ "is a directory", "try --recursive" ] suggest = [ ''' {{command[0]}} -r {{command[1:]}} ''' ] [[match_err]] pattern = [ "no such file or directory", "file(s) not found" ] suggest = [ ''' {{command[0}} {{opt::(?:\s)(-[\w]+)}} {{typo[1:](file)}} ''' ]