mirror of
https://github.com/nvbn/thefuck.git
synced 2025-02-21 20:38:54 +00:00
#394: Force history_limit
to be int
This commit is contained in:
parent
8c8abca8d5
commit
2fea0d4c60
@ -280,7 +280,8 @@ The Fuck has a few settings parameters which can be changed in `$XDG_CONFIG_HOME
|
||||
* `wait_command` – max amount of time in seconds for getting previous command output;
|
||||
* `no_colors` – disable colored output;
|
||||
* `priority` – dict with rules priorities, rule with lower `priority` will be matched first;
|
||||
* `debug` – enables debug output, by default `False`.
|
||||
* `debug` – enables debug output, by default `False`;
|
||||
* `history_limit` &ndash numeric value of how many history commands will be scanned, like `2000`;
|
||||
|
||||
Example of `settings.py`:
|
||||
|
||||
|
@ -128,6 +128,8 @@ class Settings(dict):
|
||||
return int(val)
|
||||
elif attr in ('require_confirmation', 'no_colors', 'debug'):
|
||||
return val.lower() == 'true'
|
||||
elif attr == 'history_limit':
|
||||
return int(val)
|
||||
else:
|
||||
return val
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user