install.sh
Shell command-substitution syntaxLaunches shell with forwarded script arguments
SHA-2563646b9ea59993c211335a09604b30b6aef43fd5b176e4ea657d80e3b43f944a4
MaleculeH₂(Cm₆Po₃)Md(Pa)
Evidence
1#!/bin/sh
2# Copyright 2026 Antfly, Inc.
3# SPDX-License-Identifier: Apache-2.0
4#
5# Licensed under the Apache License, Version 2.0 (the "License");
6# you may not use this file except in compliance with the License.
7# You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing, software
12# distributed under the License is distributed on an "AS IS" BASIS,
13# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14# See the License for the specific language governing permissions and
15# limitations under the License.
16
17# Stable channel bootstrap. Keep this compatible with every published
18# metadata.json version and delegate release-specific behavior to the immutable
19# installer stored with that release.
20set -eu
21
22BASE_URL="${ANTFLY_RELEASES_URL:-https://releases.antfly.io/antfly}"
23REQUESTED_VERSION="${1:-latest}"
24
25case "$REQUESTED_VERSION" in
26 latest|-h|--help)
27 METADATA=$(curl -fsSL "$BASE_URL/latest/metadata.json")
28 TAG=$(printf '%s' "$METADATA" | sed -n 's/.*"tag":"\([^"]*\)".*/\1/p')
29 ;;
30 v*) TAG="$REQUESTED_VERSION" ;;
⋯5 lines
36 *)
37 echo "ERROR: Could not resolve a valid Antfly release tag" >&2
38 exit 1
39 ;;
40esac
⋯5 lines
46esac
47
48TEMP_DIR=$(mktemp -d)