<commit_before>#!/bin/sh

DIR=`php -r "echo dirname(dirname(realpath('$0')));"`
VENDOR="$DIR/vendor"
BUNDLES=$VENDOR/bundles

# initialization
if [ "$1" = "--reinstall" -o "$2" = "--reinstall" ]; then
    rm -rf $VENDOR
fi

# just the latest revision
CLONE_OPTIONS=''
if [ "$1" = "--min" -o "$2" = "--min" ]; then
    CLONE_OPTIONS='--depth 1'
fi

mkdir -p "$VENDOR" && cd "$VENDOR"

##
# @param destination directory (e.g. "doctrine")
# @param URL of the git remote (e.g. http://github.com/doctrine/doctrine2.git)
# @param revision to point the head (e.g. origin/HEAD)
#
install_git()
{
    INSTALL_DIR=$1
    SOURCE_URL=$2
    REV=$3

    echo "======================================================================"
    echo "> Installing/Updating " $INSTALL_DIR

    if [ -z $REV ]; then
        REV=origin/HEAD
    fi

    if [ ! -d $INSTALL_DIR ]; then
        git clone $CLONE_OPTIONS $SOURCE_URL $INSTALL_DIR
    fi

    cd $INSTALL_DIR
    git fetch origin
    git reset --hard $REV
    cd ..
}

# Assetic
install_git assetic http://github.com/kriswallsmith/assetic.git

# Symfony
install_git symfony http://github.com/symfony/symfony.git

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

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

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

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

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

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

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

# Swiftmailer
install_git swiftmailer http://github.com/swiftmailer/swiftmailer.git origin/4.1

# Twig
install_git twig http://github.com/fabpot/Twig.git v1.0.0

# Twig Extensions
install_git twig-extensions http://github.com/fabpot/Twig-extensions.git

# Monolog
install_git monolog http://github.com/Seldaek/monolog.git

# Imagine
install_git imagine http://github.com/avalanche123/Imagine.git

# Doctrine Extensions
install_git doctrine-extensions http://github.com/l3pp4rd/DoctrineExtensions.git

# ZF
mkdir -p $VENDOR/zf/library
svn co http://framework.zend.com/svn/framework/standard/tags/release-1.11.5/library/ $VENDOR/zf/library

# ZF2
install_git zf2 http://github.com/zendframework/zf2.git


# FunctionalTestBundle
mkdir -p $BUNDLES/Liip
cd $BUNDLES/Liip
install_git FunctionalTestBundle http://github.com/liip/FunctionalTestBundle.git

# MenuBundle
mkdir -p $BUNDLES/Knplabs/Bundle
cd $BUNDLES/Knplabs/Bundle
install_git MenuBundle http://github.com/knplabs/MenuBundle.git

# ZendCacheBundle
mkdir -p $BUNDLES/Bundle
cd $BUNDLES/Bundle
install_git ZendCacheBundle http://github.com/knplabs/ZendCacheBundle.git

# SensioFrameworkExtraBundle
mkdir -p $BUNDLES/Sensio/Bundle
cd $BUNDLES/Sensio/Bundle
install_git FrameworkExtraBundle http://github.com/sensio/SensioFrameworkExtraBundle.git

# SecurityExtraBundle
mkdir -p $BUNDLES/JMS
cd $BUNDLES/JMS
install_git SecurityExtraBundle http://github.com/schmittjoh/SecurityExtraBundle.git

# DoctrineExtensionsBundle
mkdir -p $BUNDLES/Stof
cd $BUNDLES/Stof
install_git DoctrineExtensionsBundle http://github.com/stof/DoctrineExtensionsBundle.git

# DoctrineFixturesBundle
mkdir -p $VENDOR/symfony/src/Symfony/Bundle/
cd $VENDOR/symfony/src/Symfony/Bundle/
install_git DoctrineFixturesBundle http://github.com/symfony/DoctrineFixturesBundle.git

# DoctrineFixturesBundle
mkdir -p $VENDOR/symfony/src/Symfony/Bundle/
cd $VENDOR/symfony/src/Symfony/Bundle/
install_git DoctrineMigrationsBundle https://github.com/symfony/DoctrineMigrationsBundle.git

# Update the bootstrap files
$DIR/bin/build_bootstrap.php

# Update assets
$DIR/app/console assets:install --symlink $DIR/web/<commit_msg>fixed typo<commit_after>#!/bin/sh

DIR=`php -r "echo dirname(dirname(realpath('$0')));"`
VENDOR="$DIR/vendor"
BUNDLES=$VENDOR/bundles

# initialization
if [ "$1" = "--reinstall" -o "$2" = "--reinstall" ]; then
    rm -rf $VENDOR
fi

# just the latest revision
CLONE_OPTIONS=''
if [ "$1" = "--min" -o "$2" = "--min" ]; then
    CLONE_OPTIONS='--depth 1'
fi

mkdir -p "$VENDOR" && cd "$VENDOR"

##
# @param destination directory (e.g. "doctrine")
# @param URL of the git remote (e.g. http://github.com/doctrine/doctrine2.git)
# @param revision to point the head (e.g. origin/HEAD)
#
install_git()
{
    INSTALL_DIR=$1
    SOURCE_URL=$2
    REV=$3

    echo "======================================================================"
    echo "> Installing/Updating " $INSTALL_DIR

    if [ -z $REV ]; then
        REV=origin/HEAD
    fi

    if [ ! -d $INSTALL_DIR ]; then
        git clone $CLONE_OPTIONS $SOURCE_URL $INSTALL_DIR
    fi

    cd $INSTALL_DIR
    git fetch origin
    git reset --hard $REV
    cd ..
}

# Assetic
install_git assetic http://github.com/kriswallsmith/assetic.git

# Symfony
install_git symfony http://github.com/symfony/symfony.git

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

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

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

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

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

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

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

# Swiftmailer
install_git swiftmailer http://github.com/swiftmailer/swiftmailer.git origin/4.1

# Twig
install_git twig http://github.com/fabpot/Twig.git v1.0.0

# Twig Extensions
install_git twig-extensions http://github.com/fabpot/Twig-extensions.git

# Monolog
install_git monolog http://github.com/Seldaek/monolog.git

# Imagine
install_git imagine http://github.com/avalanche123/Imagine.git

# Doctrine Extensions
install_git doctrine-extensions http://github.com/l3pp4rd/DoctrineExtensions.git

# ZF
mkdir -p $VENDOR/zf/library
svn co http://framework.zend.com/svn/framework/standard/tags/release-1.11.5/library/ $VENDOR/zf/library

# ZF2
install_git zf2 http://github.com/zendframework/zf2.git


# FunctionalTestBundle
mkdir -p $BUNDLES/Liip
cd $BUNDLES/Liip
install_git FunctionalTestBundle http://github.com/liip/FunctionalTestBundle.git

# MenuBundle
mkdir -p $BUNDLES/Knplabs/Bundle
cd $BUNDLES/Knplabs/Bundle
install_git MenuBundle http://github.com/knplabs/MenuBundle.git

# ZendCacheBundle
mkdir -p $BUNDLES/Bundle
cd $BUNDLES/Bundle
install_git ZendCacheBundle http://github.com/knplabs/ZendCacheBundle.git

# SensioFrameworkExtraBundle
mkdir -p $BUNDLES/Sensio/Bundle
cd $BUNDLES/Sensio/Bundle
install_git FrameworkExtraBundle http://github.com/sensio/SensioFrameworkExtraBundle.git

# SecurityExtraBundle
mkdir -p $BUNDLES/JMS
cd $BUNDLES/JMS
install_git SecurityExtraBundle http://github.com/schmittjoh/SecurityExtraBundle.git

# DoctrineExtensionsBundle
mkdir -p $BUNDLES/Stof
cd $BUNDLES/Stof
install_git DoctrineExtensionsBundle http://github.com/stof/DoctrineExtensionsBundle.git

# DoctrineFixturesBundle
mkdir -p $VENDOR/symfony/src/Symfony/Bundle/
cd $VENDOR/symfony/src/Symfony/Bundle/
install_git DoctrineFixturesBundle http://github.com/symfony/DoctrineFixturesBundle.git

# DoctrineMigrationsBundle
mkdir -p $VENDOR/symfony/src/Symfony/Bundle/
cd $VENDOR/symfony/src/Symfony/Bundle/
install_git DoctrineMigrationsBundle https://github.com/symfony/DoctrineMigrationsBundle.git

# Update the bootstrap files
$DIR/bin/build_bootstrap.php

# Update assets
$DIR/app/console assets:install --symlink $DIR/web/
{'fraction_non_alphanumeric': 0.13760651150960193, 'fraction_numerical': 0.007121963627114333, 'mean_word_length': 4.601139601139601, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3895586', 'n_tokens_mistral': 2786, 'n_tokens_neox': 2747, 'n_words': 524}