Преглед на файлове

Got it working with CCL.

Ralph Moeritz преди 12 години
родител
ревизия
f52ef504fd
променени са 3 файла, в които са добавени 19 реда и са изтрити 5 реда
  1. 7 2
      coleslaw.asd
  2. 9 0
      example-ccl.post-receive
  3. 3 3
      src/util.lisp

+ 7 - 2
coleslaw.asd

@@ -5,8 +5,13 @@
5 5
   :license "BSD"
6 6
   :author "Brit Butler <redline6561@gmail.com>"
7 7
   :pathname "src/"
8
-  :depends-on (:closure-template :3bmd :3bmd-ext-code-blocks
9
-               :alexandria :local-time :trivial-shell :cl-fad)
8
+  :depends-on (:closure-template 
9
+               :3bmd 
10
+               :3bmd-ext-code-blocks
11
+               :alexandria 
12
+               :local-time 
13
+               :inferior-shell 
14
+               :cl-fad)
10 15
   :serial t
11 16
   :components ((:file "packages")
12 17
                (:file "util")

+ 9 - 0
example-ccl.post-receive

@@ -0,0 +1,9 @@
1
+GIT_REPO=$HOME/lisp-is-fun.git
2
+# TMP_GIT_CLONE _must_ match the :repo arg in coleslawrc excluding trailing slash
3
+TMP_GIT_CLONE=$HOME/lisp-is-fun/tmp
4
+
5
+git clone $GIT_REPO $TMP_GIT_CLONE
6
+echo "(ql:quickload :coleslaw)
7
+(coleslaw:main)" | ccl -b
8
+rm -Rf $TMP_GIT_CLONE
9
+exit

+ 3 - 3
src/util.lisp

@@ -8,7 +8,7 @@ If ARGS is provided, use (apply 'format nil PATH ARGS) as the value of PATH."
8 8
 (defun run-program (program &rest args)
9 9
   "Take a PROGRAM and execute the corresponding shell command. If ARGS is provided,
10 10
 use (apply 'format nil PROGRAM ARGS) as the value of PROGRAM."
11
-  (trivial-shell:shell-command (apply 'format nil program args)))
11
+  (inferior-shell:run (apply 'format nil program args) :show t))
12 12
 
13 13
 (defun update-symlink (path target)
14 14
   "Update the symlink at PATH to point to TARGET."
@@ -28,7 +28,7 @@ on files that match the given extension."
28 28
 (defun current-directory ()
29 29
   "Return the operating system's current directory."
30 30
   #+sbcl (sb-posix:getcwd)
31
-  #+ccl (current-directory)
31
+  #+ccl (ccl:current-directory)
32 32
   #+ecl (si:getcwd)
33 33
   #+cmucl (unix:unix-current-directory)
34 34
   #+clisp (ext:cd)
@@ -37,7 +37,7 @@ on files that match the given extension."
37 37
 (defun (setf current-directory) (path)
38 38
   "Change the operating system's current directory to PATH."
39 39
   #+sbcl (sb-posix:chdir path)
40
-  #+ccl (setf (current-directory) path)
40
+  #+ccl (setf (ccl:current-directory) path)
41 41
   #+ecl (si:chdir path)
42 42
   #+cmucl (unix:unix-chdir (namestring path))
43 43
   #+clisp (ext:cd path)