For example, the main Racket development repository includes a "pkgs" directory that holds packages such as base, and create-dirs-catalog constructs a catalog to be used to install those packages.
When run directly as a program, pkg/dirs-catalog expects a destination catalog followed by any number paths for directories that hold packages:
racket -l- pkg/dirs-catalog ‹dest-catalog› ‹dir› ...
The --link, --merge, --check-metadata, and --quiet flags correspond to optional keyword arguments of create-dirs-catalog.
Added in version 220.127.116.11 of package base.
(create-dirs-catalog catalog-path dirs [ #:link? link? #:merge? merge? #:check-metadata? check-metadata? #:status-printf status-printf]) → void? catalog-path : path-string? dirs : (listof path-string?) link? : any/c = #f merge? : any/c = #f check-metadata? : any/c = #f status-printf : (string? any/c ... -> void?) = void
If link? is true, then the catalog specifies that the package should be installed as a directory link, as opposed to copies.
If merge? is true, then existing catalog entries in catalog-path are preserved, otherwise old catalog entries are removed.
To create author and description information for each package in the catalog, create-dirs-catalog looks for a pkg-authors and pkg-desc definition in each package’s "info.rkt" file. If either definition is missing and check-metadata? is true, an error is reported.