From 3f6652df66c630819dbed4bbe8212b6f419a0014 Mon Sep 17 00:00:00 2001 From: nvbn <nvbn.rm@gmail.com> Date: Mon, 27 Jul 2015 17:39:52 +0300 Subject: [PATCH] #313 Add new command options to readme --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2585d5e7..acda0ba0 100644 --- a/README.md +++ b/README.md @@ -214,8 +214,8 @@ get_new_command(command: Command, settings: Settings) -> str ``` Also the rule can contain an optional function -`side_effect(command: Command, settings: Settings) -> None` and an -optional boolean `enabled_by_default`. +`side_effect(command: Command, settings: Settings) -> None` and +optional `enabled_by_default`, `requires_output` and `priority` variables. `Command` has three attributes: `script`, `stdout` and `stderr`. @@ -239,6 +239,8 @@ def side_effect(command, settings): subprocess.call('chmod 777 .', shell=True) priority = 1000 # Lower first, default is 1000 + +requires_output = True ``` [More examples of rules](https://github.com/nvbn/thefuck/tree/master/thefuck/rules),