diff options
author | Hugo Hörnquist <hugo@hornquist.se> | 2019-12-28 02:32:38 +0100 |
---|---|---|
committer | Hugo Hörnquist <hugo@hornquist.se> | 2019-12-28 02:32:38 +0100 |
commit | e9c12af512349cb95a0018e25a9cc54e78b468a4 (patch) | |
tree | 7bdfc3a05d673e220c5a3a49ebfbe7d4ebb6dba6 /module/config.scm | |
parent | Broke out vevent->sxml into generalized function. (diff) | |
download | calp-e9c12af512349cb95a0018e25a9cc54e78b468a4.tar.gz calp-e9c12af512349cb95a0018e25a9cc54e78b468a4.tar.xz |
Move config from module to config directory.
Diffstat (limited to 'module/config.scm')
-rw-r--r-- | module/config.scm | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/module/config.scm b/module/config.scm deleted file mode 100644 index 08c678c9..00000000 --- a/module/config.scm +++ /dev/null @@ -1,32 +0,0 @@ -;;; Preliminary config file for the system. -;;; Currently loaded by main, and requires that `calendar-files` -;;; is set to a list of files (or directories). - -(define-module (config) #:use-module (parameters)) - -(use-modules (srfi srfi-26) - (srfi srfi-88) - (ice-9 regex) - (ice-9 rdelim) - (glob)) - -(calendar-files (glob "~/.local/var/cal/*")) - -;;; TODO possibly replace with propper lookup -(define my-courses - '((TSEA82 . "Datorteknik") - (TFYA19 . "Kvantdatorer") - (TATA42 . "Tvåvarren") - (TSRT04 . "Matlab") - (TDDC78 . "Paralellprogrammering") - (TDDB68 . "Pintos"))) - -(define* (aref alist key optional: default) - (or (assoc-ref alist key) default key)) - -(summary-filter - (lambda (ev str) - (regexp-substitute/global - #f "T[A-Z]{3}[0-9]{2}" str - 'pre (lambda (m) (aref my-courses (string->symbol (match:substring m)))) - 'post))) |