Skip to content

Deduplicate install.ab boilerplate into a shared helper #36

Description

@NicoVIII

The five src/*/install.ab files are ~90% identical: read the VERSION param, ensure packages (plus jq/curl for latest), resolve the latest version, set up a temp dir, download/verify/extract/install, clean up. Only the artifact filename/URL templates and a few package extras differ.

A shared helper in lib/ (taking e.g. binary name, resolved version, download URL, and an optional checksum source) would collapse each feature to a short config + call, and prevent the drift that already happened (gleam gained checksum verification while just didn't, see the checksum issue).

Related: PR #33 already consolidates the latest-version lookup — this issue is the same idea applied to the rest of the install flow, and should build on top of it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    foundationFoundation work which e.g. improves DX or code quality

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions