safe_rel (rebar_safe v1.0.1)
View SourceSummary
Functions
Compute SHA256 checksum of binary data, returns lowercase hex binary.
Download specific SAFE version with checksum verification.
Fetch available versions from S3 manifest. The versions.json format is: {"1.0.0": {"macos-x86_64": "sha256", "linux-x86_64": "sha256"}, ...}
Get latest version satisfying a constraint, optionally including prereleases. Constraint format: <<"~> 1.3">> (>= 1.3.0, < 2.0.0) or <<"~> 1.3.1">> (>= 1.3.1, < 1.4.0)
Get path to safe binary
Sort versions descending (highest first) using semver comparison.
Verify checksum matches expected value (case-insensitive, trimmed).
Functions
Compute SHA256 checksum of binary data, returns lowercase hex binary.
-spec detect_arch() -> string().
-spec detect_os() -> string().
Download specific SAFE version with checksum verification.
Fetch available versions from S3 manifest. The versions.json format is: {"1.0.0": {"macos-x86_64": "sha256", "linux-x86_64": "sha256"}, ...}
-spec get_latest_compatible_version(Constraint :: binary()) -> {ok, binary(), map()} | {error, term()}.
Get latest version satisfying a constraint, optionally including prereleases. Constraint format: <<"~> 1.3">> (>= 1.3.0, < 2.0.0) or <<"~> 1.3.1">> (>= 1.3.1, < 1.4.0)
Get path to safe binary
Sort versions descending (highest first) using semver comparison.
Verify checksum matches expected value (case-insensitive, trimmed).