Best way to version control WordPress template files?

The built-in ability to restore revisions of posts and pages in WordPress is great. Is there something that gives the same power to template files in the theme-editor? Perhaps a plugin?

2 s
2

Templates are only stored as files in the file system. They are not stored in the database so there is no core functionality for versioning template files. When you make changes, the file is overwritten with the changes.

The easiest route would be to use an existing version control solution (SVN,CVS,Git,Hg, etc.) and maintain the versioning separate from WordPress.

Leave a Comment