Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Make location of GNU Tar configurable #4

Merged
merged 1 commit into from

2 participants

@valeryz

No description provided.

@orivej orivej merged commit e84673f into from
@orivej
Owner

Merged and updated readme. I set licence to Unlicence (just now, unfortunately) - do you agree?

@valeryz
@orivej orivej referenced this pull request
Closed

Add dynamic binary paths #2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 25, 2012
  1. make location of GNU tar configurable

    Valeriy Zamarayev authored
This page is out of date. Refresh to see the latest.
Showing with 7 additions and 3 deletions.
  1. +2 −1  package.lisp
  2. +5 −2 quickdist.lisp
View
3  package.lisp
@@ -17,4 +17,5 @@
#:*distinfo-file-template*
#:*dist-dir-template*
#:*archive-dir-template*
- #:*archive-url-template*))
+ #:*archive-url-template*
+ #:*gnutar*))
View
7 quickdist.lisp
@@ -12,6 +12,9 @@ system-index-url: {base-url}/{name}/{version}/systems.txt
(defparameter *archive-dir-template* "{dists-dir}/{name}/archive")
(defparameter *archive-url-template* "{base-url}/{name}/archive")
+(defparameter *gnutar* "/bin/tar"
+ "Location of the GNU TAR program")
+
(defvar *template-readtable*
(let ((readtable (copy-readtable)))
(set-syntax-from-char #\} #\) readtable)
@@ -54,7 +57,7 @@ system-index-url: {base-url}/{name}/{version}/systems.txt
(defun tar-content-sha1 (path)
(let ((octets (babel-streams:with-output-to-sequence (buffer)
- (external-program:run "/bin/tar" (list "-xOf" path) :output buffer))))
+ (external-program:run *gnutar* (list "-xOf" path) :output buffer))))
(ironclad:byte-array-to-hex-string
(ironclad:digest-sequence :sha1 (copy-seq octets)))))
@@ -65,7 +68,7 @@ system-index-url: {base-url}/{name}/{version}/systems.txt
(let* ((mtime (format-date (effective-mtime source-path)))
(name (format nil "~a-~a" (last-directory source-path) mtime))
(out-path (make-pathname :name name :type "tgz" :defaults (truename destdir-path))))
- (external-program:run "/bin/tar" (list "-C" (namestring source-path) "."
+ (external-program:run *gnutar* (list "-C" (namestring source-path) "."
"-czf" (namestring out-path)
"--transform" (format nil "s#^.#~a#" name))
:output *standard-output* :error *error-output*)
Something went wrong with that request. Please try again.