[game-data-packager] 12/39: Add optional long name for games, and add it to all current YAML games
Simon McVittie
smcv at debian.org
Sun Jan 11 01:52:22 UTC 2015
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 e094c856372bf18759ec6eb519cebfe5563bf6d1
Author: Simon McVittie <smcv at debian.org>
Date: Sat Jan 10 18:59:33 2015 +0000
Add optional long name for games, and add it to all current YAML games
---
data/ja.yaml | 2 ++
data/jk2.yaml | 2 ++
data/quake3.yaml | 1 +
data/rott.yaml | 2 ++
data/rtcw.yaml | 2 ++
data/tyrian.yaml | 3 ++-
lib/game_data_packager/__init__.py | 8 +++++++-
7 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/data/ja.yaml b/data/ja.yaml
index 0642121..87634f0 100644
--- a/data/ja.yaml
+++ b/data/ja.yaml
@@ -1,5 +1,7 @@
%YAML 1.2
---
+shortname: ja
+longname: "Star Wars Jedi Knight: Jedi Academy"
package: jedi-academy-data
type: full
diff --git a/data/jk2.yaml b/data/jk2.yaml
index aa404ed..efb9bb2 100644
--- a/data/jk2.yaml
+++ b/data/jk2.yaml
@@ -1,5 +1,7 @@
%YAML 1.2
---
+shortname: jk2
+longname: "Star Wars Jedi Knight II: Jedi Outcast"
package: jedi-outcast-data
type: full
diff --git a/data/quake3.yaml b/data/quake3.yaml
index 0368ebc..8fd9497 100644
--- a/data/quake3.yaml
+++ b/data/quake3.yaml
@@ -1,6 +1,7 @@
%YAML 1.2
---
shortname: quake3
+longname: Quake III Arena (including Team Arena)
compress_deb: false
packages:
diff --git a/data/rott.yaml b/data/rott.yaml
index 2769f3e..0ed71ae 100644
--- a/data/rott.yaml
+++ b/data/rott.yaml
@@ -1,5 +1,7 @@
%YAML 1.2
---
+shortname: rott
+longname: Rise of the Triad
package: rott-data
install_to: usr/share/games/rott
type: demo
diff --git a/data/rtcw.yaml b/data/rtcw.yaml
index 151f908..80bb2f7 100644
--- a/data/rtcw.yaml
+++ b/data/rtcw.yaml
@@ -1,5 +1,7 @@
%YAML 1.2
---
+shortname: rtcw
+longname: Return to Castle Wolfenstein
package: rtcw-data
type: full
diff --git a/data/tyrian.yaml b/data/tyrian.yaml
index 95728d7..b0dfa00 100644
--- a/data/tyrian.yaml
+++ b/data/tyrian.yaml
@@ -1,6 +1,7 @@
%YAML 1.2
---
-#shortname: tyrian
+shortname: tyrian
+longname: Tyrian
package: tyrian-data
type: full
diff --git a/lib/game_data_packager/__init__.py b/lib/game_data_packager/__init__.py
index 194e159..b5cfedf 100644
--- a/lib/game_data_packager/__init__.py
+++ b/lib/game_data_packager/__init__.py
@@ -263,9 +263,12 @@ class GameData(object):
datadir='/usr/share/games/game-data-packager',
etcdir='/etc/game-data-packager',
workdir=None):
- # The name of the game
+ # The name of the game for command-line purposes, e.g. quake3
self.shortname = shortname
+ # The formal name of the game, e.g. Quake III Arena
+ self.longname = shortname
+
# game-data-packager's configuration directory
self.etcdir = etcdir
@@ -287,6 +290,9 @@ class GameData(object):
self.yaml = yaml.load(open(os.path.join(self.datadir,
shortname + '.yaml')))
+ if 'longname' in self.yaml:
+ self.longname = self.yaml['longname']
+
if 'package' in self.yaml:
package = GameDataPackage(self.yaml['package'])
self.packages[self.yaml['package']] = package
--
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