<commit_before># Migrations Plugin for CakePHP #

Version 2.1 for cake 2.x

This migrations plugin enables developers to quickly and easily manage and migrate between database schema versions.

As an application is developed, changes to the database may be required, and managing that in teams can get extremely difficult. Migrations enables you to share and co-ordinate database changes in an iterative manner, removing the complexity of handling these changes. 
This is not a backup tool, however you can make use of callbacks if you want to backup data or execute extra queries. We highly recommend not to run Migrations in a production environment directly without doing a backup and running it first in a staging environment.

## Installing ##


## Usage ##

- Unzip or clone this plugin into your app/Plugin/Migrations folder or the shared plugins folder for your CakePHP installation.
- Add the plugin to your app/Config/bootstrap.php using `CakePlugin::load('Migrations')`
- Run `Console/cake Migrations.migration run all -p Migrations` to initialized the `schema_migrations` table

### Generating your first migration ###

The first step to adding migrations to an existing database is to import the database's structure into a format the migrations can work with. Namely a migration file. To create the _first_ migration file run the following command:

	cake Migrations.migration generate

Answer the questions asked, and it will generate a new file containing a database structure snapshot using the internal migration's plugin syntax.
If you want import all tables regardless if it has a model or not you can use -f (force) parameter while running the command:

	cake Migrations.migration generate -f 

### Running migrations ###<commit_msg>Correct typo in Readme.md<commit_after># Migrations Plugin for CakePHP #

Version 2.1 for cake 2.x

This migrations plugin enables developers to quickly and easily manage and migrate between database schema versions.

As an application is developed, changes to the database may be required, and managing that in teams can get extremely difficult. Migrations enables you to share and co-ordinate database changes in an iterative manner, removing the complexity of handling these changes. 
This is not a backup tool, however you can make use of callbacks if you want to backup data or execute extra queries. We highly recommend not to run Migrations in a production environment directly without doing a backup and running it first in a staging environment.

## Installing ##


## Usage ##

- Unzip or clone this plugin into your app/Plugin/Migrations folder or the shared plugins folder for your CakePHP installation.
- Add the plugin to your app/Config/bootstrap.php using `CakePlugin::load('Migrations')`
- Run `Console/cake Migrations.migration run all -p Migrations` to initialize the `schema_migrations` table

### Generating your first migration ###

The first step to adding migrations to an existing database is to import the database's structure into a format the migrations can work with. Namely a migration file. To create the _first_ migration file run the following command:

	cake Migrations.migration generate

Answer the questions asked, and it will generate a new file containing a database structure snapshot using the internal migration's plugin syntax.
If you want import all tables regardless if it has a model or not you can use -f (force) parameter while running the command:

	cake Migrations.migration generate -f 

### Running migrations ###
{'fraction_non_alphanumeric': 0.04290991759022449, 'fraction_numerical': 0.0017050298380221654, 'mean_word_length': 4.705024311183144, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, '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': '6378602', 'n_tokens_mistral': 835, 'n_tokens_neox': 805, 'n_words': 505}