diff options
author | Arun Isaac | 2023-01-23 23:16:03 +0000 |
---|---|---|
committer | Arun Isaac | 2023-01-23 23:16:44 +0000 |
commit | baed1d3f1bde48aa7ecafed22c6ad4c538ebf5d8 (patch) | |
tree | be0ce27cac76d3156de2d9eca295846ac20b2781 /bin | |
parent | bb0c921a38a468300c70483d2d1370d63e7e070a (diff) | |
download | tissue-baed1d3f1bde48aa7ecafed22c6ad4c538ebf5d8.tar.gz tissue-baed1d3f1bde48aa7ecafed22c6ad4c538ebf5d8.tar.lz tissue-baed1d3f1bde48aa7ecafed22c6ad4c538ebf5d8.zip |
bin: Add repository top level directory to load path.
* bin/tissue (main, pull): Add top level directory of repository to
load path.
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/tissue | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -406,6 +406,13 @@ HOSTNAME." (call-with-temporary-directory (lambda (temporary-repository-clone) (clone (git-top-level) temporary-repository-clone) + ;; Add the top level of the git repository to the + ;; load path since there may be user-written + ;; modules in the repository. + ;; TODO: Though not strictly required, it would + ;; be better to remove the added load path once + ;; done. + (add-to-load-path temporary-repository-clone) ;; Index. (unless (file-exists? "xapian") (mkdir "xapian")) @@ -482,6 +489,12 @@ Pull latest from upstream repositories. (display (condition-message c) (current-error-port)) (newline (current-error-port)) (exit #f))) + ;; Add the top level of the git repository to the load path since + ;; there may be user-written modules in the repository. + (match args + ((_ (or "repl" "web-dev") _ ...) + (add-to-load-path (git-top-level))) + (_ #t)) (match args ((_ (or "-h" "--help")) (print-usage)) |