mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-25 20:38:08 +01:00
nmbug-status: Avoid hard-coded filename in error message
We already have a 'filename' variable with the name, so stay DRY and
use that variable here.
Also fix a missing-whitespace error from bed8b674
(nmbug-status:
Clarify errors for illegible configs, 2014-05-10), wrapping on the
sentence to match similar error-generation earlier in this function.
This commit is contained in:
parent
570c0aeb40
commit
a07cafae00
1 changed files with 3 additions and 3 deletions
|
@ -109,9 +109,9 @@ def read_config(path=None, encoding=None):
|
||||||
status = p.wait()
|
status = p.wait()
|
||||||
if status != 0:
|
if status != 0:
|
||||||
raise ConfigError(
|
raise ConfigError(
|
||||||
("Missing status-config.json in branch '{branch}' of"
|
("Missing {filename} in branch '{branch}' of {nmbgit}. "
|
||||||
'{nmbgit}. Add the file or explicitly set --config.'
|
'Add the file or explicitly set --config.'
|
||||||
).format(branch=branch, nmbgit=nmbhome))
|
).format(filename=filename, branch=branch, nmbgit=nmbhome))
|
||||||
|
|
||||||
config_json = config_bytes.decode(encoding)
|
config_json = config_bytes.decode(encoding)
|
||||||
try:
|
try:
|
||||||
|
|
Loading…
Reference in a new issue