2017 © Pedro Peláez
 

symfony-bundle gitexpert-bundle

Provides some commands and other stuff to ease the work with git and a Symfony project.

image

friendsofgit/gitexpert-bundle

Provides some commands and other stuff to ease the work with git and a Symfony project.

  • Saturday, February 1, 2014
  • by xavierdubuc
  • Repository
  • 1 Watchers
  • 0 Stars
  • 4 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

GitExpertBundle

The FOGGitExpertBundle adds commands and other stuff to ease the use of git on Symfony project. This bundle is in DEVELOPMENT, so any comment, help or review is greatly welcome !, (*1)

Installation

Step 1 : Require the project in your composer.json

//composer.json
{
    "require": {
        "friendsofgit/gitexpert-bundle" : "*"
    }
}
...

Step 2 : Enable the bundle

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new FOG\GitExpertBundle\FOGGitExpertBundle(),
    );
}

Usage

When you work in a team on a Symfony project, when you pull some modifications made by an other member of the team, you often have to run some commands to continue your work. For example, in case of database modification, you have to run doctrine:update:schema in order to update your database with the changes done by your team mate. Another example is when you deploy your project on a remote server and you need to later update the remote server via a git pull. After this, while the server is in prod mode, you have to clear the cache and maybe install the assets., (*2)

The git:after:pull command allow to do all the needed verification and run all the needed commands in order to let you continue your work. It accepts two options :, (*3)

  • --hard Hard clear the caches, in other words, it rm -rf all the cache/prod and cache/dev directories
  • --reset Reset the database

The command workflow is : * If --reset option is set, drop database & recreate the database * If --reset option is set, load fixtures (DoctrineFixturesBundle) and demo content (BazingaFakerBundle) * Check if doctrine schema is valid - If the schema is not valid, abort - Else if the schema is valid but not synced with database, update the database - Else do nothing * If FOSElasticaBundle is installed, it populates the indexes * Clear the caches (via symfony command if --hard option is not set, via rm -rf otherwise) * Install the assets My site, (*4)

The Versions

01/02 2014

dev-master

9999999-dev

Provides some commands and other stuff to ease the work with git and a Symfony project.

  Sources   Download

The Requires

 

git team