diff options
author | DjLegolas <djlegolas@protonmail.com> | 2021-12-28 21:20:57 +0100 |
---|---|---|
committer | Calum Lind <calumlind+deluge@gmail.com> | 2021-12-29 22:51:07 +0100 |
commit | ec0bcc11f510cd113bbdb6cd551b27c697f03f53 (patch) | |
tree | c60c19a61a14fa157227ad7531406f250493b78e /generate_pot.py | |
parent | [Docs] Fix spinx-contrib-spelling build error (diff) | |
download | deluge-ec0bcc11f510cd113bbdb6cd551b27c697f03f53.tar.xz deluge-ec0bcc11f510cd113bbdb6cd551b27c697f03f53.zip |
Upgrade codebase with pyupgrade (>=py3.6)
Added pyupgrade utility with manual stage to pre-commit and run on all
files.
Ref: https://github.com/asottile/pyupgrade
Closes: deluge-torrent/deluge#326
Diffstat (limited to 'generate_pot.py')
-rwxr-xr-x | generate_pot.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/generate_pot.py b/generate_pot.py index 47d3b9f99..efbdc7824 100755 --- a/generate_pot.py +++ b/generate_pot.py @@ -1,5 +1,4 @@ #!/usr/bin/env python -# -*- coding: utf-8 -*- # # Copyright (C) 2011-2013 Calum Lind <calumlind@gmail.com> # Copyright (C) 2009 Andrew Resch <andrewresch@gmail.com> @@ -89,7 +88,7 @@ with open(INFILES_LIST, 'w') as f: call(xgettext_cmd + ['--language=Python', '-j']) # Replace YEAR and PACKAGE in the copyright message -with open(POT_FILEPATH, 'r') as f: +with open(POT_FILEPATH) as f: lines = f.readlines() with open(POT_FILEPATH, 'w') as f: for line in lines: |