forked from hummypkg/webif
tweak update all
git-svn-id: file:///root/webif/svn/humax/pkg/src/webif/trunk@445 2a923420-c742-0410-a762-8d5b09965624
This commit is contained in:
parent
8949bfaa02
commit
0fa394eaa1
@ -1,7 +1,7 @@
|
||||
Package: webif
|
||||
Priority: optional
|
||||
Section: web
|
||||
Version: 0.7.5
|
||||
Version: 0.7.5-1
|
||||
Architecture: mipsel
|
||||
Maintainer: af123@hummypkg.org.uk
|
||||
Depends: mongoose(>=3.0-2),jim(>=0.71-1),jim-sqlite3(>=0.71-1),jim-cgi(>=0.4),jim-oo,jim-pack,service-control,busybox(>=1.18.3-1),lsof,epg(>=1.0.5),hmt(>=1.0.6),ssmtp
|
||||
|
@ -9,17 +9,23 @@ cgi_input
|
||||
|
||||
set cmd [cgi_get cmd update]
|
||||
|
||||
proc opkg {cmd} {
|
||||
chunk ">>> opkg $cmd\r\n"
|
||||
set bcmd "|/mod/var/mongoose/lib/opkg $cmd"
|
||||
set fd [open $bcmd r]
|
||||
while {[gets $fd line] >= 0} {
|
||||
chunk "$line\r\n"
|
||||
#chunk_pad
|
||||
}
|
||||
close $fd
|
||||
}
|
||||
|
||||
start_chunked
|
||||
|
||||
set bcmd "|/mod/var/mongoose/lib/opkg $cmd"
|
||||
set fd [open $bcmd r]
|
||||
while {[gets $fd line] >= 0} {
|
||||
chunk "$line\r\n"
|
||||
#chunk_pad
|
||||
}
|
||||
close $fd
|
||||
if {$cmd eq "upgrade"} { opkg update }
|
||||
opkg $cmd
|
||||
|
||||
if {$cmd eq "update"} {
|
||||
if {$cmd eq "update" || $cmd eq "upgrade"} {
|
||||
chunk "Updating package meta information\r\n"
|
||||
pkg fetchmeta
|
||||
chunk "Done.\r\n"
|
||||
|
@ -3,11 +3,7 @@
|
||||
set services [split [exec /mod/bin/service mlist]]
|
||||
|
||||
foreach service $services {
|
||||
set data [split $service ":"]
|
||||
set name [lindex $data 0]
|
||||
set installed [lindex $data 1]
|
||||
set auto [lindex $data 2]
|
||||
set running [lindex $data 3]
|
||||
lassign [split $service ":"] name installed auto running
|
||||
|
||||
puts "<tr><td class=even>$name</td>"
|
||||
if (!$installed) {
|
||||
|
Loading…
Reference in New Issue
Block a user