[Blends-commit] [SCM] games branch, master, updated. 0.11-31-g084377f

Markus Koschany apo at gambaru.de
Sat Sep 19 08:34:26 UTC 2015


The following commit has been merged in the master branch:
commit 48fe0dd61560344d188e6d85b566e3314dfb6ef3
Author: Markus Koschany <apo at gambaru.de>
Date:   Sat Sep 19 10:23:49 2015 +0200

    Add python helper scripts
    
    Three helper scripts for getting a quick overview about
    
    - how many games (binary packages) are there?
    - what games are already listed in our task files?
    - what games are new?
    
    TODO:
    Wishlist
    Merge all scripts into a single file. Create a simple command line tool.

diff --git a/debian/blacklist b/debian/blacklist
new file mode 100644
index 0000000..e21da34
--- /dev/null
+++ b/debian/blacklist
@@ -0,0 +1,556 @@
+0ad-data
+0ad-data-common
+7kaa-data
+a7xpg-data
+abe-data
+adanaxisgpl-data
+adonthell-data
+airstrike-common
+alex4-data
+alienblaster-data
+amoebax-data
+amphetamine-data
+angband-data
+angband-data
+armagetronad-common
+armagetronad-dedicated
+asc-data
+asc-music
+asylum-data
+atanks-data
+atomix-data
+attal-themes-medieval
+balazar3-2d
+balazar3-3d
+balazar3-common
+balder2d-data
+ballz-data
+berusky2-data
+berusky-data
+billard-gl-data
+biloba-data
+biniax2-data
+blinken
+blobandconquer-data
+blobby-data
+blobby-server
+blobwars-data
+blocks-of-the-undead-data
+bomber
+bomberclone-data
+boswars-data
+bovo
+brainparty-data
+briquolo-data
+btanks-data
+bumprace-data
+bygfoot-data
+bzflag
+bzflag-data
+bzflag-server
+cappuccino
+ceferino-data
+childsplay-alphabet-sounds-bg
+childsplay-alphabet-sounds-el
+childsplay-alphabet-sounds-en-gb
+childsplay-alphabet-sounds-nb
+childsplay-alphabet-sounds-ro
+childsplay-alphabet-sounds-sl
+chipw
+chocolate-common
+chocolate-doom
+chromium-bsu-data
+circuslinux-data
+colobot-common
+colobot-common
+colobot-common-sounds
+colobot-common-sounds
+colobot-common-textures
+colobot-common-textures
+connectagram-data
+cookietool
+crawl-common
+crawl-tiles
+crawl-tiles-data
+criticalmass-data
+crossfire-client-images
+crossfire-client-sounds
+crossfire-common
+crossfire-maps
+crossfire-maps-small
+crossfire-server
+crrcsim-data
+crystalspace
+csmash-data
+csmash-demosong
+cube2
+cube2-server
+cutechess
+cuyo-data
+cyphesis-cpp
+cyphesis-cpp-clients
+cyphesis-cpp-mason
+darkplaces
+darkplaces-server
+defendguin-data
+dizzy
+dolphin-emu-data
+doomsday-common
+doomsday-data
+doomsday-server
+dopewars-data
+dossizola-data
+drascula-french
+drascula-german
+drascula-italian
+drascula-music
+drascula-spanish
+dreamchess-data
+ember-media
+empire-hub
+empire-lafe
+enigma-data
+epiphany-data
+etw-data
+extremetuxracer-data
+extremetuxracer-extras
+extremetuxracer-gimp-dev
+fb-music-high
+fcmp
+fgo
+fgrun
+fillets-ng-data
+fillets-ng-data-cs
+fillets-ng-data-nl
+five-or-more
+fizmo-common
+fizmo-console
+flare
+flare-data
+flare-engine
+flightgear-data-ai
+flightgear-data-aircrafts
+flightgear-data-all
+flightgear-data-base
+flightgear-data-models
+fltk1.1-games
+foobillardplus-data
+fortunes
+fortunes-bg
+fortunes-bofh-excuses
+fortunes-br
+fortunes-cs
+fortunes-de
+fortunes-eo
+fortunes-eo-ascii
+fortunes-eo-iso3
+fortunes-es
+fortunes-es-off
+fortunes-fr
+fortunes-ga
+fortunes-it
+fortunes-it-off
+fortunes-mario
+fortunes-min
+fortunes-off
+fortunes-pl
+fortunes-ru
+fortune-zh
+four-in-a-row
+freecell-solver-bin
+freeciv-client-extras
+freeciv-client-gtk
+freeciv-client-qt
+freeciv-client-sdl
+freeciv-data
+freeciv-server
+freeciv-sound-standard
+freedink-data
+freedink-dfarc
+freedink-engine
+freedroid-data
+freedroidrpg-data
+freegish-data
+freeorion-data
+freetennis-common
+fretsonfire-game
+fretsonfire-songs-muldjord
+fretsonfire-songs-sectoid
+frozen-bubble-data
+funguloids-data
+gamine-data
+garden-of-coloured-lights-data
+gav-themes
+gearhead2-data
+gearhead-data
+gl-117-data
+glhack
+glob2-data
+glpeces-data
+gnome-breakout
+gnome-cards-data
+gnome-chess
+gnome-hearts
+gnome-klotski
+gnome-mastermind
+gnome-nibbles
+gnome-robots
+gnome-sudoku
+gnome-tetravex
+gnubg-data
+gnujump-data
+gnurobbo-data
+golly
+gpsshogi-data
+granatier
+grhino-data
+gunroar-data
+hannah-data
+hedgewars-data
+heroes-common
+heroes-data
+heroes-sound-effects
+heroes-sound-tracks
+holdingnuts-server
+holotz-castle-data
+holotz-castle-editor
+hyperrogue-music
+iagno
+infon-devel
+infon-server
+infon-viewer
+instead-data
+ioquake3
+ioquake3-server
+jigzo-data
+junior-toys
+kajongg
+kanagram
+kapman
+katomic
+kball-data
+kbattleship
+kblackbox
+kblocks
+kbounce
+kbreakout
+kcheckers
+kdegames-card-data
+kdegames-mahjongg-data
+kdiamond
+ketm-data
+kfourinline
+kgoldrunner
+khangman
+kigo
+kiki-the-nano-bot-data
+killbots
+kiriki
+kjumpingcube
+klickety
+klines
+kmahjongg
+knavalbattle
+knetwalk
+knights
+kobodeluxe-data
+kolf
+kollision
+konquest
+kpat
+kraptor-data
+kreversi
+kshisen
+ksirk
+ksnakeduel
+kspaceduel
+ksquares
+ksudoku
+ktuberling
+kubrick
+late-data
+lbreakout2-data
+lgc-pg
+lgeneral-data
+lierolibre-data
+lincity-ng-data
+liquidwar-data
+liquidwar-server
+littlewizard
+littlewizard-data
+lordsawar-data
+love
+lskat
+luola-data
+luola-levels
+luola-nostalgy
+madbomber-data
+magicor-data
+manaplus-data
+marsshooter-data
+mazeofgalious-data
+megaglest-data
+meritous-data
+micropolis-data
+minetest-data
+minetest-mod-mobf
+minetest-mod-moreblocks
+minetest-mod-moreores
+minetest-mod-pipeworks
+minetest-mod-worldedit
+minetest-server
+mirrormagic-data
+mmpong-caca
+mmpongd
+mmpong-gl-data
+monsterz-data
+moon-buggy-esd
+moon-lander-data
+mu-cade-data
+mupen64plus-audio-sdl
+mupen64plus-data
+mupen64plus-input-sdl
+mupen64plus-rsp-hle
+mupen64plus-rsp-z64
+mupen64plus-ui-console
+mupen64plus-video-arachnoid
+mupen64plus-video-glide64
+mupen64plus-video-glide64mk2
+mupen64plus-video-rice
+mupen64plus-video-z64
+nethack-common
+nethack-lisp
+netpanzer-data
+neverball-common
+neverball-data
+neverputt-data
+nexuiz-data
+nexuiz-music
+nexuiz-server
+nexuiz-textures
+nikwi-data
+njam-data
+noiz2sa-data
+ogamesim-www
+oolite-data
+oolite-data-sounds
+openarena-081-maps
+openarena-081-misc
+openarena-081-players
+openarena-081-players-mature
+openarena-081-textures
+openarena-085-data
+openarena-088-data
+openarena-data
+openarena-oacmp1
+openarena-server
+openbve-data
+opencity-data
+openclonk-data
+open-invaders-data
+openssn-data
+openttd-data
+openttd-opengfx
+openttd-openmsx
+orbital-eunuchs-sniper-data
+overgod-data
+pachi-data
+palapeli
+palapeli-data
+parsec47-data
+pax-britannica-data
+pennmush-common
+pennmush-mysql
+performous-tools
+phlipple-data
+picmi
+pinball-data
+pinball-dev
+pingus-data
+pink-pony-data
+pioneers-console
+pioneers-console-data
+pioneers-data
+pioneers-metaserver
+pioneers-meta-server
+pipenightdreams-data
+pixbros
+pixfrogger
+plee-the-bear-data
+pokerth-data
+pokerth-server
+polygen-data
+powermanga-data
+prboom-plus
+prboom-plus-game-server
+purity-ng
+purity-off
+pybik-bin
+pybridge-common
+pybridge-server
+pykaraoke
+pykaraoke-bin
+pyscrabble-common
+pyscrabble-server
+pysolfc-cardsets
+pysycache-buttons-beerabbit
+pysycache-buttons-crapaud
+pysycache-buttons-ice
+pysycache-buttons-wolf
+pysycache-click-dinosaurs
+pysycache-click-sea
+pysycache-dblclick-appleandpear
+pysycache-dblclick-butterfly
+pysycache-images
+pysycache-move-animals
+pysycache-move-food
+pysycache-move-plants
+pysycache-move-sky
+pysycache-move-sports
+pysycache-puzzle-cartoons
+pysycache-puzzle-photos
+pysycache-sounds
+python-pykaraoke
+qstat
+quadrapassel
+rafkill-data
+raincat-data
+realtimebattle-common
+redeclipse-data
+redeclipse-server
+renpy-demo
+renpy-thequestion
+ri-li-data
+rrootage-data
+salliere
+scid-data
+scid-rating-data
+scid-spell-data
+scorched3d-data
+scummvm-data
+sdl-ball-data
+searchandrescue-common
+searchandrescue-data
+shogivar-data
+simutrans-data
+simutrans-makeobj
+simutrans-pak128.britain
+simutrans-pak64
+singularity-music
+slashem-common
+slashem-gtk
+slashem-sdl
+slashem-x11
+slimevolley-data
+sm
+smc-data
+smc-music
+spring-common
+spring-javaai
+starfighter-data
+starvoyager-data
+stormbaancoureur-data
+supertransball2-data
+supertux-data
+supertuxkart-data
+swell-foop
+tagua-data
+tali
+tanglet-data
+tecnoballz-data
+teeworlds-data
+teeworlds-server
+tetrinet-server
+titanion-data
+tomatoes-data
+torcs-data
+torcs-data-cars
+torcs-data-tracks
+torus-trooper-data
+trackballs-data
+trackballs-music
+trigger-rally-data
+trophy-data
+tumiki-fighters-data
+tuxmath-data
+tuxtype-data
+tworld-data
+val-and-rick-data
+warmux-data
+warmux-servers
+warzone2100-data
+warzone2100-music
+wesnoth-1.12
+wesnoth-1.12-aoi
+wesnoth-1.12-core
+wesnoth-1.12-data
+wesnoth-1.12-did
+wesnoth-1.12-dm
+wesnoth-1.12-dw
+wesnoth-1.12-ei
+wesnoth-1.12-httt
+wesnoth-1.12-l
+wesnoth-1.12-low
+wesnoth-1.12-music
+wesnoth-1.12-nr
+wesnoth-1.12-server
+wesnoth-1.12-sof
+wesnoth-1.12-sotbe
+wesnoth-1.12-thot
+wesnoth-1.12-tools
+wesnoth-1.12-trow
+wesnoth-1.12-tsg
+wesnoth-1.12-ttb
+wesnoth-1.12-utbs
+wesnoth-1.13
+wesnoth-1.13-aoi
+wesnoth-1.13-core
+wesnoth-1.13-data
+wesnoth-1.13-did
+wesnoth-1.13-dm
+wesnoth-1.13-dw
+wesnoth-1.13-ei
+wesnoth-1.13-httt
+wesnoth-1.13-l
+wesnoth-1.13-low
+wesnoth-1.13-music
+wesnoth-1.13-nr
+wesnoth-1.13-server
+wesnoth-1.13-sof
+wesnoth-1.13-sotbe
+wesnoth-1.13-thot
+wesnoth-1.13-tools
+wesnoth-1.13-trow
+wesnoth-1.13-tsg
+wesnoth-1.13-ttb
+wesnoth-1.13-utbs
+wesnoth-core
+wesnoth-music
+widelands-data
+wing-data
+wizznic-data
+wmpuzzle
+wordwarvi-sound
+xabacus
+xblast
+xblast-tnt-images
+xblast-tnt-levels
+xblast-tnt-mini
+xblast-tnt-models
+xblast-tnt-musics
+xblast-tnt-sounds
+xbubble-data
+xjokes
+xmoto-data
+xpilot-extra
+xpilot-ng-client-sdl
+xpilot-ng-client-x11
+xpilot-ng-common
+xpilot-ng-server
+xpilot-ng-utils
+xpuzzles
+xqf
+xracer-tools
+xscreensaver-screensaver-dizzy
+xye-data
+zaz-data
diff --git a/debian/debian_games_updater.py b/debian/debian_games_updater.py
new file mode 100644
index 0000000..9be5233
--- /dev/null
+++ b/debian/debian_games_updater.py
@@ -0,0 +1,58 @@
+#!/usr/bin/python3
+# -*- coding: utf-8 -*-
+'''
+Copyright 2015, Markus Koschany <apo at gambaru.de>
+
+This program is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free Software
+Foundation; either version 2 of the License, or (at your option) any later
+version.
+
+This program is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+PARTICULAR PURPOSE. See the GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License along with
+this package; if not, write to the Free Software Foundation, Inc., 51 Franklin
+St, Fifth Floor, Boston, MA 02110-1301 USA
+'''
+
+from psycopg2 import connect
+
+ALL_GAMES = "games_all"
+
+def get_all_games():
+    query ="""
+        SELECT package
+        FROM packages
+        WHERE distribution='debian'
+        AND section='games'
+        AND release='sid'
+        AND component='main'
+        AND (architecture='amd64' OR architecture='all')
+        ORDER BY package
+    """;
+
+
+    conn = connect(
+            database='udd',
+            port=5432,
+            host='public-udd-mirror.xvm.mit.edu',
+            user='public-udd-mirror',
+            password='public-udd-mirror')
+
+    cur = conn.cursor()
+    cur.execute(query)
+    rows = cur.fetchall()
+    cur.close()
+    conn.close()
+
+    return rows
+
+def write_all_games_to_file():
+    with open(ALL_GAMES, mode="w", encoding="utf-8") as fout:
+        for row in get_all_games():
+            fout.write("%s\n" % str(row[0]))
+
+#get_all_games()
+write_all_games_to_file()
diff --git a/debian/games_new.py b/debian/games_new.py
new file mode 100644
index 0000000..d516dc0
--- /dev/null
+++ b/debian/games_new.py
@@ -0,0 +1,40 @@
+#!/usr/bin/python3
+# -*- coding: utf-8 -*-
+'''
+Copyright 2015, Markus Koschany <apo at gambaru.de>
+
+This program is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free Software
+Foundation; either version 2 of the License, or (at your option) any later
+version.
+
+This program is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+PARTICULAR PURPOSE. See the GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License along with
+this package; if not, write to the Free Software Foundation, Inc., 51 Franklin
+St, Fifth Floor, Boston, MA 02110-1301 USA
+'''
+
+NEW_GAMES = "games_new"
+ALL_GAMES = "games_all"
+CURRENT_GAMES = "games_current"
+OLD_GAMES = "games_old"
+BLACKLIST = "blacklist"
+files = (OLD_GAMES, BLACKLIST)
+
+def get_new_games():
+    with open(CURRENT_GAMES, mode="w", encoding="utf-8") as f_current:
+        for fname in files:
+            with open(fname) as fin:
+                f_current.write(fin.read())
+
+    with open(CURRENT_GAMES) as f_current:
+        s1 = set(f_current)
+
+    with open(ALL_GAMES) as f_all:
+        with open(NEW_GAMES, mode="w", encoding="utf-8") as f_new:
+            f_new.writelines(x for x in f_all if x not in s1)
+
+get_new_games()
diff --git a/debian/tasks_parser.py b/debian/tasks_parser.py
new file mode 100644
index 0000000..3820851
--- /dev/null
+++ b/debian/tasks_parser.py
@@ -0,0 +1,53 @@
+#!/usr/bin/python3
+# -*- coding: utf-8 -*-
+'''
+Copyright 2015, Markus Koschany <apo at gambaru.de>
+
+This program is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free Software
+Foundation; either version 2 of the License, or (at your option) any later
+version.
+
+This program is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+PARTICULAR PURPOSE. See the GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License along with
+this package; if not, write to the Free Software Foundation, Inc., 51 Franklin
+St, Fifth Floor, Boston, MA 02110-1301 USA
+'''
+
+import os
+
+OLD_GAMES = "games_old"
+blacklisted_tasks = ("c++-dev", "content-dev", "java-dev", "perl-dev",
+                     "python2-dev", "python3-dev")
+
+def get_current_games():
+    games = []
+    tasks_directory = os.path.abspath(
+        os.path.join(
+            os.path.dirname(__file__),
+            os.pardir,
+            'tasks'))
+    for filename in os.listdir(tasks_directory):
+        if filename in blacklisted_tasks:
+            continue
+        with open(os.path.join(tasks_directory, filename)) as f:
+            for line in f:
+                try:
+                    depends_list = line.split()
+                    if depends_list[0].startswith((
+                        "Depends:",
+                        "Suggests:")):
+                        games.append(depends_list[1])
+                except (KeyError, IndexError):
+                    pass
+
+    with open(OLD_GAMES, mode="w", encoding="utf-8") as fout:
+        for game in sorted(set(games)):
+            fout.write("%s\n" % str(game))
+
+
+
+get_current_games()

-- 
Debian Games Pure Blend



More information about the Blends-commit mailing list