#!/bin/sh
#
# NAME: Miniconda3
# VER: py39_4.10.3
# PLAT: linux-64
# LINES: 556
# MD5: 8d6c3d5854472e65ae4c6fd2553f244d
export OLD_LD_LIBRARY_PATH=$LD_LIBRARY_PATH
unset LD_LIBRARY_PATH
if ! echo "$0" | grep '\.sh$' > /dev/null; then
printf 'Please run using "bash" or "sh", but not "." or "source"\\n' >&2
return 1
fi
# Determine RUNNING_SHELL; if SHELL is non-zero use that.
if [ -n "$SHELL" ]; then
RUNNING_SHELL="$SHELL"
else
if [ "$(uname)" = "Darwin" ]; then
RUNNING_SHELL=/bin/bash
else
if [ -d /proc ] && [ -r /proc ] && [ -d /proc/$$ ] && [ -r /proc/$$ ] && [ -L /proc/$$/exe ] && [ -r /proc/$$/exe ]; then
RUNNING_SHELL=$(readlink /proc/$$/exe)
fi
if [ -z "$RUNNING_SHELL" ] || [ ! -f "$RUNNING_SHELL" ]; then
RUNNING_SHELL=$(ps -p $$ -o args= | sed 's|^-||')
case "$RUNNING_SHELL" in
*/*)
;;
default)
RUNNING_SHELL=$(which "$RUNNING_SHELL")
;;
esac
fi
fi
fi
# Some final fallback locations
if [ -z "$RUNNING_SHELL" ] || [ ! -f "$RUNNING_SHELL" ]; then
if [ -f /bin/bash ]; then
RUNNING_SHELL=/bin/bash
else
if [ -f /bin/sh ]; then
RUNNING_SHELL=/bin/sh
fi
fi
fi
if [ -z "$RUNNING_SHELL" ] || [ ! -f "$RUNNING_SHELL" ]; then
printf 'Unable to determine your shell. Please set the SHELL env. var and re-run\\n' >&2
exit 1
fi
THIS_DIR=$(DIRNAME=$(dirname "$0"); cd "$DIRNAME"; pwd)
THIS_FILE=$(basename "$0")
THIS_PATH="$THIS_DIR/$THIS_FILE"
PREFIX=$HOME/miniconda3
BATCH=0
FORCE=0
SKIP_SCRIPTS=0
TEST=0
REINSTALL=0
USAGE="
usage: $0 [options]
Installs Miniconda3 py39_4.10.3
-b run install in batch mode (without manual intervention),
it is expected the license terms are agreed upon
-f no error if install prefix already exists
-h print this help message and exit
-p PREFIX install prefix, defaults to $PREFIX, must not contain spaces.
-s skip running pre/post-link/install scripts
-u update an existing installation
-t run package tests after installation (may install conda-build)
"
if which getopt > /dev/null 2>&1; then
OPTS=$(getopt bfhp:sut "$*" 2>/dev/null)
if [ ! $? ]; then
printf "%s\\n" "$USAGE"
exit 2
fi
eval set -- "$OPTS"
while true; do
case "$1" in
-h)
printf "%s\\n" "$USAGE"
exit 2
;;
-b)
BATCH=1
shift
;;
-f)
FORCE=1
shift
;;
-p)
PREFIX="$2"
shift
shift
;;
-s)
SKIP_SCRIPTS=1
shift
;;
-u)
FORCE=1
shift
;;
-t)
TEST=1
shift
;;
--)
shift
break
;;
*)
printf "ERROR: did not recognize option '%s', please try -h\\n" "$1"
exit 1
;;
esac
done
else
while getopts "bfhp:sut" x; do
case "$x" in
h)
printf "%s\\n" "$USAGE"
exit 2
;;
b)
BATCH=1
;;
f)
FORCE=1
;;
p)
PREFIX="$OPTARG"
;;
s)
SKIP_SCRIPTS=1
;;
u)
FORCE=1
;;
t)
TEST=1
;;
?)
printf "ERROR: did not recognize option '%s', please try -h\\n" "$x"
exit 1
;;
esac
done
fi
if [ "$BATCH" = "0" ] # interactive mode
then
if [ "$(uname -m)" != "x86_64" ]; then
printf "WARNING:\\n"
printf " Your operating system appears not to be 64-bit, but you are trying to\\n"
printf " install a 64-bit version of Miniconda3.\\n"
printf " Are sure you want to continue the installation? [yes|no]\\n"
printf "[no] >>> "
read -r ans
if [ "$ans" != "yes" ] && [ "$ans" != "Yes" ] && [ "$ans" != "YES" ] && \
[ "$ans" != "y" ] && [ "$ans" != "Y" ]
then
printf "Aborting installation\\n"
exit 2
fi
fi
if [ "$(uname)" != "Linux" ]; then
printf "WARNING:\\n"
printf " Your operating system does not appear to be Linux, \\n"
printf " but you are trying to install a Linux version of Miniconda3.\\n"
printf " Are sure you want to continue the installation? [yes|no]\\n"
printf "[no] >>> "
read -r ans
if [ "$ans" != "yes" ] && [ "$ans" != "Yes" ] && [ "$ans" != "YES" ] && \
[ "$ans" != "y" ] && [ "$ans" != "Y" ]
then
printf "Aborting installation\\n"
exit 2
fi
fi
printf "\\n"
printf "Welcome to Miniconda3 py39_4.10.3\\n"
printf "\\n"
printf "In order to continue the installation process, please review the license\\n"
printf "agreement.\\n"
printf "Please, press ENTER to continue\\n"
printf ">>> "
read -r dummy
pager="cat"
if command -v "more" > /dev/null 2>&1; then
pager="more"
fi
"$pager" <<EOF
===================================
End User License Agreement - Miniconda
===================================
Copyright 2015-2021, Anaconda, Inc.
All rights reserved under the 3-clause BSD License:
This End User License Agreement (the "Agreement") is a legal agreement between you and Anaconda, Inc. ("Anaconda") and governs your use of Miniconda.
Subject to the terms of this Agreement, Anaconda hereby grants you a non-exclusive, non-transferable license to:
* Install and use the Miniconda.
* Modify and create derivative works of sample source code delivered in Miniconda subject to the Terms of Service for the Repository (as defined hereinafter) available at https://www.anaconda.com/terms-of-service, and
* Redistribute code files in source (if provided to you by Anaconda as source) and binary forms, with or without modification subject to the requirements set forth below.
Anaconda may, at its option, make available patches, workarounds or other updates to Miniconda. Unless the updates are provided with their separate governing terms, they are deemed part of Miniconda licensed to you as provided in this Agreement. This Agreement does not entitle you to any support for Miniconda.
Anaconda reserves all rights not expressly granted to you in this Agreement.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
* Neither the name of Anaconda nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
You acknowledge that, as between you and Anaconda, Anaconda owns all right, title, and interest, including all intellectual property rights, in and to Miniconda and, with respect to third-party products distributed with or through Miniconda, the applicable third-party licensors own all right, title and interest, including all intellectual property rights, in and to such products. If you send or transmit any communicatio