Dev Environment Revisited
So after a few weeks of using the dev environment that I talked about in my last post I’ve modified it and revised it thusly (anything to say the terrible word thusly in a post).
Since I started this, I’ve always had a concern over security and privacy with what could be very sensitive data on Dropbox, so I’ve stopped using it to host the code.
Don’t get the wrong idea, Dropbox is a great service, and I use it for a lot of stuff. It’s just not as completely secure as you might think it to be (which has it’s pros and cons). So things like taxes, financial information, and other sensitive non-encrypted data probably should not be stored there (well encrypted data, like 1Password, should be fine for most intents and purposes).
This brings me back to how can I get the code on multiple machines when I need to.
I generally work on the Mac, but on occasion I work on a Windows machine as well. I still don’t want to use GitHub since I want to have my own simple versioning system, and something down and dirty to use and learn. Due to the nature of the two OSes, I also don’t want to open my Mac to network file sharing since it would require me to reduce the security of the machine (cough, cough, windows, cough, cough).
So I decided on a little trick to be able to version my code, backup my code, and also have it available on multiple machines all in one go.
The process is relatively simple. Using a shell script (Mac) or a batch file (Windows) I can create a zip file of the current source code, put the current date in the filename, and place it on a networked drive. I can achieve all of that from within my text editor or at worst a terminal/prompt window with one command (which I usually have open anyway).
This gives me a backup copy of any given days work in a central location.
It’s not perfect yet since I still have to go and retrieve the code and replace the code on the local machine after I work on another machine. Which I should create a new shell script/batch file now that I think about it.
These scripts have taken more time then I thought they would. I spent one whole evening last week getting the batch file to even work just to find out all I had to do was close and reopen the command prompt (cough, cough, windows, cough, cough).
While limiting, these scripts are amazingly robust. Once I finish them I will be releasing a version of them for people to look at and use if they want to.
One may ask why not just create a program to do that. I should, and maybe someday I will, but right now I just want something that works and can easily be modified if I need to make minor adjustments.