diff options
Diffstat (limited to '')
-rwxr-xr-x | module/main.scm | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/module/main.scm b/module/main.scm index 246e729c..332d9990 100755 --- a/module/main.scm +++ b/module/main.scm @@ -1,10 +1,9 @@ -#!/bin/bash -# -*- mode: scheme; geiser-scheme-implementation: guile -*- +;; -*- geiser-scheme-implementation: guile -*- -. $(dirname $(dirname $(realpath $0)))/env +(when (current-filename) + (add-to-load-path (dirname (current-filename)))) -exec guile -e main -s $0 "$@" -!# +(set! (@ (global) basedir) (car %load-path)) (use-modules (srfi srfi-1) (srfi srfi-41) @@ -14,6 +13,7 @@ exec guile -e main -s $0 "$@" (util) (util io) (util time) + (util app) ((entry-points html) :prefix html-) ((entry-points terminal) :prefix terminal-) @@ -32,6 +32,7 @@ exec guile -e main -s $0 "$@" ) + (define options '((statprof (value optional)) (repl (value optional)) @@ -57,6 +58,12 @@ exec guile -e main -s $0 "$@" (when (file-exists? config-file) (primitive-load config-file))) + + ;; (current-app (make-app)) + + ((@ (vcomponent) init-app) (get-config 'calendar-files)) + ((@ (datetime app) init-app)) + (let ((ropt (ornull (option-ref opts '() '()) '("term")))) ((case (string->symbol (car ropt)) |