Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

CVS CGI & Perl

by mandog (Curate)
on Jun 02, 2002 at 20:48 UTC ( #171065=perlquestion: print w/ replies, xml ) Need Help??
mandog has asked for the wisdom of the Perl Monks concerning the following question:

I'm a few chapters into Open Source Development With CVS The good bits of the book are released here under the GPL

Our (student & wannabe, hobbyest and unemployed) crew wants to get into CVS for a bunch of reasons. Our current method of version control is: "copy the current file to the "old" folder with today's date as a suffix." We want to know enough CVS to start contributing to projects like nms-cgi Our patron at the university wants his students to learn CVS. Often we'll go weeks without working on the code and then forget where we were (no changelog). We don't really have a boundary between production and development code. We're using emacs instead of pico now, but people still don't tell us we are cool.

We're using perl entirely for CGI and system administration for our web site and for the web sites of other organizations.

We've built a couple simple modules. (Now in /usr/local/lib/perl5/site_perl/) and apart from canned scripts, will mostly be doing CGI/DBI stuff.

We have our own machine(s) I'm wondering the best way to set things up and I'm wondering what tips people have for using CVS with Perl & CGI programs.

I'm thinking of modifying our existing setup to be something like:

production space:
# not in CVS /home/sites/<sitename>/cgi-bin # not in apache webspace & not in CVS # for .ini style files /home/sites/sitename/config/ # In CVS & in Apache webspace, one CVS projects per dir /home/sites/<sitename>/cgi-bin/project_1/ /home/sites/<sitename>/cgi-bin/project_2/ # In CVS out of apache webspace, one CVS project per dir /home/sites/<sitename>/lib/mod_1/ /home/sites/<sitename>/lib/mod_2/
Developer space would replace:
/home/sites/<sitename>
with:
/home/people/<person>public_html/

Does this setup make sense?

Anybody got some general CVS / Perl / CGI / CPAN (??) tips?



email: mandog

Comment on CVS CGI & Perl
Select or Download Code
Re: CVS CGI & Perl
by abaxaba (Hermit) on Jun 02, 2002 at 21:22 UTC
    This is a pretty wide-open question, but I'll relate my experience:

    I worked for a dotcom that used CVS, with virtually all of our code being perl and SYBASE-stored procedure source.

    We had about 8 developers -- 3 on the Sybase side, 5 on the perl side. We also had multiple boxes (prod/test/dev).

    On the dev box -- Each of the 5 perl developers had 2 webroots (Apache -- http/https) spawned to their ~ dir, each mapped two diffent ports (Mine was 7001 for http, 7002 for https). All development/unit testing was done in each developer's home directory.

    Our repository, IIRC, looked like this, using Module in the cvs context, not CPAN! :)

    Module:cgi
    Module:js
    Module:sql
    Module:site_perl

    Our site_perl CVS-Module did NOT contain CPAN modules, only our common scripts and proprietary modules.

    The dev. box main webroot (eg http://dev) was owned by webuser, and we did not have access to it. After a commit, the SR developer, who futher tested the code, would su webuser, and copy the code to appropriate spot in the http://dev directory.

    As far as general advice: CVS Keywords are your friend. We used $Author$, $Date$, and $ID$ -- and this saved a lot of arguements along the lines of "Who in the @#$^! committed this crap, and when the @#$% did they do it???"

    A good book, IMHO, on Open-Source development with CVS is Karl Fogel's.

    HTH!!
    ÅßÅ×ÅßÅ
    "It is a very mixed blessing to be brought back from the dead." -- Kurt Vonnegut

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://171065]
Approved by grep
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (6)
As of 2014-09-02 01:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (18 votes), past polls