This is the mail archive of the mailing list for the GDB project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Question about "cvs update"

On Monday 11 October 2010 17:51:17, Dave Korn wrote:
> On 11/10/2010 08:49, Hui Zhu wrote:
> > Hi guys,
> > 
> > "cvs update -d" will make the src directory include a lot of other
> > softwares like binutils, sid and so on.
> > 
> > I want keep the directory just have the file of GDB.  I tried "cvs
> > update -dP".  But it still tried to checkout the files of other
> > softwares.
> > 
> > Could someone tell me how to update the all src directory and do not
> > co the files of other softwares.
>   I do something roughly(*) like:
> ls -1d */CVS | cut -d/ -f1 | xargs cvs up -dP
> ... followed by a plain old "cvs up" to get the top-level files.  This can
> easily be put into a shell alias or function definition in one of your shell
> startup scripts.

Irks.  I just do "cvs co" which knows to update instead of
checkout if you already have a tree, but wrapped in a tiny script
that I carry around to all my trees:

 $ cat /home/pedro/gdb/baseline/ 

 cvs -t -d co gdb

That's it!

To avoid hacks, I just have my sources in a directory
called literally "src".  E.g., I follow this layout:





When I want to update a tree, I just e.g.,

 $ cd /home/pedro/gdb/baseline
 $ ./

When I want to create a new fresh checkout, I do:

 $ mkdir /home/pedro/gdb/fresh-project
 $ cd /home/pedro/gdb/fresh-project
 $ cp /home/pedro/gdb/baseline/ /home/pedro/gdb/fresh-project
 $ ./

(or copy an existing tree)

I prefer copying the script file because sometimes I want to checkout
a specific date / tag / branch.  E.g.,

 $ cat /home/pedro/gdb/7_0/
 cvs -t -z9 -d co -r gdb_7_0-branch gdb

Pedro Alves

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]