Mercurial > p > roundup > code
comparison roundup/i18n.py @ 7228:07ce4e4110f5
flake8 fixes: whitespace, remove unused imports
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Sat, 18 Mar 2023 14:16:31 -0400 |
| parents | 00fe67eb8a91 |
| children | 57f34b0b912c |
comparison
equal
deleted
inserted
replaced
| 7227:1e004afe87bb | 7228:07ce4e4110f5 |
|---|---|
| 62 # __file__ should be something like: | 62 # __file__ should be something like: |
| 63 # /usr/local/lib/python3.10/site-packages/roundup/i18n.py | 63 # /usr/local/lib/python3.10/site-packages/roundup/i18n.py |
| 64 # os.prefix should be /usr, /usr/local or root of virtualenv | 64 # os.prefix should be /usr, /usr/local or root of virtualenv |
| 65 # strip leading / to make os.path.join work right. | 65 # strip leading / to make os.path.join work right. |
| 66 path = __file__ | 66 path = __file__ |
| 67 for N in 1, 2: | 67 for _N in 1, 2: |
| 68 path = os.path.dirname(path) | 68 path = os.path.dirname(path) |
| 69 # path is /usr/local/lib/python3.10/site-packages | 69 # path is /usr/local/lib/python3.10/site-packages |
| 70 _ldir = os.path.join(path, sys.prefix[1:], 'share', 'locale') | 70 _ldir = os.path.join(path, sys.prefix[1:], 'share', 'locale') |
| 71 if os.path.isdir(_ldir): | 71 if os.path.isdir(_ldir): |
| 72 LOCALE_DIRS.append(_ldir) | 72 LOCALE_DIRS.append(_ldir) |
