Skip to content

Commit 666c257

Browse files
authored
Merge pull request Azure#285 from jeff-shepherd/master
Corrected line termination for automl_setup_mac.sh
2 parents ea1b759 + 5af3aa4 commit 666c257

File tree

1 file changed

+55
-55
lines changed

1 file changed

+55
-55
lines changed
Lines changed: 55 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -1,55 +1,55 @@
1-
#!/bin/bash
2-
3-
CONDA_ENV_NAME=$1
4-
AUTOML_ENV_FILE=$2
5-
OPTIONS=$3
6-
PIP_NO_WARN_SCRIPT_LOCATION=0
7-
8-
if [ "$CONDA_ENV_NAME" == "" ]
9-
then
10-
CONDA_ENV_NAME="azure_automl"
11-
fi
12-
13-
if [ "$AUTOML_ENV_FILE" == "" ]
14-
then
15-
AUTOML_ENV_FILE="automl_env_mac.yml"
16-
fi
17-
18-
if [ ! -f $AUTOML_ENV_FILE ]; then
19-
echo "File $AUTOML_ENV_FILE not found"
20-
exit 1
21-
fi
22-
23-
if source activate $CONDA_ENV_NAME 2> /dev/null
24-
then
25-
echo "Upgrading azureml-sdk[automl,notebooks,explain] in existing conda environment" $CONDA_ENV_NAME
26-
pip install --upgrade azureml-sdk[automl,notebooks,explain] &&
27-
jupyter nbextension uninstall --user --py azureml.widgets
28-
else
29-
conda env create -f $AUTOML_ENV_FILE -n $CONDA_ENV_NAME &&
30-
source activate $CONDA_ENV_NAME &&
31-
conda install lightgbm -c conda-forge -y &&
32-
python -m ipykernel install --user --name $CONDA_ENV_NAME --display-name "Python ($CONDA_ENV_NAME)" &&
33-
jupyter nbextension uninstall --user --py azureml.widgets &&
34-
pip install numpy==1.15.3 &&
35-
echo "" &&
36-
echo "" &&
37-
echo "***************************************" &&
38-
echo "* AutoML setup completed successfully *" &&
39-
echo "***************************************" &&
40-
if [ "$OPTIONS" != "nolaunch" ]
41-
then
42-
echo "" &&
43-
echo "Starting jupyter notebook - please run the configuration notebook" &&
44-
echo "" &&
45-
jupyter notebook --log-level=50 --notebook-dir '../..'
46-
fi
47-
fi
48-
49-
if [ $? -gt 0 ]
50-
then
51-
echo "Installation failed"
52-
fi
53-
54-
55-
1+
#!/bin/bash
2+
3+
CONDA_ENV_NAME=$1
4+
AUTOML_ENV_FILE=$2
5+
OPTIONS=$3
6+
PIP_NO_WARN_SCRIPT_LOCATION=0
7+
8+
if [ "$CONDA_ENV_NAME" == "" ]
9+
then
10+
CONDA_ENV_NAME="azure_automl"
11+
fi
12+
13+
if [ "$AUTOML_ENV_FILE" == "" ]
14+
then
15+
AUTOML_ENV_FILE="automl_env_mac.yml"
16+
fi
17+
18+
if [ ! -f $AUTOML_ENV_FILE ]; then
19+
echo "File $AUTOML_ENV_FILE not found"
20+
exit 1
21+
fi
22+
23+
if source activate $CONDA_ENV_NAME 2> /dev/null
24+
then
25+
echo "Upgrading azureml-sdk[automl,notebooks,explain] in existing conda environment" $CONDA_ENV_NAME
26+
pip install --upgrade azureml-sdk[automl,notebooks,explain] &&
27+
jupyter nbextension uninstall --user --py azureml.widgets
28+
else
29+
conda env create -f $AUTOML_ENV_FILE -n $CONDA_ENV_NAME &&
30+
source activate $CONDA_ENV_NAME &&
31+
conda install lightgbm -c conda-forge -y &&
32+
python -m ipykernel install --user --name $CONDA_ENV_NAME --display-name "Python ($CONDA_ENV_NAME)" &&
33+
jupyter nbextension uninstall --user --py azureml.widgets &&
34+
pip install numpy==1.15.3 &&
35+
echo "" &&
36+
echo "" &&
37+
echo "***************************************" &&
38+
echo "* AutoML setup completed successfully *" &&
39+
echo "***************************************" &&
40+
if [ "$OPTIONS" != "nolaunch" ]
41+
then
42+
echo "" &&
43+
echo "Starting jupyter notebook - please run the configuration notebook" &&
44+
echo "" &&
45+
jupyter notebook --log-level=50 --notebook-dir '../..'
46+
fi
47+
fi
48+
49+
if [ $? -gt 0 ]
50+
then
51+
echo "Installation failed"
52+
fi
53+
54+
55+

0 commit comments

Comments
 (0)