raco¶
- ID
raco- Home page
- Platforms
🐧 Linux · 🍎 macOS · 🪟 Windows
- Operations
installed·install·upgrade·upgrade_all·remove- purl types
pkg:raco- CLI name
raco- Issues and PRs
- Source
Bundled package-manager definition shipped with mpm.
raco is Racket’s command-line
tool, whose pkg subcommand tree is the package manager for the Racket
catalog.
Parsing notes, verified against Racket v9.3 on macOS:
raco reports no version of its own:
raco --versionis refused outright with “A flag must follow a command”. raco ships with Racket and is versioned with it, so the probe reads the interpreter beside it.The listing forces
--alland--long, and both are load-bearing. Without--allraco hides auto-installed packages behind a summary line, “[1 auto-installed package not shown]”, so an inventory would silently omit every dependency pulled in on the user’s behalf. Without--longthe checksum column is truncated with an ellipsis, which would report a mangled version rather than none at all.Versions are the 40-character checksums raco pins each package to; the catalog publishes no release numbers, so the checksum is the identity. Anchoring the pattern on forty hex characters is also what makes it skip the column header, the
[none]placeholder of an empty scope and the two scope banners, none of which a line-count-based skip would survive if Racket reordered them.An auto-installed package is flagged with a trailing
*on its name, which the pattern strips so the id round-trips intoinstallandremove.Both scopes are listed at once, the installation-wide tree and the user-specific one, which together are what the machine holds.
installandupdateforce--auto. Their default dependency mode issearch-ask, which “asks for permission to auto-install” and would hang mpm’s non-interactive subprocess;--autois the documented shorthand for--deps search-auto, the same resolution without the prompt.No search:
raco pkghas no catalog query verb.
What mpm adds to raco¶
mpm reaches across every manager at once, not raco alone: mpm installed and mpm outdated cover raco alongside every other manager you run in one table, mpm upgrade --all updates them together, and mpm sbom exports the whole machine as one bill of materials.
Every mpm command also gains --dry-run and --plan previews, cross-scheme version comparison and purl identifiers. See manager augmentations for how each one is built.
Your raco commands, in mpm¶
You already know raco: each operation maps one-to-one onto mpm, in an interface shared by every manager.
To… |
With |
With |
|---|---|---|
List what’s installed |
|
|
Install a package |
|
|
Upgrade one package |
|
|
Upgrade everything |
|
|
Remove a package |
|
|
Prefix any command above with --dry-run to simulate the underlying manager calls without touching the system: the safe way to watch what mpm would do before trusting it.
Operations¶
Operation |
Supported |
|---|---|
|
✓ |
|
|
|
|
|
|
|
✓ |
|
✓ |
|
✓ |
|
✓ |
|
|
|
|
|
Selecting and configuring raco¶
Deselect raco for a single run with --no-raco, or persist the choice in your configuration:
[mpm]
raco = false
Keep it enabled but tune how mpm drives it with a per-manager override:
[mpm.managers.raco]
timeout = 900
mpm config-template raco prints every overridable attribute as a ready-to-paste block.
Recipes¶
A few jobs you would otherwise script around raco, one mpm command each:
Snapshot and clone a machine:
mpm --raco dump raco.toml, thenmpm restore raco.tomlon the next one.Export a compliance SBOM:
mpm --raco sbom(CycloneDX by default,--spdxfor SPDX).
Privilege escalation¶
mpm runs this manager as the current user and never prepends sudo by default. Flip the policy for its privileged operations with --sudo or the per-manager sudo override.
None of its operations needs root.
See privilege escalation for the full policy.
Cooldown¶
State of raco’s release-age gating, from the cooldown support table:
Status: ❌ None
A cooldown only pays off where a compromised release can be withdrawn while the clock runs, and can only be emulated where the registry dates its releases. From the retraction table:
Registry: Racket package catalog
Retraction: Index revert: pkgs.racket-lang.org maps a package name to a source checkout and a checksum rather than hosting the code, so withdrawal is the catalog entry being removed or repointed; the source repository it names can also vanish underneath it
Publish date: ❌ a package is pinned by the 40-character checksum of its source rather than by a release number, and the catalog publishes no upload date the client can read
With --cooldown set, mpm skips this manager’s install and upgrade operations rather than run them unguarded (fail-closed); --allow-unsupported-managers opts back in.
Version probe¶
The version is probed by running:
$ racket --version
Welcome to Racket v9.3 [cs].
and extracted with:
r"Racket v(?P<version>\S+)"
Reference traces¶
Raw native outputs captured in the bundled definition: the reference mpm’s parsers were written against. If you know raco well and a transcript below looks wrong, or a newer release changed its output format, report it.
$ raco pkg show --all --long
Installation-wide:
Package[*=auto] Checksum Source
base* 6272bda442d1c26a40d2403a251665d500147ab3 (catalog "base")
racket-aarch64-macosx-4 4c09d8fd50131e48edb3d5a5e95016ca31435da0 (catalog "racket-aarch64-macosx-4")
racket-lib 62eb15ddc03bc26a1c0f85c8aff03aa6ef7a518a (catalog "racket-lib")
User-specific for installation "9.3":
[none]
Feed any of these through mpm and the raw output becomes one uniform table, the same shape for every manager: filter it, project columns, or export it (mpm --raco installed --output json, or csv, toml, yaml), each package carrying a purl and a version comparable across managers.
Changelog¶
8.0.0.dev0(unreleased)Add Racket’s
raco pkgas a bundled definition, withinstalled,install,removeandupgradesupport. The listing forces--all, without which auto-installed packages are hidden behind a summary line, and--long, without which the checksum standing in for a version is truncated. Mutating operations force--auto, their default dependency mode asking for permission interactively.