]> Git repositories of Nishi - koakuma.git/commitdiff
better layout
authorNishi <nishi@nishi.boats>
Wed, 2 Oct 2024 06:42:12 +0000 (06:42 +0000)
committerNishi <nishi@nishi.boats>
Wed, 2 Oct 2024 06:42:12 +0000 (06:42 +0000)
git-svn-id: file:///raid/svn-personal/koakuma/trunk@15 219d0f9c-2d94-d447-890a-813e76b88fe9

koakuma.cgi.in

index 6eeb7b27a1693c673638b36d1f283700d78ba8ec..f9422848efd4f9bdd7762516d0c28d700e8c64ad 100644 (file)
@@ -610,35 +610,35 @@ if { [catch {
                                tputs   "<table border=\"0\">"
                                tputs   "       <tr>"
                                tputs   "               <th>"
-                               tputs   "                       Last run"
+                               tputs   "                       Status"
                                tputs   "               </th>"
                                tputs   "               <td>"
-                               if { [file exists "@@PREFIX@@/lib/koakuma/db/data/$projname/lastrun"] } {
-                                       set fid [open "@@PREFIX@@/lib/koakuma/db/data/$projname/lastrun" "r"]
-                                       set date "[clock format "[gets $fid]" -format "%a %b %d %H:%M:%S %Z %Y"]"
+                               if { [file exists "@@PREFIX@@/lib/koakuma/db/data/$projname/build.lock"] } {
+                                       set fid [open "@@PREFIX@@/lib/koakuma/db/data/$projname/build.loc" "r"]
+                                       if { [file exists "/proc/[gets $fid]"] } {
+                                               tputs "Running"
+                                       } else {
+                                               tputs "Idle"
+                                       }
                                        close $fid
-                                       tputs "$date"
                                } else {
-                                       tputs "No builds yet"
+                                       tputs "Idle"
                                }
                                tputs   "                       "
                                tputs   "               </td>"
                                tputs   "       </tr>"
                                tputs   "       <tr>"
                                tputs   "               <th>"
-                               tputs   "                       Status"
+                               tputs   "                       Last run"
                                tputs   "               </th>"
                                tputs   "               <td>"
-                               if { [file exists "@@PREFIX@@/lib/koakuma/db/data/$projname/build.lock"] } {
-                                       set fid [open "@@PREFIX@@/lib/koakuma/db/data/$projname/build.loc" "r"]
-                                       if { [file exists "/proc/[gets $fid]"] } {
-                                               tputs "Running"
-                                       } else {
-                                               tputs "Idle"
-                                       }
+                               if { [file exists "@@PREFIX@@/lib/koakuma/db/data/$projname/lastrun"] } {
+                                       set fid [open "@@PREFIX@@/lib/koakuma/db/data/$projname/lastrun" "r"]
+                                       set date "[clock format "[gets $fid]" -format "%a %b %d %H:%M:%S %Z %Y"]"
                                        close $fid
+                                       tputs "$date"
                                } else {
-                                       tputs "Idle"
+                                       tputs "No builds yet"
                                }
                                tputs   "                       "
                                tputs   "               </td>"