Skip to content

Instantly share code, notes, and snippets.

@prcaen
Created May 23, 2012 23:11
Show Gist options
  • Save prcaen/2778423 to your computer and use it in GitHub Desktop.
Save prcaen/2778423 to your computer and use it in GitHub Desktop.
[Symfony] - Bash aliases
# Symfony aliases
## Cache
alias sf_cache_clear="php app/console cache:clear" # Clears the cache
alias sf_cache_warmup="php app/console cache:warmup" # Warms up an empty cache
## Doctrine
alias sf_doctrine_="php app/console doctrine:cache:clear-metadata" # Clears all metadata cache for a entity manager
alias sf_doctrine_="php app/console doctrine:cache:clear-query" # Clears all query cache for a entity manager
alias sf_doctrine_="php app/console doctrine:cache:clear-result" # Clears result cache for a entity manager
alias sf_doctrine_="php app/console doctrine:database:create" # Creates the configured databases
alias sf_doctrine_="php app/console doctrine:database:drop" # Drops the configured databases
alias sf_doctrine_="php app/console doctrine:ensure-production-settings" # Verify that Doctrine is properly configured for a production environment.
alias sf_doctrine_="php app/console doctrine:generate:crud" # Generates a CRUD based on a Doctrine entity
alias sf_doctrine_="php app/console doctrine:generate:entities" # Generates entity classes and method stubs from your mapping information
alias sf_doctrine_="php app/console doctrine:generate:entity" # Generates a new Doctrine entity inside a bundle
alias sf_doctrine_="php app/console doctrine:generate:form" # Generates a form type class based on a Doctrine entity
alias sf_doctrine_="php app/console doctrine:mapping:convert" # Convert mapping information between supported formats.
alias sf_doctrine_="php app/console doctrine:mapping:import" # Imports mapping information from an existing database
alias sf_doctrine_="php app/console doctrine:mapping:info" # Shows basic information about all mapped entities
alias sf_doctrine_="php app/console doctrine:query:dql" # Executes arbitrary DQL directly from the command line.
alias sf_doctrine_="php app/console doctrine:query:sql" # Executes arbitrary SQL directly from the command line.
alias sf_doctrine_="php app/console doctrine:schema:create" # Executes (or dumps) the SQL needed to generate the database schema
alias sf_doctrine_="php app/console doctrine:schema:drop" # Executes (or dumps) the SQL needed to drop the current database schema
alias sf_doctrine_="php app/console doctrine:schema:update" # Executes (or dumps) the SQL needed to update the database schema to match the current mapping metadata
## Generate
alias sf_gen_bundle="php app/console generate:bundle" # Generates a bundle
alias sf_gen_doctrine_crud="php app/console generate:doctrine:crud" # Generates a CRUD based on a Doctrine entity
alias sf_gen_doctrine_entities="php app/console generate:doctrine:entities" # Generates entity classes and method stubs from your mapping information
alias sf_gen_doctrine_entity="php app/console generate:doctrine:entity" # Generates a new Doctrine entity inside a bundle
alias sf_gen_doctrine_form="php app/console generate:doctrine:form" # Generates a form type class based on a Doctrine entity
# End Symfony aliases
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment