Using rsync to create two versions of the same software.

keith smith klsmith2020 at yahoo.com
Tue Jun 15 10:44:23 MST 2010


Hi All,

In the old days of writing desktop applications, when one wanted to make two versions of the same app - one free or demo and the other with all the features, all one had to do was add a switch to include (run) or exclude (not run) the code to create either version and compile.

Now that we have interpreted web based applications written in PHP and the like, this option does not work so well.  I was thinking about this recently and wondering how to address such an issue with PHP.

Yesterday while looking at rsync I happened upon a website and read "I personally use it to synchronize Website trees from 
staging to production
servers....".

Then it occurred to me that I can use rsync for building two different versions of a PHP application.  

I can add that switch to the code and test each version by setting the switch.  Then I can run rsync to copy each code set to its own directories.  

The other solution would be to use a compiler. 

I suspect I could use this to upload changes to a production server.  Configuring it to only copy files that have changed.  Interesting idea.  Only down side is any code not ready for production would be uploaded to the production server as well. 

------------------------

Keith Smith


      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.PLUG.phoenix.az.us/pipermail/plug-discuss/attachments/20100615/c0ad491b/attachment.html>


More information about the PLUG-discuss mailing list