mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-09 22:34:17 +00:00
Merge branch 'git-config-parsing' into 'master'
Fix git config parsing Because the `git config --get --bool <option>` external command adds an extraneous newline for readability purposes, that character need to be stripped for proper parsing. *Related to:* #170 See merge request !75
This commit is contained in:
commit
9cbb31b463
1 changed files with 1 additions and 1 deletions
|
|
@ -181,7 +181,7 @@ def piped_process(command):
|
||||||
def git_config_for(parameter):
|
def git_config_for(parameter):
|
||||||
config = piped_process(['git', 'config', '--get', '--bool', parameter])
|
config = piped_process(['git', 'config', '--get', '--bool', parameter])
|
||||||
(stdout, _) = config.communicate()
|
(stdout, _) = config.communicate()
|
||||||
return to_text(stdout)
|
return to_text(stdout).strip()
|
||||||
|
|
||||||
|
|
||||||
def config_for(parameter):
|
def config_for(parameter):
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue