mirror of
https://github.com/webinstall/webi-installers.git
synced 2026-02-14 17:49:53 +00:00
fix: replace 'uname -a' with 'uname -srm' for OS/Arch detection
This commit is contained in:
@@ -15,7 +15,7 @@ __install_webi() {
|
||||
export WEBI_HOST
|
||||
|
||||
echo ""
|
||||
printf "Thanks for using webi to install '\e[32m%s\e[0m' on '\e[31m%s/%s\e[0m'.\n" "${WEBI_PKG-}" "$(uname -s)" "$(uname -m)"
|
||||
printf "Thanks for using webi to install '\e[32m%s\e[0m' on '\e[31m%s/%s\e[0m'.\n" "${WEBI_PKG-}" "$(uname -s)/$(uname -r)" "$(uname -m)"
|
||||
echo "Have a problem? Experience a bug? Please let us know:"
|
||||
echo " https://github.com/webinstall/webi-installers/issues"
|
||||
echo ""
|
||||
@@ -93,7 +93,7 @@ __webi_main() {
|
||||
set -e
|
||||
|
||||
export WEBI_HOST="\${WEBI_HOST:-https://webinstall.dev}"
|
||||
export WEBI_UA="\$(uname -a)"
|
||||
export WEBI_UA="\$(uname -s)/\$(uname -r) \$(uname -m)/unknown"
|
||||
|
||||
|
||||
webinstall() {
|
||||
@@ -220,7 +220,7 @@ EOF
|
||||
echo ""
|
||||
echo "Hmm... no WEBI_PKG was specified. This is probably an error in the script."
|
||||
echo ""
|
||||
echo "Please open an issue with this information: Package '${WEBI_PKG-}' on '$(uname -s)/$(uname -m)'"
|
||||
echo "Please open an issue with this information: Package '${WEBI_PKG-}' on '$(uname -s)/$(uname -r) $(uname -m)'"
|
||||
echo " https://github.com/webinstall/packages/issues"
|
||||
echo ""
|
||||
fi
|
||||
|
||||
@@ -30,7 +30,7 @@ __bootstrap_webi() {
|
||||
#PKG_OSES=
|
||||
#PKG_ARCHES=
|
||||
#PKG_FORMATS=
|
||||
WEBI_UA="$(uname -a)"
|
||||
WEBI_UA="$(uname -s)/$(uname -r) $(uname -m)/unknown"
|
||||
WEBI_PKG_DOWNLOAD=""
|
||||
WEBI_DOWNLOAD_DIR="${HOME}/Downloads"
|
||||
if command -v xdg-user-dir > /dev/null; then
|
||||
|
||||
@@ -16,7 +16,7 @@ function getRequest(req) {
|
||||
}
|
||||
|
||||
return {
|
||||
unix: 'curl -fsSA "$(uname -a)" ' + url,
|
||||
unix: 'curl -fsSA "$(uname -srm)" ' + url,
|
||||
windows: 'curl.exe -fsSA "MS $Env:PROCESSOR_ARCHITECTURE" ' + url,
|
||||
ua: ua,
|
||||
os: uaDetect.os(ua),
|
||||
|
||||
@@ -7,7 +7,7 @@ _install_brew() {
|
||||
# Straight from https://brew.sh
|
||||
#/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
|
||||
|
||||
if uname -a | grep -q -i darwin; then
|
||||
if [ "Darwin" = "$(uname -s)" ]; then
|
||||
needs_xcode="$(/usr/bin/xcode-select -p > /dev/null 2> /dev/null || echo "true")"
|
||||
if [ -n "${needs_xcode}" ]; then
|
||||
echo ""
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
set -e
|
||||
set -u
|
||||
|
||||
if ! (uname -a | grep -i "darwin" > /dev/null); then
|
||||
if [ "Darwin" != "$(uname -s)" ]; then
|
||||
echo "No fish installer for Linux yet. Try this instead:"
|
||||
echo " sudo apt install -y fish"
|
||||
exit 1
|
||||
|
||||
@@ -5,7 +5,7 @@ set -u
|
||||
__init_git() {
|
||||
|
||||
if [ -z "$(command -v git)" ]; then
|
||||
if uname -a | grep -q -i darwin; then
|
||||
if [ "Darwin" = "$(uname -s)" ]; then
|
||||
echo >&2 "Error: 'git' not found. You may have to re-install 'git' on Mac after every major update."
|
||||
echo >&2 " for example, try: xcode-select --install"
|
||||
# sudo xcodebuild -license accept
|
||||
|
||||
@@ -4,7 +4,7 @@ set -e
|
||||
set -u
|
||||
|
||||
_install_gpg() {
|
||||
if ! (uname -a | grep -i "darwin" > /dev/null); then
|
||||
if [ "Darwin" != "$(uname -s)" ]; then
|
||||
echo "No gpg installer for Linux yet. Try this instead:"
|
||||
echo " sudo apt install -y gpg gnupg"
|
||||
exit 1
|
||||
|
||||
Reference in New Issue
Block a user