summaryrefslogtreecommitdiff
path: root/guix/store.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2013-09-01 19:24:21 +0200
committerLudovic Courtès <ludo@gnu.org>2013-09-02 00:20:14 +0200
commitbf8e7fc502057c5e59f541351a2bf35d2b20e612 (patch)
tree6d3165bb998201a911b580ed7220f1a60067389e /guix/store.scm
parentd91712ee894e3bcaabc51269d292cbe77ed89530 (diff)
downloadgnu-guix-bf8e7fc502057c5e59f541351a2bf35d2b20e612.tar
gnu-guix-bf8e7fc502057c5e59f541351a2bf35d2b20e612.tar.gz
store: Add a printer for <nix-server>.
* guix/store.scm (<nix-server>): Set a printer.
Diffstat (limited to 'guix/store.scm')
-rw-r--r--guix/store.scm9
1 files changed, 9 insertions, 0 deletions
diff --git a/guix/store.scm b/guix/store.scm
index 343da91506..541c7c848f 100644
--- a/guix/store.scm
+++ b/guix/store.scm
@@ -25,6 +25,7 @@
#:use-module (rnrs io ports)
#:use-module (srfi srfi-1)
#:use-module (srfi srfi-9)
+ #:use-module (srfi srfi-9 gnu)
#:use-module (srfi srfi-26)
#:use-module (srfi srfi-34)
#:use-module (srfi srfi-35)
@@ -242,6 +243,14 @@
(ats-cache nix-server-add-to-store-cache)
(atts-cache nix-server-add-text-to-store-cache))
+(set-record-type-printer! <nix-server>
+ (lambda (obj port)
+ (format port "#<build-daemon ~a.~a ~a>"
+ (nix-server-major-version obj)
+ (nix-server-minor-version obj)
+ (number->string (object-address obj)
+ 16))))
+
(define-condition-type &nix-error &error
nix-error?)