Skip to content

Commit

Permalink
Merge install_vendors.sh and update_vendors.sh
Browse files Browse the repository at this point in the history
Install or update vendors as needed. To force the old
install_vendors.sh behavior, you can call
update_vendors.sh --reinstall.
  • Loading branch information
laurentb authored and fabpot committed Feb 13, 2011
1 parent 8684055 commit f1633f8
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 50 deletions.
45 changes: 30 additions & 15 deletions install_vendors.sh
Expand Up @@ -3,40 +3,55 @@
cd $(dirname $0)

# initialization
if [ -d "vendor" ]; then
rm -rf vendor/*
else
mkdir vendor
if [ "$1" = "--reinstall" ]; then
rm -rf vendor
fi

cd vendor
mkdir -p vendor && cd vendor

##
# @param destination directory (e.g. "doctrine")
# @param URL of the git remote (e.g. git://github.com/doctrine/doctrine2.git)
#
install_git()
{
INSTALL_DIR=$1
SOURCE_URL=$2
if [ -d $INSTALL_DIR ]; then
cd $INSTALL_DIR
git pull
cd ..
else
git clone $SOURCE_URL $INSTALL_DIR
fi
}

# Doctrine ORM
git clone git://github.com/doctrine/doctrine2.git doctrine
install_git doctrine git://github.com/doctrine/doctrine2.git

# Doctrine Data Fixtures Extension
git clone git://github.com/doctrine/data-fixtures doctrine-data-fixtures
install_git doctrine-data-fixtures git://github.com/doctrine/data-fixtures

# Doctrine DBAL
git clone git://github.com/doctrine/dbal.git doctrine-dbal
install_git doctrine-dbal git://github.com/doctrine/dbal.git

# Doctrine Common
git clone git://github.com/doctrine/common.git doctrine-common
install_git doctrine-common git://github.com/doctrine/common.git

# Doctrine migrations
git clone git://github.com/doctrine/migrations.git doctrine-migrations
install_git doctrine-migrations git://github.com/doctrine/migrations.git

# Doctrine MongoDB
git clone git://github.com/doctrine/mongodb.git doctrine-mongodb
install_git doctrine-mongodb git://github.com/doctrine/mongodb.git

# Doctrine MongoDB
git clone git://github.com/doctrine/mongodb-odm.git doctrine-mongodb-odm
install_git doctrine-mongodb-odm git://github.com/doctrine/mongodb-odm.git

# Swiftmailer
git clone git://github.com/swiftmailer/swiftmailer.git swiftmailer
install_git swiftmailer git://github.com/swiftmailer/swiftmailer.git

# Twig
git clone git://github.com/fabpot/Twig.git twig
install_git twig git://github.com/fabpot/Twig.git

# Zend Framework
git clone git://github.com/zendframework/zf2.git zend
install_git zend git://github.com/zendframework/zf2.git
35 changes: 0 additions & 35 deletions update_vendors.sh

This file was deleted.

0 comments on commit f1633f8

Please sign in to comment.