-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathupstream-misc.lisp
64 lines (46 loc) · 2.03 KB
/
upstream-misc.lisp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
;;;; upstream-misc.lisp
(in-package #:quicklisp-controller)
(defclass location-templated-source (upstream-source)
((location-template
:initarg :location-template
:accessor location-template)))
(defmethod location ((source location-templated-source))
(format nil (location-template source) (project-name source)))
(defclass predictable-http-source (location-templated-source http-source)
())
(defclass ediware-http-source (git-source location-templated-source) ()
(:default-initargs
:location-template "https://github.com/edicl/~A.git"))
(defclass froydware-http-source (predictable-http-source) ()
(:default-initargs
:location-template "http://method-combination.net/lisp/files/~A.tar.gz"))
(defclass svcware-http-source (predictable-http-source) ()
(:default-initargs
:location-template "http://homepage.mac.com/svc/~A/~:*~A.tar.gz"))
(defclass predictable-darcs-source (location-templated-source darcs-source)
())
(defclass hungarian-darcs-source (predictable-darcs-source) ()
(:default-initargs
:location-template "http://dwim.hu/darcs/~A"))
(defclass clnet-darcs-source (predictable-darcs-source) ()
(:default-initargs
:location-template "http://common-lisp.net/project/~A/darcs/~:*~A"))
(defclass kmr-git-source (location-templated-source git-source) ()
(:default-initargs
:location-template "http://git.kpe.io/~A.git"))
;;; Walter C. Pelissero
;;; http://wcp.sdf-eu.org/
(defclass wcpware-http-source (http-source) ())
(defmethod make-release-tarball ((source wcpware-http-source) output-file)
"WCP's projects are bzip2 archives that unpack into the current
directory. Fix them up to be tarballs with predictable output
directories."
(let ((prefix (release-tarball-prefix source))
(cached (ensure-source-cache source)))
(in-temporary-directory prefix
(sb-posix:mkdir prefix #o755)
(with-posix-cwd prefix
(run "tar" "xjvf" cached))
(run "tar" :owner 0 :group 0 "-cvf" "wcp.tar" prefix)
(run "gzip" "-vn9" "wcp.tar")
(copy "wcp.tar.gz" output-file))))