Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
Comparing 'versions' of plugins
This should really be called “saving me from my own stupidity”…
Over time, I have made some slight modifications to a few plugins – nothing heavy duty, but mainly to add in class and id elements into the HTML output so that I can access it with CSS and JS.
Of course, when a new version of the plugin is released I have no idea what I have changed so that I can incorporate my changes in the new version.
What I would like is some idea of the best practice for comparing ‘versions’ of plugins.
And finally, what is the best practice when you do feel the need to change a plugin? Yes, documenting the changes within the code is easy, but what else should I do? eg. change the plugin name?
Thanks.
Offline
Re: Comparing 'versions' of plugins
Maybe rvm_plugin_diff can help you.
Otherwise putting clear comments into a plugin helps in tracking them down and why. I often mark mods by inserting // MOD (person)
and // MOD END
and if relevant, I will copy the original line and comment it out for reference, or describe what is different.
If you make more complex changes a diff tool is useful.
I’d also be interested to hear what other people do.
TXP Builders – finely-crafted code, design and txp
Offline
Re: Comparing 'versions' of plugins
Thanks for that.
rvm_plugin_diff is amazing and quickly shows me what I have done (not sure about the formatting of the ‘unified diff format’ but at least the information is there).
Your suggestions for commenting are good too.
Offline
Re: Comparing 'versions' of plugins
The unified diff is useful if you are a plugin developer and have access to the original PHP file used to create the plugin or if you want to submit a patch to the plugin developer. I wrote it mostly for the same purpose you’re using it for now, to find what I changed in the plugins I installed.
Offline
Pages: 1