[game-data-packager] 01/01: add generic support for misc shops only selling handfull of games
Alexandre Detiste
detiste-guest at moszumanska.debian.org
Thu Jul 16 08:02:14 UTC 2015
This is an automated email from the git hooks/post-receive script.
detiste-guest pushed a commit to branch master
in repository game-data-packager.
commit 903dc4a3d9db905f3470e411da17ae5b553630ca
Author: Alexandre Detiste <alexandre.detiste at gmail.com>
Date: Thu Jul 16 10:01:21 2015 +0200
add generic support for misc shops only selling handfull of games
---
data/blakestone.yaml | 2 ++
data/brokensword1.yaml | 1 +
data/duke3d.yaml | 1 +
data/elvira1.yaml | 1 +
data/elvira2.yaml | 1 +
data/noahs-ark.yaml | 1 +
data/rott.yaml | 1 +
data/simon1.yaml | 1 +
data/simon2.yaml | 1 +
data/wolf3d.yaml | 1 +
debian/changelog | 7 +++++++
game_data_packager/__init__.py | 13 ++++++++++---
tools/babel.py | 9 +++++----
13 files changed, 33 insertions(+), 7 deletions(-)
diff --git a/data/blakestone.yaml b/data/blakestone.yaml
index 89e4d8f..d2b0a6d 100644
--- a/data/blakestone.yaml
+++ b/data/blakestone.yaml
@@ -65,6 +65,7 @@ packages:
steam:
id: 358190
path: common/The Apogee Throwback Pack/Blake Stone
+ url_misc: https://3drealms.com/catalog/blake-stone_15/
install:
- audiohed.bs6
- audiot.bs6
@@ -113,6 +114,7 @@ packages:
steam:
id: 358310
path: common/The Apogee Throwback Pack/Planet Strike
+ url_misc: https://3drealms.com/catalog/planet-strike_21/
install:
- audiohed.vsi
- audiot.vsi
diff --git a/data/brokensword1.yaml b/data/brokensword1.yaml
index abb3a04..c1167b2 100644
--- a/data/brokensword1.yaml
+++ b/data/brokensword1.yaml
@@ -15,6 +15,7 @@ help_text: |
packages:
brokensword1-data:
+ url_misc: http://www.mastertronic.com/product/broken-sword-trilogy-download
install:
- compacts.clu
- general.clu
diff --git a/data/duke3d.yaml b/data/duke3d.yaml
index 19200ca..bb3b7fe 100644
--- a/data/duke3d.yaml
+++ b/data/duke3d.yaml
@@ -33,6 +33,7 @@ packages:
url: duke_nukem_3d_atomic_edition
# banner at http://eduke32.com/
pp: 6c1e671f9af5b46d9c1a52067bdf0e53685674f7
+ url_misc: https://3drealms.com/catalog/duke-nukem-3d_27/
debian:
replaces: duke3d-shareware
install:
diff --git a/data/elvira1.yaml b/data/elvira1.yaml
index 7dc6b9c..0be4d14 100644
--- a/data/elvira1.yaml
+++ b/data/elvira1.yaml
@@ -8,6 +8,7 @@ packages:
elvira1-en-data:
debian:
provides: elvira1-data
+ url_misc: http://www.adventuresoft.com/acatalog/Other_Adventure_Soft_games.html
install:
- gamepc
- icon.dat
diff --git a/data/elvira2.yaml b/data/elvira2.yaml
index 8f6b80e..008694b 100644
--- a/data/elvira2.yaml
+++ b/data/elvira2.yaml
@@ -6,6 +6,7 @@ genre: Horror
packages:
elvira2-en-data:
+ url_misc: http://www.adventuresoft.com/acatalog/Other_Adventure_Soft_games.html
debian:
provides: elvira2-data
install:
diff --git a/data/noahs-ark.yaml b/data/noahs-ark.yaml
index 3aa251c..6f83ef0 100644
--- a/data/noahs-ark.yaml
+++ b/data/noahs-ark.yaml
@@ -19,6 +19,7 @@ packages:
steam:
id: 371180
path: "common/Super 3-D Noah's Ark"
+ url_misc: http://wisdomtree.itch.io/s3dna
install:
- audiohed.n3d
- audiot.n3d
diff --git a/data/rott.yaml b/data/rott.yaml
index 6e37a50..209953b 100644
--- a/data/rott.yaml
+++ b/data/rott.yaml
@@ -37,6 +37,7 @@ packages:
url: rise_of_the_triad__dark_war
game: rise_of_the_triad__dark_war
format: deb
+ url_misc: https://3drealms.com/catalog/rise-triad-dark-war_44/
install_to: usr/share/games/rott
install:
- any_registered_rtc
diff --git a/data/simon1.yaml b/data/simon1.yaml
index a241005..7c9f069 100644
--- a/data/simon1.yaml
+++ b/data/simon1.yaml
@@ -9,6 +9,7 @@ packages:
provides: simon-the-sorcerer1-data
gog:
url: simon_the_sorcerer
+ url_misc: http://www.adventuresoft.com/acatalog/Simon_the_Sorcerer_games.html
install:
- gamepc
- icon.dat
diff --git a/data/simon2.yaml b/data/simon2.yaml
index 3f29998..36282cb 100644
--- a/data/simon2.yaml
+++ b/data/simon2.yaml
@@ -9,6 +9,7 @@ packages:
provides: simon-the-sorcerer2-data
gog:
url: simon_the_sorcerer_2
+ url_misc: http://www.adventuresoft.com/acatalog/Simon_the_Sorcerer_games.html
install:
- gsptr30
- icon.dat
diff --git a/data/wolf3d.yaml b/data/wolf3d.yaml
index 7e375f4..5300e5c 100644
--- a/data/wolf3d.yaml
+++ b/data/wolf3d.yaml
@@ -54,6 +54,7 @@ packages:
steam:
id: 2270
path: common/Wolfenstein 3D
+ url_misc: https://3drealms.com/catalog/wolfenstein-3d_25/
install_to: usr/share/games/wolf3d
install:
- audiohed.wl6
diff --git a/debian/changelog b/debian/changelog
index cf9a785..5897a58 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+game-data-packager (43) UNRELEASED; urgency=medium
+
+ [ Alexandre Detiste ]
+ * add support for extra miscellaneous shops URLs
+
+ -- Simon McVittie <smcv at debian.org> Thu, 16 Jul 2015 09:59:23 +0200
+
game-data-packager (42) unstable; urgency=medium
[ Alexandre Detiste ]
diff --git a/game_data_packager/__init__.py b/game_data_packager/__init__.py
index 54fe06b..de36de5 100644
--- a/game_data_packager/__init__.py
+++ b/game_data_packager/__init__.py
@@ -385,6 +385,7 @@ class GameDataPackage(object):
self.gog = {}
self.dotemu = {}
self.origin = {}
+ self.url_misc = None
# overide the game engine when needed
self.engine = None
@@ -558,6 +559,7 @@ class GameData(object):
self.url_steam = None
self.url_gog = None
self.url_dotemu = None
+ self.url_misc = None
self.data = data
@@ -565,7 +567,7 @@ class GameData(object):
for k in ('longname', 'copyright', 'compress_deb', 'help_text',
'engine', 'genre', 'missing_langs',
- 'steam', 'gog', 'dotemu', 'origin'):
+ 'steam', 'gog', 'dotemu', 'origin', 'url_misc'):
if k in self.data:
setattr(self, k, self.data[k])
@@ -817,6 +819,8 @@ class GameData(object):
steam_id.add(package.steam.get('id'))
dotemu_id = package.dotemu.get('id', dotemu_id)
dotemu_pp = package.dotemu.get('pp', dotemu_pp)
+ if package.url_misc:
+ self.url_misc = package.url_misc
steam_id.discard(None)
www = list()
if steam_id:
@@ -831,6 +835,8 @@ class GameData(object):
self.url_dotemu = 'http://www.dotemu.com/affiliate/%s/node/%d' % (
dotemu_pp, dotemu_id)
www.append(self.url_dotemu)
+ if self.url_misc:
+ www.append(self.url_misc)
if www:
random.shuffle(www)
self.help_text += '\nThis game can be bought online here:\n '
@@ -890,9 +896,10 @@ class GameData(object):
def _populate_package(self, package, d):
for k in ('expansion_for', 'expansion_for_ext', 'longname', 'symlinks', 'install_to',
- 'install_to_docdir', 'install_contents_of', 'steam', 'debian', 'dotemu',
+ 'install_to_docdir', 'install_contents_of', 'debian',
'rip_cd', 'architecture', 'aliases', 'better_version', 'langs',
- 'copyright', 'engine', 'gog', 'origin', 'lang', 'component', 'section'):
+ 'copyright', 'engine', 'lang', 'component', 'section',
+ 'steam', 'gog', 'dotemu', 'origin', 'url_misc'):
if k in d:
setattr(package, k, d[k])
diff --git a/tools/babel.py b/tools/babel.py
index d4c52c0..badcfa4 100755
--- a/tools/babel.py
+++ b/tools/babel.py
@@ -57,6 +57,7 @@ for name, game in load_games().items():
stats['url_steam'] = game.url_steam
stats['url_gog'] = game.url_gog
stats['url_dotemu'] = game.url_dotemu
+ stats['url_misc'] = game.url_misc
for l in game.missing_langs:
if l not in langs:
langs[l] = 0
@@ -80,7 +81,7 @@ html.write('''<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "ht
)
for lang in langs_order:
html.write(' <td><b>%s</b></td>\n' % lang)
-html.write('<td>Demo</td><td>Steam</td><td>GOG.com</td><td>DotEmu</td></tr>\n')
+html.write('<td>Demo</td><td>Steam</td><td>GOG.com</td><td>DotEmu</td><td>Misc.</td></tr>\n')
# BODY
last_genre = None
@@ -103,13 +104,13 @@ for game in games:
html.write(' <td> </td>\n')
if game['fullfree']:
- html.write(' <td colspan=4 align=center><b>freeload</b></td>\n')
+ html.write(' <td colspan=5 align=center><b>freeload</b></td>\n')
else:
if game['somefree']:
html.write(' <td align=center><b>X</b></td>\n')
else:
html.write(' <td> </td>\n')
- for url in (game['url_steam'], game['url_gog'], game['url_dotemu']):
+ for url in (game['url_steam'], game['url_gog'], game['url_dotemu'], game['url_misc']):
if url:
html.write(' <td align=center><a href="%s"><b>X</b></a></td>\n' % url)
else:
@@ -122,7 +123,7 @@ for lang in langs_order:
html.write(' <td><b>%s</b></td>\n' % langs[lang])
html.write('''
-<td colspan=4> </td>
+<td colspan=5> </td>
</tr>
</table>
<ul>
--
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