fixup for showing dependencies during update

This commit is contained in:
Matthew Flatt 2013-09-17 13:07:39 -06:00
parent ad437eee46
commit 10a931d688
2 changed files with 9 additions and 5 deletions

View File

@ -108,7 +108,7 @@
$ "racket -e '(require pkg-test2)'" =exit> 1
$ "raco pkg install --deps search-auto test-pkgs/pkg-test2.zip"
=exit> 0
=stdout> "Resolving \"pkg-test1\" via http://localhost:9990\nDownloading checksum for pkg-test1\nDownloading http://localhost:9999/pkg-test1.zip\nThe following uninstalled packages were listed as dependencies\nand they were automatically installed:\ndependencies of pkg-test2:\n pkg-test1\n"
=stdout> "Resolving \"pkg-test1\" via http://localhost:9990\nDownloading checksum for pkg-test1\nDownloading http://localhost:9999/pkg-test1.zip\nThe following uninstalled packages were listed as dependencies\nand they were automatically installed:\n dependencies of pkg-test2:\n pkg-test1\n"
=stderr> ""
$ "racket -e '(require pkg-test2)'" =exit> 0
$ "racket -e '(require pkg-test2/contains-dep)'" =exit> 0

View File

@ -1220,12 +1220,16 @@
(define (format-deps update-deps)
(format-list (for/list ([ud (in-list update-deps)])
(if (pkg-desc? ud)
(pkg-desc-name ud)
(cond
[(pkg-desc? ud)
(pkg-desc-name ud)]
[(string? ud)
ud]
[else
(format "~a (have ~a, need ~a)"
(car ud)
(caddr ud)
(cadddr ud))))))
(cadddr ud))]))))
(define (install-packages
#:old-infos old-infos
@ -1799,7 +1803,7 @@
(string-append*
(for/list ([p*ds (in-list summary-deps)])
(match-define (vector n ds) p*ds)
(format "\ndependencies of ~a:~a"
(format "\n dependencies of ~a:~a"
n
(if updating?
(format-deps ds)