[game-data-packager] 07/11: make_template: Fix pyflakes warnings
Simon McVittie
smcv at debian.org
Sun Dec 31 16:59:27 UTC 2017
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to branch master
in repository game-data-packager.
commit 65570976e0ae0eb065ea280c883d72edc1264c43
Author: Simon McVittie <smcv at debian.org>
Date: Sun Dec 31 13:00:39 2017 +0000
make_template: Fix pyflakes warnings
Signed-off-by: Simon McVittie <smcv at debian.org>
---
game_data_packager/make_template.py | 13 ++++---------
1 file changed, 4 insertions(+), 9 deletions(-)
diff --git a/game_data_packager/make_template.py b/game_data_packager/make_template.py
index fb965f0..bb176b2 100644
--- a/game_data_packager/make_template.py
+++ b/game_data_packager/make_template.py
@@ -34,7 +34,7 @@ except ImportError:
from distutils.version import LooseVersion as Version
ON_DEBIAN = False
-from .data import (FileGroup, HashedFile, PackageRelation, WantedFile)
+from .data import (HashedFile, PackageRelation, WantedFile)
from .game import (GameData, load_game, load_games)
from .gog import GOG
from .steam import parse_acf
@@ -336,18 +336,18 @@ class Template:
return self.add_hashed_file(path, hf,
out_name=out_name, lang=lang,
parent_unpacker=parent_unpacker, size=size,
- is_plain_file=is_plain_file, unpack=unpack, opened=opened)
+ is_plain_file=is_plain_file, unpack=unpack, opened=opened,
+ ignorable=ignorable)
def add_hashed_file(self, path, hf, *, out_name=None, lang=None,
parent_unpacker=None, size=None, unpack=False,
- is_plain_file=False, opened=None):
+ is_plain_file=False, opened=None, ignorable=False):
if out_name is None:
out_name = path
result = None
existing = None
match_path = '/' + path.lower()
- ignorable = False
# TODO: This resembles PackagingTask.consider_file()
# and PackagingTask.use_file()
@@ -414,9 +414,6 @@ class Template:
if ignorable:
result.ignorable = True
- if ignorable:
- result.ignorable = True
-
self.game.files[result.name] = result
for lf in result.look_for:
@@ -443,8 +440,6 @@ class Template:
else:
unpacker = automatic_unpacker(path, opened)
- ext = path.lower().split('.')[-1]
-
if result is not existing and ignorable:
result.ignorable = True
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/game-data-packager.git
More information about the Pkg-games-commits
mailing list