Skip to content

Instantly share code, notes, and snippets.

View Raphy's full-sized avatar

Raphael De Freitas Raphy

  • Dehef Tech
  • Lille, France
View GitHub Profile
@Raphy
Raphy / rebuild_database.sh
Created April 4, 2015 13:46
Symfony Tool Script : Rebuild the database quickly
#!/bin/sh
app/console doctrine:database:drop --force
app/console doctrine:database:create
app/console doctrine:schema:update --force
app/console doctrine:fixtures:load -n # Remove this line if the bundle « doctrine/doctrine-fixtures-bundle » is not required by the project
@Raphy
Raphy / clear_cache.sh
Created April 4, 2015 13:50
Symfony Tool Script : Clear the cache quickly
#!/bin/bash
# Deleting the cache and logs
sudo rm -rf app/cache/* app/logs/*.log
# This previous line will only work if the current user has the right to execute the command as sudo
# Add into /etc/sudoers
# USER_NAME ALL = NOPASSWD: /bin/rm -rf app/cache/* app/logs/*.log
# Replace USER_NAME by the owner of the repository