v 0.35 - add ArchReader & Better displaying Probing devices at starting prog
This commit is contained in:
parent
ef6fc3e80b
commit
1e11ac5754
|
@ -1,9 +1,10 @@
|
|||
GPyFSA 0.34 (2012-15-07)
|
||||
GPyFSA 0.35 (2012-07-18)
|
||||
=========================
|
||||
|
||||
New General Features
|
||||
-------------------------
|
||||
|
||||
* Better displaying probing devices
|
||||
* Add Tab Archives Infos
|
||||
* Add Archlinux Package
|
||||
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
@ -51,7 +51,7 @@ class AboutDialog(gtk.AboutDialog):
|
|||
self.set_website(conf.WEBSITE)
|
||||
self.set_website_label(conf.APPNAME)
|
||||
self.set_authors(conf.AUTHORS)
|
||||
self.set_artists(conf.ARTISTS)
|
||||
#self.set_artists(conf.ARTISTS)
|
||||
|
||||
# Show all widgets
|
||||
self.show_all()
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
@ -114,7 +114,7 @@ def file_get_contents(filename):
|
|||
# Application info
|
||||
SCALABLE_ICON = PATH_IMG+'gpyfsa.png'
|
||||
APPNAME = "GPyFSA"
|
||||
APPVERSION = "0.33"
|
||||
APPVERSION = "0.35"
|
||||
COPYRIGHTS = _("Copyright © 2010-2012 a-Sansara\n Copyright © 2010-2012 pluie.org")
|
||||
WEBSITE = "https://sourceforge.net/projects/gpyfsa/"
|
||||
AUTHORS = [
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
@ -41,6 +41,7 @@ class DevListManager():
|
|||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def evt_refreshDevicesList(self,widget=None):
|
||||
self.gpyfsa['w_treedev'].expand_all()
|
||||
self.gpyfsa.doBeforeManageDevices()
|
||||
self.gpyfsa['w_treedev'].set_model(self.getTreeStoreDevices(self.gpyfsa['w_treedev'].get_model()))
|
||||
self.gpyfsa['w_treedev'].expand_all()
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
@ -98,6 +98,71 @@ class ProbeReader():
|
|||
print "%d - %s " % (j,dlist[i][self.conf.K_DEVICE][j])
|
||||
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
class ArchReader():
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def __init__(self, conf):
|
||||
self.conf = conf
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def getContent(self, path):
|
||||
sh = self.conf.getShell()
|
||||
return sh.call([sh.CMD_FSA,"archinfo",path]).stderr.read()
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def __getListInfo(self,path):
|
||||
sh = self.conf.getShell()
|
||||
ostr = self.getContent(path)
|
||||
ostr = re.sub(r'\n\n','\n',ostr)
|
||||
return ostr.split('\n')
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def isSection(self,line):
|
||||
return line.startswith('=');
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def getValue(self,line):
|
||||
m = re.search(r'^[^:]+:[ \t]+(.*)$',line);
|
||||
if m is None : v = '';
|
||||
else :
|
||||
v = m.groups()[0]
|
||||
return v.lstrip().rstrip()
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def getListInfo(self,path):
|
||||
#lines, isMain, lmain, lsys, dic = self.__getListInfo(path), True, [], [], {}
|
||||
lines = self.__getListInfo(path)
|
||||
isMain = True
|
||||
lmain, lsys = [],[]
|
||||
for l in lines:
|
||||
if isMain:
|
||||
if self.isSection(l):
|
||||
print('---------------')
|
||||
if len(lmain)>0 :
|
||||
isMain = False
|
||||
lsys.append([])
|
||||
print('> isMain '+str(isMain))
|
||||
continue
|
||||
else:
|
||||
v = self.getValue(l)
|
||||
print('> value '+v)
|
||||
if not v.isspace():lmain.append(v);
|
||||
else:
|
||||
if self.isSection(l):
|
||||
print('---------------')
|
||||
lsys.append([])
|
||||
continue
|
||||
else:
|
||||
v = self.getValue(l)
|
||||
print('> value '+v)
|
||||
if not v.isspace() and len(lsys[len(lsys)-1])< 7 :lsys[len(lsys)-1].append(v)
|
||||
print('=====================================')
|
||||
print('lmain : '+str(lmain))
|
||||
print('lsys : '+str(lsys))
|
||||
return lmain
|
||||
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
class LogReader:
|
||||
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
@ -26,7 +26,7 @@
|
|||
# You should have received a copy of the GNU General Public License
|
||||
# along with GPyFSA. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import sys
|
||||
import sys,time,gobject
|
||||
|
||||
try:
|
||||
import pygtk
|
||||
|
@ -97,12 +97,14 @@ class GPyFSA(gtk.Window):
|
|||
self.timer = ui.setTimeout(100, ui.endSaveFS, self.cleaningSaveFS, self.checkCleaningSaveFS, self['w_progress_savefs'])
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# deprecated
|
||||
def terminateArchInfos(self):
|
||||
ui.clearTimeout(self.timer)
|
||||
self.endTime = 0
|
||||
buff = self['w_info_log'].get_buffer();
|
||||
content = conf.file_get_contents(conf.PATH_LOG)
|
||||
buff.set_text(content)
|
||||
ldev = fsa.ArchReader(conf).getListInfo(''.join(self.archivePath))
|
||||
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
|
@ -149,10 +151,7 @@ class GPyFSA(gtk.Window):
|
|||
cmd = ['fsarchiver','archinfo',path]
|
||||
if self['w_infopass'].get_active():
|
||||
cmd.append('-c'+self['w_infopass_value'].get_text())
|
||||
self.logFile.close()
|
||||
self.logFile = open(conf.PATH_LOG, 'w')
|
||||
self.pfsa = conf.getShell().call(cmd,self.logFile,False)
|
||||
self.timer = ui.setTimeout(100, ui.waitTimeout, self.terminateArchInfos, self.checkProgressAborting, (self.logReader,))
|
||||
buff.set_text(fsa.ArchReader(conf).getContent(path))
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def evt_saveFS(self,widget):
|
||||
|
@ -191,10 +190,18 @@ class GPyFSA(gtk.Window):
|
|||
return poll==0 or poll==1
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def doBeforeManageDevices(self): conf.chdir(conf.PATH_SRC)
|
||||
def doBeforeManageDevices(self):
|
||||
conf.chdir(conf.PATH_SRC)
|
||||
ui.setVisibility(self['i_refresh'],True)
|
||||
ui.setVisibility(self['l_tvcol_refresh'],True)
|
||||
ui.setVisibility(self['l_probing'],False)
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def doAfterManageDevices(self): self.setDefaultArchivePath()
|
||||
def doAfterManageDevices(self):
|
||||
self.setDefaultArchivePath()
|
||||
ui.setVisibility(self['l_probing'],True)
|
||||
ui.setVisibility(self['i_refresh'],False)
|
||||
ui.setVisibility(self['l_tvcol_refresh'],False)
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def doAfterDeviceSelection(self): self.switchStateSaveFS()
|
||||
|
@ -281,10 +288,16 @@ class GPyFSA(gtk.Window):
|
|||
# # # # < BUG FIX # # # # # # # # # # # # # # # # # # # # #
|
||||
return self.xml.get_widget(key)
|
||||
|
||||
def wait(self,data):
|
||||
self.dlm = DevListManager(self,conf)
|
||||
self.dlm.evt_refreshDevicesList(self.dlm)
|
||||
ui.clearTimeout(data.timer)
|
||||
return False
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def __init__(self):
|
||||
self.xml = conf.getGladeXML()
|
||||
self.dlm = DevListManager(self,conf)
|
||||
self.dlm = None # DevListManager(self,conf)
|
||||
self.bugFix_GladeComboBoxEntry()
|
||||
self.setCompressionStore()
|
||||
self.manageStyle()
|
||||
|
@ -296,10 +309,15 @@ class GPyFSA(gtk.Window):
|
|||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
def main():
|
||||
GPyFSA()
|
||||
gpyfsa = GPyFSA()
|
||||
gtk.window_set_default_icon_list(gtk.gdk.pixbuf_new_from_file(conf.SCALABLE_ICON))
|
||||
gpyfsa.timer = gobject.timeout_add(1000, gpyfsa.wait,gpyfsa)
|
||||
#gpyfsa.dlm.evt_refreshDevicesList(gpyfsa)
|
||||
ui.setVisibility(gpyfsa['i_refresh'],True)
|
||||
ui.setVisibility(gpyfsa['l_tvcol_refresh'],True)
|
||||
gtk.main()
|
||||
|
||||
|
||||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.32 #
|
||||
# date : 2010 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
GPyFSA 0.34 (2012-15-07)
|
||||
GPyFSA 0.35 (2012-18-07)
|
||||
=========================
|
||||
|
||||
Install on Archlinux
|
||||
-------------------------
|
||||
sudo pacman -U http://sourceforge.net/projects/gpyfsa/files/packages/archlinux/gpyfsa-0.34-1-any.pkg.tar.xz/download
|
||||
sudo pacman -U http://sourceforge.net/projects/gpyfsa/files/packages/archlinux/gpyfsa-0.35-1-any.pkg.tar.xz/download
|
||||
|
||||
|
||||
(re)build instruction
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
[Desktop Entry]
|
||||
Name=GPyFSA
|
||||
Comment=GUI front end of fsarchiver with mounting facilities
|
||||
Version=0.34
|
||||
Version=0.35
|
||||
Icon=gpyfsa
|
||||
Exec=gpyfsa
|
||||
Terminal=false
|
||||
|
|
1526
gpyfsa/resources/gpyfsa/glade/gpyfsa-0.34.glade
Normal file
1526
gpyfsa/resources/gpyfsa/glade/gpyfsa-0.34.glade
Normal file
File diff suppressed because it is too large
Load Diff
|
@ -876,7 +876,6 @@
|
|||
<property name="can_focus">False</property>
|
||||
<child>
|
||||
<widget class="GtkLabel" id="l_tvcol_refresh">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes">refresh</property>
|
||||
</widget>
|
||||
|
@ -889,7 +888,6 @@
|
|||
<child>
|
||||
<widget class="GtkImage" id="i_refresh">
|
||||
<property name="height_request">25</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="pixbuf">../../pixmaps/gpyfsa/gpyfsa_refresh.png</property>
|
||||
</widget>
|
||||
|
@ -908,7 +906,16 @@
|
|||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<placeholder/>
|
||||
<widget class="GtkLabel" id="l_probing">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes">probing devices... please wait</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="expand">True</property>
|
||||
<property name="fill">True</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</widget>
|
||||
<packing>
|
||||
|
@ -932,7 +939,6 @@
|
|||
<property name="vscrollbar_policy">automatic</property>
|
||||
<child>
|
||||
<widget class="GtkTreeView" id="w_treedev">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
</widget>
|
||||
</child>
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
|
||||
# #
|
||||
# software : GPyFSA <http://gpyfsa.sourceforge.net/> #
|
||||
# version : 0.34 #
|
||||
# date : 2012-07-15 #
|
||||
# version : 0.35 #
|
||||
# date : 2012-07-18 #
|
||||
# licence : GPLv3.0 <http://www.gnu.org/licenses/> #
|
||||
# author : a-Sansara <http://www.a-sansara.net/> #
|
||||
# copyright : pluie.org <http://www.pluie.org/> #
|
||||
|
@ -38,7 +38,7 @@ for filepath in glob.glob('resources/locale/*/LC_MESSAGES/*.mo'):
|
|||
I18NFILES.append((targetpath, [filepath]))
|
||||
|
||||
setup(name='gpyfsa',
|
||||
version='0.34',
|
||||
version='0.35',
|
||||
packages=['GPyFSA'],
|
||||
scripts=['gpyfsa'],
|
||||
data_files=[('/usr/share/pixmaps' , glob.glob('resources/pixmaps/gpyfsa/gpyfsa.png')),
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Maintainer : a-Sansara <a-sansara@clochardprod.net>
|
||||
# Contributor:
|
||||
pkgname=gpyfsa
|
||||
pkgver=0.34
|
||||
pkgver=0.35
|
||||
pkgrel=1
|
||||
pkgdesc='a gtk+ GUI front-end of fsarchiver with mounting facilities'
|
||||
arch=('any')
|
||||
|
@ -10,7 +10,7 @@ license=('GPL3')
|
|||
depends=('gksu' 'python2' 'pygtk' 'desktop-file-utils' 'fsarchiver>=0.6.8')
|
||||
install="${pkgname}.install"
|
||||
source=("http://download.pluie.org/packages/archlinux/${pkgname}-${pkgver}.tar.bz2")
|
||||
md5sums=('7921db4f551bd959d75a9523f809105c')
|
||||
md5sums=('a4ecf31222b2bee37db1646580440a8f')
|
||||
|
||||
build() {
|
||||
cd "${srcdir}/${pkgname}"
|
||||
|
|
BIN
pkg/archlinux/gpyfsa-0.35-1-any.pkg.tar.xz
Normal file
BIN
pkg/archlinux/gpyfsa-0.35-1-any.pkg.tar.xz
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user