From 7d1331f1aaff3cc68cd7401b50381638681badcc Mon Sep 17 00:00:00 2001 From: hummypkg Date: Sun, 3 Jun 2012 20:12:31 +0000 Subject: [PATCH] add Humax version to main screen, fix shtml footer; git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@1029 2a923420-c742-0410-a762-8d5b09965624 --- CONTROL/control | 4 ++-- var/mongoose/html/lib/footer.jim | 8 +++++--- var/mongoose/include/modversion.jim | 7 ++++++- var/mongoose/lib/system.class | 12 ++++++++++++ 4 files changed, 25 insertions(+), 6 deletions(-) diff --git a/CONTROL/control b/CONTROL/control index c094cb66..7baa4363 100644 --- a/CONTROL/control +++ b/CONTROL/control @@ -1,9 +1,9 @@ Package: webif Priority: optional Section: web -Version: 0.9.10 +Version: 0.9.10-1 Architecture: mipsel Maintainer: af123@hummypkg.org.uk -Depends: webif-channelicons(>=1.0.1),mongoose(>=3.0-7),jim(>=0.73-1),jim-oo,jim-sqlite3(>=0.73),jim-cgi(>=0.5),service-control(>=1.2),busybox(>=1.19.3-1),lsof,epg(>=1.0.9),hmt(>=1.1.6),ssmtp,anacron,trm,openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.1) +Depends: webif-channelicons(>=1.0.1),mongoose(>=3.0-7),jim(>=0.73-1),jim-oo,jim-sqlite3(>=0.73),jim-cgi(>=0.5),service-control(>=1.2),busybox(>=1.19.3-1),lsof,epg(>=1.0.9),hmt(>=1.1.6),ssmtp,anacron,trm,openssl-command,nicesplice,id3v2,file,rsvsync(>=1.0.2),webif-charts(>=1.2) Suggests: ffmpeg,webif-iphone Description: An evolving web interface for the Humax. diff --git a/var/mongoose/html/lib/footer.jim b/var/mongoose/html/lib/footer.jim index 0f861b7e..3eab0554 100755 --- a/var/mongoose/html/lib/footer.jim +++ b/var/mongoose/html/lib/footer.jim @@ -5,9 +5,11 @@ puts { diff --git a/var/mongoose/include/modversion.jim b/var/mongoose/include/modversion.jim index 33d3ab70..0584b1b2 100755 --- a/var/mongoose/include/modversion.jim +++ b/var/mongoose/include/modversion.jim @@ -3,8 +3,13 @@ source /mod/webif/lib/setup require system.class + puts " Web interface version: [system pkgver webif]
Custom firmware version: [system modversion] -
" +" +if {![catch {set fhtcpversion [system fhtcpversion]}]} { + puts "
Humax Version: $fhtcpversion" +} +puts "" diff --git a/var/mongoose/lib/system.class b/var/mongoose/lib/system.class index 7fa97ead..4ba7e665 100644 --- a/var/mongoose/lib/system.class +++ b/var/mongoose/lib/system.class @@ -33,6 +33,18 @@ proc {system modversion} {{short 0}} { return [format "%d.%d%d" $a $b $c] } +proc {system fhtcpversion} {} { + set file "/etc/fhtcpversion" + if {![file exists $file]} { set file "/root/fhtcpversion" } + if {[catch {set fp [open $file r]}]} { + set ver "?.??.??" + } else { + set ver [string trim [read $fp]] + close $fp + } + return $ver +} + proc {system pkgver} {{pkg webif}} { return [lrange [split [exec opkg list-installed $pkg] " "] 2 end] }