ajouter le hook double-quote-string-fixer (#79788) #5

Merged
vdeniaud merged 3 commits from wip/79788-single-quotes into main 2023-08-16 12:01:33 +02:00
3 changed files with 10 additions and 4 deletions

View File

@ -1,2 +1,4 @@
# trivial: apply black
6adea28798dc02a721624fc1e079450b6ae16954
# misc: apply double-quote-string-fixer (#79788)
91aa8a41eafe344eadd1c85df21e151da39777f9

View File

@ -1,6 +1,10 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: double-quote-string-fixer
- repo: https://github.com/asottile/pyupgrade
rev: v3.1.0
hooks:

View File

@ -72,10 +72,10 @@ def get_servers():
serversfile = config.get('config', 'servers', fallback=None)
if serversfile is None:
print(
"You need to create ~/.config/eoptasks.ini with such a content:\n"
"\n"
" [config]\n"
" servers = /home/user/src/puppet/data/servers.yaml\n"
'You need to create ~/.config/eoptasks.ini with such a content:\n'
'\n'
' [config]\n'
' servers = /home/user/src/puppet/data/servers.yaml\n'
)
sys.exit(1)
ignorelist = [x.strip() for x in config.get('config', 'ignore', fallback='').split(',')]