Skip to content
Permalink
Browse files

Merge pull request #23 from dunn/paths

paths.lisp: simplify, install global packages to qi/share
  • Loading branch information...
CodyReichert committed Nov 4, 2016
2 parents 3eeddeb + 6f11b34 commit 7fe2ce2d95966d2efb6edc6c0c98b13e443e9837
Showing with 14 additions and 16 deletions.
  1. +3 −3 .gitignore
  2. +3 −3 init.lisp
  3. +8 −10 src/paths.lisp
@@ -1,11 +1,11 @@
*.fasl
*.dx32fsl
*.dx64fsl
*.fasl
*.lx32fsl
*.lx64fsl
*.x86f
*~
.#*
.dependencies
t/resources/tar/*-master/
/share
t/resources/tar/*-latest/
t/resources/tar/*-master/
@@ -64,12 +64,12 @@ compiling asdf.lisp to a FASL and then loading it."
(defun load-user-packages ()
"Make user-global-packages available to ASDF. They're not immediately
available like qi, but can be make so by (qi:qiload :<system>)."
(loop for dir in (directory (qi-dir ".dependencies/packages/**"))
(loop for dir in (directory (qi-dir "share/qi/packages/**"))
do (push-new-to-registry dir)))


;; Walk ./dependencies and make all of qi's dependencies
;; available. Also walk ./.dependencies/packages to load in user
;; Walk dependencies and make all of qi's dependencies
;; available. Also walk share/qi/packages to load in user
;; globally-installed packages.
(let ((qi-deps-to-load (directory (concatenate 'string (namestring +qi-dependencies+) "**"))))
(setf asdf:*central-registry* nil)
@@ -5,8 +5,7 @@
:+project-name+
:+qi-directory+
:package-dir
:project-dir
:qi-dir))
:project-dir))
(in-package :qi.paths)

;; Code:
@@ -33,12 +32,11 @@ Qi is not running in the context of a project.")
"Pathname/directory for <proj>."
(asdf:system-relative-pathname proj (qi.util:sym->str proj)))

(defun qi-dir ()
(fad:merge-pathnames-as-directory
(project-dir +project-name+)
(ensure-directories-exist #P".dependencies/")))

(defun package-dir ()
(fad:merge-pathnames-as-directory
(project-dir +project-name+)
(ensure-directories-exist #P".dependencies/packages/")))
(ensure-directories-exist
(fad:merge-pathnames-as-directory
(project-dir +project-name+)
(if (equal "qi"
(qi.util:sym->str +project-name+))
#P"share/qi/packages/"
#P".dependencies/packages/"))))

0 comments on commit 7fe2ce2

Please sign in to comment.
You can’t perform that action at this time.