mirror of
https://github.com/aquatix/dotfiles.git
synced 2025-12-06 21:45:10 +01:00
Check for ~/.dot_is_server for green prompt; install script facilitates
this and now asks whether hg extensions are wanted
This commit is contained in:
2
.bashrc
2
.bashrc
@@ -76,7 +76,7 @@ if [ "$color_prompt" = yes ]; then
|
||||
YELLOW="\[\033[0;33m\]"
|
||||
GREEN="\[\033[0;32m\]"
|
||||
PROMPT_SYMBOL='$'
|
||||
if [ "${HOSTNAME}" = "higgs.aquariusoft.org" ] || [ "${HOSTNAME}" = "medusa" ]; then
|
||||
if [ -e ~/.dot_is_server ]; then
|
||||
PS1="$YELLOW\t $GREEN\u$BLACK@\h:\W$ "
|
||||
else
|
||||
PS1="$YELLOW\t $BLUE\u$BLACK@\h:\W$ "
|
||||
|
||||
55
install.sh
55
install.sh
@@ -1,6 +1,30 @@
|
||||
#!/bin/sh
|
||||
# inspired by rrix' dotfiles
|
||||
|
||||
install_hg()
|
||||
{
|
||||
break
|
||||
# Mercurial extensions
|
||||
touch ~/.dot_has_hg
|
||||
HGDIR=~/workspace/application_addons/mercurial
|
||||
mkdir -p $HGDIR
|
||||
cd $HGDIR
|
||||
|
||||
for REPO in Mekk/mercurial_keyring sjl/hg-prompt durin42/hg-git yujiewu/hgflow
|
||||
do
|
||||
REPODIR="${REPO##*/}"
|
||||
echo $REPODIR
|
||||
if [ ! -d "$HGDIR/$REPODIR" ]; then
|
||||
hg clone http://bitbucket.org/$REPO
|
||||
#echo http://bitbucket.org/$REPO
|
||||
else
|
||||
cd $HGDIR/$REPODIR
|
||||
#echo $HGDIR/$REPODIR
|
||||
hg pull -u
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
cd $DIR
|
||||
|
||||
@@ -22,21 +46,18 @@ fi
|
||||
echo "INFO: Vundle Install"
|
||||
vim +BundleInstall +qall
|
||||
|
||||
# Mercurial extensions
|
||||
HGDIR=~/workspace/application_addons/mercurial
|
||||
mkdir -p $HGDIR
|
||||
cd $HGDIR
|
||||
|
||||
for REPO in Mekk/mercurial_keyring sjl/hg-prompt durin42/hg-git yujiewu/hgflow
|
||||
do
|
||||
REPODIR="${REPO##*/}"
|
||||
echo $REPODIR
|
||||
if [ ! -d "$HGDIR/$REPODIR" ]; then
|
||||
hg clone http://bitbucket.org/$REPO
|
||||
#echo http://bitbucket.org/$REPO
|
||||
else
|
||||
cd $HGDIR/$REPODIR
|
||||
#echo $HGDIR/$REPODIR
|
||||
hg pull -u
|
||||
fi
|
||||
echo "Do you wish to install mercurial stuff?"
|
||||
select yn in "Yes" "No"; do
|
||||
case $yn in
|
||||
Yes ) install_hg; break;;
|
||||
No ) break;;
|
||||
esac
|
||||
done
|
||||
|
||||
echo "Is this machine a server?"
|
||||
select yn in "Yes" "No"; do
|
||||
case $yn in
|
||||
Yes ) touch ~/.dot_is_server; break;;
|
||||
No ) break;;
|
||||
esac
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user