Current location: Hot Scripts Forums » Other Discussions » Other Topics » how to work with Code Repositories, but for web development?


how to work with Code Repositories, but for web development?

Reply
  #1 (permalink)  
Old 02-11-10, 05:42 AM
SoftDux SoftDux is offline
Newbie Coder
 
Join Date: Mar 2008
Location: Johannesburg,South Africa
Posts: 12
Thanks: 0
Thanked 0 Times in 0 Posts
how to work with Code Repositories, but for web development?

Hi all,

I would like some suggestion on this matter please. I have never bothered using any code repositories / version control systems for our web development project, many cause I didn't know any better, and probably cause most of our projects don't really require that we need to keep a history of what has changed. i.e. a client wants to change something on their website, and we change it, whether it's cosmetics or code (normally PHP & MySQL).

But, I want to see if CVS, or maybe even a forge script (like in offerforge) could benefit met. Most of the time when we make changes to the code, we simply update the version, from say 1.2.2 to 1.2.3 and write the changes to a basic changelog, which in our case is a simple text file calles changelog.txt

But, how could I benefit from a CVS, ir similar system? And what would be best for this environment? I installed CVS on my CentOS server, but it seems that it's not just a matter of creating a tree and dumping code. I'm not too worried about multiple users at this stage. All our coding is currently stored on a CentOS 5.4 Samba server, so we can access to the code from either a Windows or Linux PC. Do I need anything more?

I started using eclipse+PHP a few months ago and I don't really use it to its full potential, so I'm sure I could benefit from it more.



So, the question is, what is a good recommended setup to go with? Web based access to all the files would be nice, then we could access it from outside the LAN on HTTPS.
And how do I use it to my benefit? For example, clientA wants to make changes to Project1. Now I have a Project1 in the CVS tree (is this the right terminology?), and make changes to file contacts.php - what now? Do I need to create a subfolder called 1.2.2 (for example), and add only the updated file in this folder, or do I copy the whole Project into the new folder?

2 weeks down the line I need to make changes to 8 files, what do I do now?



Does this make sense? I realize it could be beneficial to keep older files, but how does one structure it?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 02-11-10, 04:06 PM
wirehopper's Avatar
wirehopper wirehopper is offline
-
 
Join Date: Feb 2006
Posts: 2,516
Thanks: 20
Thanked 109 Times in 106 Posts
I'd recommend installing a few different version control systems and testing them out.

The one I use (ClearCase) allows you to create a directory tree identical to that which you're building, so I work within that, check files in and out, then tar up the files and untar them for an install. We also use RPMs, but that may be overkill for you.

My standard procedure is to do the folllowing:

scp root@devserver:/path/to/file/file.php NEW
diff NEW file.php
ct co -nc file.php
cp NEW file.php
ct ci -c "Comment about change made" file.php

I don't check files out prior to working on them, but, I do get fresh copies of all the code before making changes. The diff is important, because it ensures I don't overwrite someone else's changes.

You can load the files up with wildcards, so the initial set up isn't difficult.

I use file -mtime 0 and ls -lat to see which files I've modified, and I always check them in one by one, to ensure the changes are done right.

All my interaction with the system is on the command line.

There is a lot to know about branches, releases, and labels. Someone else takes care of that for me. After you find a system you like, you should take the time to learn more about it, prior to setting it up and using it.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Web Development and Design [ITScript, LLC] itscript Job Offers & Assistance 0 06-19-06 01:48 AM
Web Development and Design [ITScript, LLC] itscript Job Offers & Assistance 0 02-07-06 06:23 AM
VBA: My Outlook VBA rule code does't work :( gicio Visual Basic 1 12-03-03 11:21 AM
Reduce the time intensive phases of .Net application development using TierDeveloper3 smars General Advertisements 0 12-02-03 06:15 AM


All times are GMT -5. The time now is 10:43 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.