diff options
author | Mathieu Lirzin <mthl@gnu.org> | 2015-08-12 16:02:58 +0200 |
---|---|---|
committer | Mathieu Lirzin <mthl@gnu.org> | 2016-05-07 11:32:19 +0200 |
commit | f835793336020212b03232486aa5f76b9953a632 (patch) | |
tree | f5a187e6d992409c898eb8991b049d04ed9240aa | |
parent | 7ed303705c17b127cc224ee1ddecc53a931d65e5 (diff) | |
download | mcron-f835793336020212b03232486aa5f76b9953a632.tar.gz mcron-f835793336020212b03232486aa5f76b9953a632.tar.bz2 mcron-f835793336020212b03232486aa5f76b9953a632.zip |
main: Import the modules all together.
* scm/mcron/main.scm: Gather module imports.
-rw-r--r-- | scm/mcron/main.scm | 30 |
1 files changed, 9 insertions, 21 deletions
diff --git a/scm/mcron/main.scm b/scm/mcron/main.scm index 5f48379..ddd7619 100644 --- a/scm/mcron/main.scm +++ b/scm/mcron/main.scm @@ -29,12 +29,16 @@ ;; (l0ad "crontab.scm") (sic) is inlined by the makefile. All other ;; functionality comes through modules in .../share/guile/site/mcron/*.scm. +(use-modules (ice-9 getopt-long) + (ice-9 rdelim) + (ice-9 regex) + (mcron config) + (mcron core) + (mcron job-specifier) + (mcron vixie-specification) + (srfi srfi-2)) - -;; Pull in some constants set by the builder (via autoconf) at configuration -;; time. Turn debugging on if indicated. - -(use-modules (mcron config)) +;; Turn debugging on if indicated. (if config-debug (begin (debug-enable 'debug) (debug-enable 'backtrace))) @@ -44,8 +48,6 @@ ;; backwards for the first non-alphabetic character. This allows names like ;; in.cron to be accepted as an invocation of the cron command. -(use-modules (ice-9 regex) (ice-9 rdelim)) - (define command-name (match:substring (regexp-exec (make-regexp "[[:alpha:]]*$") (car (command-line))))) @@ -93,8 +95,6 @@ ;; all the others, with the --help and --version options common to all the ;; personalities. -(use-modules (ice-9 getopt-long)) - (define options (catch 'misc-error @@ -234,16 +234,6 @@ reading all the information in the users' crontabs and in /etc/crontab.\n (c-set-cron-signals))) - -;; Define the functions available to the configuration files. While we're here, -;; we'll get the core loaded as well. - -(use-modules (mcron core) - (mcron job-specifier) - (mcron vixie-specification)) - - - ;; Procedure to slurp the standard input into a string. (define (stdin->string) @@ -349,8 +339,6 @@ reading all the information in the users' crontabs and in /etc/crontab.\n ;; operation, but we leave it to the permissions on the /var/cron/tabs directory ;; to enforce this. -(use-modules (srfi srfi-2)) ;; For and-let*. - (define (process-files-in-system-directory) (catch #t (lambda () |