ambevar-dotfiles/.config/guix/profile-to-manifest.scm

22 lines
756 B
Scheme

;; Run with:
;; guile -s FILE ~/.guix-profile
(use-modules (guix profiles)
(ice-9 match)
(ice-9 pretty-print))
(match (command-line)
((_ where)
(pretty-print
`(specifications->manifest
',(sort (map (lambda (entry)
(let ((out (manifest-entry-output entry)))
(if (string= out "out")
(manifest-entry-name entry)
(format #f "~a:~a"
(manifest-entry-name entry)
(manifest-entry-output entry)))))
(manifest-entries (profile-manifest where)))
string<?))))
(_ (error "Please provide the path to a Guix profile.")))