Index: apimod.scm ================================================================== --- apimod.scm +++ apimod.scm @@ -25,11 +25,11 @@ (declare (uses dbfile)) (declare (uses tcp-transportmod)) (declare (uses megatestmod)) (module apimod - * +() (import scheme chicken data-structures extras) (import (prefix sqlite3 sqlite3:) posix matchable typed-records srfi-1 srfi-18 srfi-69 ) (import commonmod) (import debugprint) Index: archivemod.scm ================================================================== --- archivemod.scm +++ archivemod.scm @@ -37,11 +37,11 @@ (declare (uses dbfile)) (use srfi-69) (module archivemod - * +() (import scheme) (cond-expand (chicken-4 @@ -121,11 +121,11 @@ srfi-69 typed-records z3 ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") ;;====================================================================== ;; ;;====================================================================== Index: common.scm ================================================================== --- common.scm +++ common.scm @@ -43,11 +43,11 @@ debugprint configfmod rmtmod (prefix mtargs args:)) -(include "common_records.scm") +;; (include "common_records.scm") Index: commonmod.scm ================================================================== --- commonmod.scm +++ commonmod.scm @@ -50,12 +50,38 @@ (import stml2 ) (module commonmod - * + ( + common:get-toppath + common:generic-ssh + common:file-exists? + common:with-env-vars + common:nice-path + common:get-fields + ;; globals + *configdat* + *db-access-allowed* + *db-cache-path* + *toppath* + + keys:target-set-args + + getenv + setenv + safe-setenv + + get-area-path-signature + common:simple-file-lock + common:low-noise-print + common:get-create-writeable-dir + common:real-path + val->alist +) + (import scheme) (cond-expand (chicken-4 (import chicken @@ -385,10 +411,11 @@ (define *last-launch* (current-seconds)) ;; use for throttling the launch rate. Would be better to use the db and last time of a test in LAUNCHED state. ;; environment vars handy stuff from common.scm ;; (define getenv get-environment-variable) + (define (safe-setenv key val) (if (or (substring-index "!" key) (substring-index ":" key) ;; variables containing : are for internal use and cannot be environment variables. (substring-index "." key)) ;; periods are not allowed in environment variables (debug:print-error 4 *default-log-port* "skip setting internal use only variables containing \":\" or starting with \"!\"") @@ -563,13 +590,10 @@ (if valstr (val->alist valstr) '()))) ;; should it return empty list or #f to indicate not set? -(define (get-section cfgdat section) - (hash-table-ref/default cfgdat section '())) - (define (common:make-tmpdir-name areapath tmpadj) (let* ((area (pathname-file areapath)) (dname (conc "/tmp/"(current-user-name)"/megatest_localdb/" area "/" (string-translate areapath "/" ".") tmpadj "/.mtdb"))) (unless (directory-exists? dname) (create-directory dname #t)) Index: configfmod.scm ================================================================== --- configfmod.scm +++ configfmod.scm @@ -25,11 +25,16 @@ (declare (uses mtargs)) (use regex regex-case) (module configfmod -* + ( + lookup + configf:lookup + get-section + configf:get-section + ) (import scheme chicken extras files @@ -203,10 +208,12 @@ (if match ;; (and match (list? match)(> (length match) 1)) (cadr match) #f)) )) #f)) + +(define lookup configf:lookup) ;; use to have definitive setting: ;; [foo] ;; var yes ;; @@ -234,10 +241,12 @@ '() (map car sectdat)))) (define (configf:get-section cfgdat section) (hash-table-ref/default cfgdat section '())) + +(define get-section configf:get-section) (define (configf:set-section-var cfgdat section var val) (let ((sectdat (configf:get-section cfgdat section))) (hash-table-set! cfgdat section (configf:assoc-safe-add sectdat var val)))) Index: cpumod.scm ================================================================== --- cpumod.scm +++ cpumod.scm @@ -29,11 +29,12 @@ (declare (uses mtargs)) (use srfi-69) (module cpumod - * + () + (import scheme) (cond-expand (chicken-4 Index: dashboard-context-menu.scm ================================================================== --- dashboard-context-menu.scm +++ dashboard-context-menu.scm @@ -44,11 +44,11 @@ (use canvas-draw) (use srfi-1 posix regex regex-case srfi-69) (use (prefix sqlite3 sqlite3:)) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") (include "run_records.scm") (import commonmod configfmod Index: dashboard-guimonitor.scm ================================================================== --- dashboard-guimonitor.scm +++ dashboard-guimonitor.scm @@ -35,11 +35,11 @@ (declare (uses common)) (declare (uses keys)) (declare (uses commonmod)) (import commonmod) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") (include "run_records.scm") (include "task_records.scm") (define (control-panel db tdb keys) Index: dashboard-tests.scm ================================================================== --- dashboard-tests.scm +++ dashboard-tests.scm @@ -61,11 +61,11 @@ testsmod runsmod subrunmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") (include "run_records.scm") ;;====================================================================== ;; C O M M O N Index: dashboard.scm ================================================================== --- dashboard.scm +++ dashboard.scm @@ -107,11 +107,11 @@ tasksmod runsmod testsmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") (include "run_records.scm") (include "task_records.scm") (include "megatest-version.scm") (include "megatest-fossil-hash.scm") Index: dbmod.scm ================================================================== --- dbmod.scm +++ dbmod.scm @@ -26,11 +26,11 @@ (declare (uses debugprint)) (declare (uses mtargs)) (declare (uses mtmod)) (module dbmod - * +() (import scheme) (cond-expand (chicken-4 @@ -79,11 +79,11 @@ dbfile debugprint mtmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") ;; (include "key_records.scm") (include "run_records.scm") (define *number-of-writes* 0) Index: dcommon.scm ================================================================== --- dcommon.scm +++ dcommon.scm @@ -40,11 +40,11 @@ testsmod dbmod debugprint) (include "megatest-version.scm") -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") ;; (include "key_records.scm") (include "run_records.scm") ;; yes, this is non-ideal Index: diff-report.scm ================================================================== --- diff-report.scm +++ diff-report.scm @@ -23,11 +23,11 @@ (declare (uses commonmod)) (import commonmod rmtmod debugprint) -(include "common_records.scm") +;; (include "common_records.scm") (use matchable) (use fmt) (use ducttape-lib) (define css "") Index: ezstepsmod.scm ================================================================== --- ezstepsmod.scm +++ ezstepsmod.scm @@ -45,11 +45,11 @@ (declare (uses fsmod)) (use srfi-69) (module ezstepsmod - * + () (import scheme) (cond-expand (chicken-4 @@ -126,11 +126,11 @@ testsmod runsmod fsmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") Index: fsmod.scm ================================================================== --- fsmod.scm +++ fsmod.scm @@ -33,11 +33,12 @@ (declare (uses processmod)) (use srfi-69) (module fsmod - * + ( + ) (import scheme) (cond-expand (chicken-4 Index: launch.scm ================================================================== --- launch.scm +++ launch.scm @@ -46,11 +46,11 @@ (import (prefix base64 base64:) (prefix sqlite3 sqlite3:) (prefix mtargs args:) ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "megatest-fossil-hash.scm") (import commonmod Index: launchmod.scm ================================================================== --- launchmod.scm +++ launchmod.scm @@ -44,11 +44,12 @@ (declare (uses fsmod)) (use srfi-69) (module launchmod - * + ( + ) (import scheme) (cond-expand (chicken-4 @@ -126,11 +127,11 @@ testsmod runsmod fsmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "megatest-fossil-hash.scm") ;;====================================================================== Index: megatest.scm ================================================================== --- megatest.scm +++ megatest.scm @@ -121,11 +121,11 @@ fsmod ) (define *db* #f) ;; this is only for the repl, do not use in general!!!! -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") (include "megatest-fossil-hash.scm") Index: megatestmod.scm ================================================================== --- megatestmod.scm +++ megatestmod.scm @@ -38,11 +38,12 @@ (declare (uses fsmod)) (use srfi-69) (module megatestmod - * + ( + ) (import scheme) (cond-expand (chicken-4 Index: monitor.scm ================================================================== --- monitor.scm +++ monitor.scm @@ -25,10 +25,10 @@ (declare (uses runconfig)) (declare (uses commonmod)) (import commonmod) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") Index: mt.scm ================================================================== --- mt.scm +++ mt.scm @@ -41,11 +41,11 @@ megatestmod) ;; make mt: calls in megatestmod work ;; (read-config-set! read-config) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") ;; (include "test_records.scm") Index: mtmod.scm ================================================================== --- mtmod.scm +++ mtmod.scm @@ -32,11 +32,12 @@ ;; (declare (uses tcp-transportmod)) ;; we don't want mtmod depending on tcp (use srfi-69) (module mtmod - * + ( + ) (import scheme) (cond-expand (chicken-4 Index: odsmod.scm ================================================================== --- odsmod.scm +++ odsmod.scm @@ -23,11 +23,12 @@ (declare (uses debugprint)) (declare (uses dbfile)) (declare (uses dbmod)) (module odsmod - * + ( + ) (import scheme chicken data-structures extras Index: processmod.scm ================================================================== --- processmod.scm +++ processmod.scm @@ -23,11 +23,14 @@ (declare (uses commonmod)) (use srfi-69) (module processmod - * + ( + process:cmd-run->list + + ) (import scheme) (cond-expand (chicken-4 Index: rmtmod.scm ================================================================== --- rmtmod.scm +++ rmtmod.scm @@ -28,11 +28,14 @@ (declare (uses tcp-transportmod)) (declare (uses apimod)) (declare (uses servermod)) (module rmtmod - * + ( + rmtmod:send-receive + + ) (import scheme chicken data-structures regex Index: runconfig.scm ================================================================== --- runconfig.scm +++ runconfig.scm @@ -28,7 +28,7 @@ (declare (uses commonmod)) (import commonmod debugprint) -(include "common_records.scm") +;; (include "common_records.scm") Index: runs.scm ================================================================== --- runs.scm +++ runs.scm @@ -42,11 +42,11 @@ posix-extras directory-utils pathname-expand typed-records format sxml-serializer sxml-modifications matchable) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") ;; (include "test_records.scm") Index: runsmod.scm ================================================================== --- runsmod.scm +++ runsmod.scm @@ -44,11 +44,12 @@ (declare (uses fsmod)) (use srfi-69) (module runsmod - * + ( + ) (import scheme) (cond-expand (chicken-4 @@ -127,11 +128,11 @@ subrunmod archivemod fsmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") ;; (include "test_records.scm") Index: server.scm ================================================================== --- server.scm +++ server.scm @@ -34,11 +34,11 @@ (import commonmod configfmod debugprint (prefix mtargs args:)) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") (define (db:kill-servers) (let* ((tl (launch:setup)) ;; need this to initialize *toppath* (servdir (conc *toppath* "/.servinfo")) Index: servermod.scm ================================================================== --- servermod.scm +++ servermod.scm @@ -23,11 +23,12 @@ (declare (uses mtmod)) (declare (uses debugprint)) (declare (uses mtargs)) (module servermod - * + ( + ) (import scheme chicken) (use (srfi 18) extras s11n) @@ -46,11 +47,11 @@ debugprint (prefix mtargs args:) mtmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") (define (server:make-server-url hostport) (if (not hostport) #f Index: subrunmod.scm ================================================================== --- subrunmod.scm +++ subrunmod.scm @@ -40,11 +40,12 @@ (declare (uses tasksmod)) (use srfi-69) (module subrunmod - * + ( + ) (import scheme) (cond-expand (chicken-4 Index: tasksmod.scm ================================================================== --- tasksmod.scm +++ tasksmod.scm @@ -39,11 +39,12 @@ (declare (uses megatestmod)) (use srfi-69) (module tasksmod - * + ( + ) (import scheme) (cond-expand (chicken-4 Index: tcp-transportmod.scm ================================================================== --- tcp-transportmod.scm +++ tcp-transportmod.scm @@ -27,11 +27,12 @@ (declare (uses mtmod)) (use address-info tcp) (module tcp-transportmod - * + ( + ) (import scheme) (cond-expand (chicken-4 Index: tdb.scm ================================================================== --- tdb.scm +++ tdb.scm @@ -39,11 +39,11 @@ (import commonmod debugprint rmtmod (prefix mtargs args:)) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") ;; (include "key_records.scm") (include "run_records.scm") ;;====================================================================== Index: testsmod.scm ================================================================== --- testsmod.scm +++ testsmod.scm @@ -39,11 +39,13 @@ (declare (uses fsmod)) (use srfi-69) (module testsmod - * + ( + tests:summarize-items + ) (import scheme) (cond-expand (chicken-4 @@ -125,11 +127,11 @@ mtmod servermod fsmod ) -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "key_records.scm") ;; (include "db_records.scm") (include "run_records.scm") ;; (include "test_records.scm") (include "js-path.scm") Index: tree.scm ================================================================== --- tree.scm +++ tree.scm @@ -36,11 +36,11 @@ (import (prefix mtargs args:) debugprint) (include "megatest-version.scm") -(include "common_records.scm") +;; (include "common_records.scm") ;; (include "db_records.scm") ;; (include "key_records.scm") ;;====================================================================== ;; T R E E S T U F F ADDED utils/extract-export-list.sh Index: utils/extract-export-list.sh ================================================================== --- /dev/null +++ utils/extract-export-list.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +LAST_PARENT=foobar + +for fn in $(grep 'Warning: refer' typescript |tr '`' ' '|tr "'" " "|awk '{print $7}');do + PARENT=$(grep $fn *mod.scm|grep define|cut -d: -f1) + if [[ $PARENT != $LAST_PARENT ]];then + echo + echo $PARENT + LAST_PARENT=$PARENT + fi + echo $fn +done