mirror of
https://github.com/roswell/roswell.git
synced 2026-09-10 07:16:17 -04:00
32 lines
968 B
Common Lisp
32 lines
968 B
Common Lisp
#!/bin/sh
|
|
#|-*- mode:lisp -*-|#
|
|
#|git wrapper
|
|
exec ros -Q -m roswell -N roswell -- $0 "$@"
|
|
|#
|
|
(progn ;;init forms
|
|
(ros:ensure-asdf)
|
|
(roswell:include "util"))
|
|
|
|
(defpackage :ros.script.git.3702458293
|
|
(:use :cl :roswell.util))
|
|
(in-package :ros.script.git.3702458293)
|
|
|
|
(defun main (&rest argv)
|
|
(let* ((name (pathname-name *load-pathname*)))
|
|
(roswell:exec
|
|
(cond
|
|
((equal (first argv) "clone")
|
|
(uiop:chdir (first ql:*local-project-directories*))
|
|
`(,name ,@argv))
|
|
((ql:where-is-system (first argv))
|
|
(let* ((path (make-pathname
|
|
:type nil :name nil
|
|
:defaults (ql:where-is-system (first argv)))))
|
|
(if (ignore-errors (uiop:chdir path))
|
|
`(,name ,@(rest argv))
|
|
(progn
|
|
(format t "~A not found.~%" (first argv))
|
|
(roswell:quit 1)))))
|
|
(t `(,(roswell:opt "wargv0") "help" ,name))))))
|
|
;;; vim: set ft=lisp lisp:
|