A passionate programmer’s findings in the world of internet.

Archive for June, 2007

Setup CVSNT for Personal Use

Thursday, June 21st, 2007

After developed a small system, I find it hard to keep track all versions of my source files, especially when there are bug fixes and enhancement requests. I have to create a whole new folder to keep track all changes in the past to allow me rollback to a specific version that I need. I'm sure there are version control system that could help me. In my day work, my company is using SCCS/CSSC but it requires Linux environment.

I asked my friends who do programming in Windows environment for suggestions. Most of them confirmed that CVSNT is the thing I need.

There are lots of good and detail guide out there to setup CVSNT, but I there is none that is simple and straight forward, or it's probably too complicated for my simple mind. Let me try to put up a simple guide, with my own experience.


Zip a Folder Using Command Line

Wednesday, June 6th, 2007

As far as I know, the built-in compressed zip folder function in Windows XP does not provide any command line tools. To zip a folder using batch script or command line, one can install command line tool provided by 7zip.

It can be done with installation of whole 7zip package or just use an executable file provided by 7zip. I prefer the latter option.

Download the "7-Zip Command Line Version" from 7zip download page and unzip it.

Use the following command to zip a folder:

7za a -tzip <archive-name> <folder-name>

e.g. 7za a -tzip test.zip "New Folder"

Although this seems to be quite useless to be run in command line, but it's extremely useful if you need to create batch script to automatically zip a folder. For my case, I need it to zip a folder and FTP it to a server. By this way, I can backup a folder to server without having to consider the recursive FTP upload problem.