mirror of
https://github.com/coder/code-server.git
synced 2024-12-29 04:34:00 +03:00
b978655c07
* refactor: get version dynamically * chore: remove version * fixup: missing quotes * refactor: drop global VERSION * wip: updating ersion in publish * refactor: update publish.yaml with version changes * refactor: release.yaml with new version changes * refactor: update build.yaml with version changes * chore: update maintainer * fixup: update version in build-vscode * fixup: fix github env version * try macos only * try again * last resort * joe again * this oneee * fixup: this should work * try using inputs * docs: update release notes * fixup!: use env.VERSION in docker step * fixup!: comment get and set version * fixup!: remove compress release package comment * fixup!: use $VERSION in npm-version * refactor: set VERSION in build VS Code step * refactor: use 0.0.0 in package.json version * refactor: delete release-prep script * Update ci/build/build-vscode.sh * fixup!: remove extra VERSION set in aur
55 lines
1.1 KiB
Bash
Executable File
55 lines
1.1 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
pushd() {
|
|
builtin pushd "$@" > /dev/null
|
|
}
|
|
|
|
popd() {
|
|
builtin popd > /dev/null
|
|
}
|
|
|
|
vscode_version() {
|
|
jq -r .version lib/vscode/package.json
|
|
}
|
|
|
|
os() {
|
|
osname=$(uname | tr '[:upper:]' '[:lower:]')
|
|
case $osname in
|
|
linux)
|
|
# Alpine's ldd doesn't have a version flag but if you use an invalid flag
|
|
# (like --version) it outputs the version to stderr and exits with 1.
|
|
# TODO: Better to check /etc/os-release; see ../install.sh.
|
|
ldd_output=$(ldd --version 2>&1 || true)
|
|
if echo "$ldd_output" | grep -iq musl; then
|
|
osname="alpine"
|
|
fi
|
|
;;
|
|
darwin) osname="macos" ;;
|
|
cygwin* | mingw*) osname="windows" ;;
|
|
esac
|
|
echo "$osname"
|
|
}
|
|
|
|
arch() {
|
|
cpu="$(uname -m)"
|
|
case "$cpu" in
|
|
aarch64) cpu=arm64 ;;
|
|
x86_64) cpu=amd64 ;;
|
|
esac
|
|
echo "$cpu"
|
|
}
|
|
|
|
rsync() {
|
|
command rsync -a --del "$@"
|
|
}
|
|
|
|
ARCH="$(arch)"
|
|
export ARCH
|
|
OS=$(os)
|
|
export OS
|
|
|
|
# RELEASE_PATH is the destination directory for the release from the root.
|
|
# Defaults to release
|
|
RELEASE_PATH="${RELEASE_PATH-release}"
|