Created
July 19, 2010 18:34
-
-
Save denniscastro/481780 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FriendlyId Rake Tasks | |
FriendlyId provides several tasks to help maintain your application. | |
Generating New Slugs For the First Time | |
friendly_id:make_slugs MODEL=<model name> | |
Use this task to generate slugs after installing FriendlyId in a new application. | |
Regenerating Slugs | |
friendly_id:redo_slugs MODEL=<model name> | |
Use this task to regenerate slugs after making any changes to your model’s FriendlyId configuration options that affect slug generation. For example, if you introduce a cached_slug column or change the :seqence_separator. | |
Deleting Old Slugs | |
rake friendly_id:remove_old_slugs MODEL=<model name> DAYS=<days> | |
Use this task if you wish to delete expired slugs; manually or perhaps via cron. If you don’t specify the days option, the default is to remove unused slugs older than 45 days. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment