bump version to 0.7

support relative paths
--tmdinfo no longer fails when an IOS-tmd is check
don't enforce decrypt=false on unpacking CLI
This commit is contained in:
Christopher Roy Bratusek 2013-06-17 10:00:37 +02:00
parent 138af060a3
commit e573cd1f2f
6 changed files with 103 additions and 77 deletions

View File

@ -1,3 +1,9 @@
-- 0.7 --
* cli-options now can properly handle relative paths
* --tmdinfo does now longer fail when checking an IOS
* don't enforce decrypt=false on unpacking cli
* automatic whitespace fixes
-- 0.6 --
* fixed a string in german translation
* fixed selecting file in TMD-Viewer

View File

@ -10,7 +10,7 @@ from PyQt4.QtCore import pyqtSignature
from Ui_AboutQwad import Ui_Dialog
def Version():
return "0.5"
return "0.7"
def Author():
return "Christopher Roy Bratusek <nano@tuxfamily.org>"

View File

@ -342,6 +342,18 @@ class UnpackingCLI(Thread):
print e
print "Done"
class UnpackingCLIX(Thread):
def __init__(self, wadpath, dirpath):
Thread.__init__(self)
self.wadpath = wadpath
self.dirpath = dirpath
def run(self):
try:
WAD.loadFile(self.wadpath).dumpDir(self.dirpath)
except Exception, e:
print e
print "Done"
class Packing(Unpacking):
def __init__(self, dirpath, wadpath, QMW, deletedir = False):
Unpacking.__init__(self, wadpath, dirpath, QMW)
@ -349,8 +361,8 @@ class Packing(Unpacking):
def run(self):
self.qobject.emit(SIGNAL("working"),PACKING)
try:
print self.dirpath
print self.wadpath
print self.dirpath
WAD.loadDir(self.dirpath).dumpFile(self.wadpath)
if self.deletedir:
print "Cleaning temporary files"
@ -393,6 +405,8 @@ class nusDownloading(Unpacking):
self.version = None
self.decrypt = decrypt
self.titleid = titleid
print self.titleid
print self.version
def run(self):
self.qobject.emit(SIGNAL("working"),DOWNLOADING)
try:
@ -425,7 +439,7 @@ class nusDownloadingCLI(UnpackingCLI):
try:
if self.pack:
self.dirpath = tempfile.gettempdir() + "/NUS_"+ str(time.time()).replace(".","")
NUS(self.titleid, self.version).download(self.dirpath, decrypt = False)
NUS(self.titleid, self.version).download(self.dirpath, decrypt = self.decrypt)
self.packing = PackingCLI(self.dirpath, str(self.outputdir), True)
self.packing.start()
else:
@ -446,6 +460,9 @@ def ShowTMD(tmdpath):
print "Title Version : %s" % tmd.tmd.title_version
print "Title Boot Index : %s" % tmd.tmd.boot_index
print "Title Contents : %s" % tmd.tmd.numcontents
if ("%016x" % tmd.tmd.iosversion) == "0000000000000000":
print "Title IOS : --"
else:
print "Title IOS : %s" % TitleIDs.TitleSwapDict["%s" % ("%016x" % tmd.tmd.iosversion)]
print "Title Access Rights: %s" % tmd.tmd.access_rights
print "Title Type : %s" % tmd.tmd.title_type

View File

@ -8,6 +8,11 @@ from PyQt4.QtCore import QTranslator, QString, QLocale
from GUI.VenPri import MWQwad, nusDownloadingCLI, PackingCLI, UnpackingCLI, ShowTMD
from TitleIDs import TitleDict, IOSdict, swap_dic, ChannelCLIDict, ChannelJAPDict, ChannelPALDict, ChannelUSADict, ChannelJAPVerDict, ChannelPALVerDict, ChannelUSAVerDict
if os.getenv("QWAD_X_DIR"):
os.chdir(os.getenv("QWAD_X_DIR"))
else:
os.chdir(os.getenv("HOME"))
class MultipleOption(Option):
ACTIONS = Option.ACTIONS + ("extend",)
STORE_ACTIONS = Option.STORE_ACTIONS + ("extend",)
@ -20,10 +25,9 @@ class MultipleOption(Option):
else:
Option.take_action(self, action, dest, opt, value, values, parser)
VERSION = '0.6'
VERSION = '0.7'
def opts():
os.chdir(sys.path[0])
description = """NUS-Downloader, WadManager and TMD-Viewer for Linux"""
parser = OptionParser(option_class=MultipleOption,
usage='usage: qwad [OPTIONS] ARGUMENT',
@ -165,8 +169,6 @@ def main():
# load Qt translations
qttranslator = QTranslator()
qttranslator.load(QString("qt_%1").arg(QLocale.system().name()))
# change directory in $HOME, so that file-seletors don't start in Qwads source/data directory
os.chdir(os.getenv("HOME"))
# misc stuff
Vapp = QApplication(sys.argv)
Vapp.setOrganizationName("Nanolx")

1
qwad
View File

@ -1,3 +1,4 @@
#!/bin/sh
export QWAD_X_DIR="${PWD}"
PYTHONPATH="/usr/share/Qwad/"
python /usr/share/Qwad/Qwad.pyw $@