mirror of
https://github.com/roswell/roswell.git
synced 2026-09-10 07:16:17 -04:00
install quicklisp to env.
This commit is contained in:
parent
9993015b04
commit
fffb81f709
|
|
@ -12,12 +12,15 @@ exec ros +R +Q -m roswell -N roswell -- $0 "$@"
|
|||
(in-package :ros.script.config.3668210854)
|
||||
|
||||
(defun main (&rest argv)
|
||||
(let* ((path (cond ((and (equal (first argv) "--env")
|
||||
(roswell:opt "roswellenv"))
|
||||
(setf argv (cdr argv))
|
||||
(merge-pathnames (format nil "env/~A/config"
|
||||
(roswell:opt "roswellenv"))
|
||||
(roswell:opt "homedir")))
|
||||
(let* ((path (cond ((equal (first argv) "--env")
|
||||
(prog1
|
||||
(merge-pathnames (format nil "env/~A/config"
|
||||
(or (roswell:opt "*roswellenv")
|
||||
(third (assoc "roswellenv"
|
||||
(load-config ".roswellenv")
|
||||
:test 'equal))))
|
||||
(roswell:opt "homedir"))
|
||||
(setf argv (cdr argv))))
|
||||
((equal (first argv) "--local")
|
||||
(setf argv (cdr argv))
|
||||
".roswellenv")
|
||||
|
|
|
|||
|
|
@ -39,8 +39,13 @@
|
|||
(sb-posix:setgid (parse-integer gid)))
|
||||
(let ((uid (sb-posix:getenv "SUDO_UID")))
|
||||
(sb-posix:setuid (parse-integer uid))))
|
||||
(let ((archive (opt "download.archive"))
|
||||
(path (opt "quicklisp")))
|
||||
(let*((archive (opt "download.archive"))
|
||||
(env (opt "roswellenv"))
|
||||
(path (if env
|
||||
(merge-pathnames (format nil "env/~A/lisp/quicklisp/" env) (homedir))
|
||||
(opt "quicklisp"))))
|
||||
(when env
|
||||
(setf (config "quicklisp" :where env) env))
|
||||
(quicklisp-patch path)
|
||||
(cond
|
||||
((probe-file (merge-pathnames "setup.lisp" path))
|
||||
|
|
@ -57,7 +62,7 @@
|
|||
;; use roswell to download everithing.
|
||||
(setf (fdefinition (find-symbol (string :fetch) :qlqs-http))
|
||||
(lambda (url file &key (follow-redirects t) quietly
|
||||
(maximum-redirects 10))
|
||||
(maximum-redirects 10))
|
||||
"Request URL and write the body of the response to FILE."
|
||||
(declare (ignorable url file follow-redirects quietly
|
||||
maximum-redirects))
|
||||
|
|
|
|||
|
|
@ -142,11 +142,15 @@ Example:
|
|||
(defun (setf config) (val item &key where)
|
||||
"Interface to roswell C binary."
|
||||
(roswell:roswell
|
||||
`("config" ,@(when where `(,(format nil "--~(~A~)" where)))
|
||||
,(if val "set" "unset")
|
||||
,item
|
||||
,@(when val `(,val)))
|
||||
:string t)
|
||||
`(,@(when (stringp where)
|
||||
`("-N" ,where))
|
||||
"config" ,@(cond
|
||||
((stringp where) `("--env"))
|
||||
(where `(,(format nil "--~(~A~)" where))))
|
||||
,(if val "set" "unset")
|
||||
,item
|
||||
,@(when val `(,val)))
|
||||
:string t)
|
||||
val)
|
||||
|
||||
(defun chdir (dir &optional (verbose t))
|
||||
|
|
|
|||
|
|
@ -31,7 +31,10 @@ DEF_SUBCMD(opt_take1) {
|
|||
int argc=length(arg_);
|
||||
const char* arg=cmd->name;
|
||||
if(arg && argc>1) {
|
||||
cond_printf(1,"take1:%s:%s\n",arg,firsts(nthcdr(1,arg_)));
|
||||
char* current=get_opt(arg,0);
|
||||
cond_printf(1,"take1:%s:%s,%s\n",arg,firsts(nthcdr(1,arg_)),current);
|
||||
if(current)
|
||||
set_opt(&local_opt,cat("*",arg,NULL),current);
|
||||
set_opt(&local_opt,arg,firsts(nthcdr(1,arg_)));
|
||||
return 2;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue