diff --git a/.gitignore b/.gitignore --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -docker/config.lisp +/docker/config.lisp* diff --git a/bin/build-config-tmpl b/bin/build-config-tmpl --- a/bin/build-config-tmpl +++ b/bin/build-config-tmpl @@ -5,6 +5,12 @@ (when (probe-file quicklisp-init) (load quicklisp-init))) +;; Make sure we can provide path to forgerie code... +(let ((forgerie-path (uiop:getenv "FORGERIE_PATH"))) + (when (and forgerie-path (probe-file forgerie-path)) + (push (pathname forgerie-path) asdf:*central-registry*))) + +;; so quicklisp is able to run the forgerie code and execute the script (ql:quickload :forgerie) (with-open-file (str "config/config.lisp.tmpl" :direction :output :if-exists :supersede) diff --git a/bin/postmortem b/bin/postmortem --- a/bin/postmortem +++ b/bin/postmortem @@ -5,6 +5,11 @@ (when (probe-file quicklisp-init) (load quicklisp-init))) +;; Make sure we can provide path to forgerie code... +(let ((forgerie-path (uiop:getenv "FORGERIE_PATH"))) + (when (and forgerie-path (probe-file forgerie-path)) + (push (pathname forgerie-path) asdf:*central-registry*))) + (ql:quickload :forgerie) (forgerie-core:postmortem :phabricator :gitlab) diff --git a/bin/run b/bin/run --- a/bin/run +++ b/bin/run @@ -1,10 +1,16 @@ #!/usr/bin/env -S /usr/bin/sbcl --dynamic-space-size 4096 --script + (let ((quicklisp-init (merge-pathnames "quicklisp/setup.lisp" (user-homedir-pathname)))) (when (probe-file quicklisp-init) (load quicklisp-init))) +;; Make sure we can provide path to forgerie code... +(let ((forgerie-path (uiop:getenv "FORGERIE_PATH"))) + (when (and forgerie-path (probe-file forgerie-path)) + (push (pathname forgerie-path) asdf:*central-registry*))) + (ql:quickload :forgerie) (forgerie-core:run :phabricator :gitlab)