Add code to install env-shared.
This commit is contained in:
21
setup.sh
21
setup.sh
@@ -9,6 +9,7 @@ cd $DIR
|
|||||||
DIR="`pwd`"
|
DIR="`pwd`"
|
||||||
echo "Working in '$DIR'."
|
echo "Working in '$DIR'."
|
||||||
|
|
||||||
|
|
||||||
if [[ $1 == "skip" ]]; then
|
if [[ $1 == "skip" ]]; then
|
||||||
echo "\n`date` - Skipping Updates"
|
echo "\n`date` - Skipping Updates"
|
||||||
else
|
else
|
||||||
@@ -17,6 +18,7 @@ else
|
|||||||
pkg upgrade -y
|
pkg upgrade -y
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
echo -e "\n`date` - Check Storage Permission"
|
echo -e "\n`date` - Check Storage Permission"
|
||||||
|
|
||||||
if [[ ! -e ~/storage/shared ]]; then
|
if [[ ! -e ~/storage/shared ]]; then
|
||||||
@@ -32,6 +34,7 @@ else
|
|||||||
echo "Everything looks good already, pal."
|
echo "Everything looks good already, pal."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
if [[ $1 == "skip" ]]; then
|
if [[ $1 == "skip" ]]; then
|
||||||
echo "\n`date` - Skipping Installs"
|
echo "\n`date` - Skipping Installs"
|
||||||
else
|
else
|
||||||
@@ -43,6 +46,7 @@ else
|
|||||||
kotlin php nodejs python libllvm hugo
|
kotlin php nodejs python libllvm hugo
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
echo -e "\n`date` - BASH Environment"
|
echo -e "\n`date` - BASH Environment"
|
||||||
|
|
||||||
if [[ ! -e ~/.env ]]; then
|
if [[ ! -e ~/.env ]]; then
|
||||||
@@ -62,7 +66,8 @@ else
|
|||||||
echo "ERROR: bashrc.sh not found, skipping." >&2
|
echo "ERROR: bashrc.sh not found, skipping." >&2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "\n`date` - Directoriee"
|
|
||||||
|
echo -e "\n`date` - Directories"
|
||||||
|
|
||||||
if [[ -d ~/TRASH ]]; then
|
if [[ -d ~/TRASH ]]; then
|
||||||
rm -rfv ~/TRASH
|
rm -rfv ~/TRASH
|
||||||
@@ -77,6 +82,19 @@ if [[ ! -d ~/Code && ! -d ~/storage/shared/Code ]]; then
|
|||||||
ln -s ~/Code ~/storage/shared/Code
|
ln -s ~/Code ~/storage/shared/Code
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
echo -e "\n`date` - env-shared"
|
||||||
|
|
||||||
|
env_shared_dir="env-shared-dev-deleteme"
|
||||||
|
git clone https://git.hyperling.com/me/env-shared \
|
||||||
|
--branch=dev ~/$env_shared_dir
|
||||||
|
cp -v ~/$env_shared_dir/rc_shared.sh ~/.rc_shared
|
||||||
|
if [[ ! -d ~/bin ]]; then
|
||||||
|
mkdir -pv ~/bin
|
||||||
|
fi
|
||||||
|
cp -v ~/$env_shared_dir/bin-shared/* ~/bin/
|
||||||
|
|
||||||
|
|
||||||
echo -e "\n`date` - Cleanup"
|
echo -e "\n`date` - Cleanup"
|
||||||
|
|
||||||
if [[ -n $DIR && $DIR != "/" && $DIR == *"deleteme" && -d .git ]]; then
|
if [[ -n $DIR && $DIR != "/" && $DIR == *"deleteme" && -d .git ]]; then
|
||||||
@@ -89,6 +107,7 @@ else
|
|||||||
mv "$PROG" ~/TRASH/
|
mv "$PROG" ~/TRASH/
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
echo -e "\n*******"
|
echo -e "\n*******"
|
||||||
echo "Don't forget to reload your environment!"
|
echo "Don't forget to reload your environment!"
|
||||||
echo " source ~/.bashrc"
|
echo " source ~/.bashrc"
|
||||||
|
|||||||
Reference in New Issue
Block a user