[p4] Getting the size of a branch

G Barthelemy gb.perforce at googlemail.com
Tue Apr 29 11:46:54 PDT 2008


Or try p4 sizes -s //depot/some/branch/... (available since 2006.2).
It also work with remote depots.

Guillaume


On Tue, Apr 29, 2008 at 4:54 PM, Robert Cowham <robert at vaccaperna.co.uk> wrote:
> I assume you mean size of files on disk (as opposed to number of files in
>  branch)?!
>
>  P4 fstat has the following option:
>
>              -Ol     output a fileSize and digest field for each revision
>                      (this may be expensive to compute)
>
>  So process output of:
>
>  P4 fstat -Ol //depot/some/branch/...
>
>  C:\bruno_ws>p4 fstat -Ol //depot/jam/MAIN/... | grep fileSize | gawk "{s +=
>  $3} END{print s;}"
>  475980
>
>  Note that the file size for text files is only accurate with Unix line
>  endings.
>
>  Robert
>
>
>
>  > -----Original Message-----
>  > From: perforce-user-bounces at perforce.com
>  > [mailto:perforce-user-bounces at perforce.com] On Behalf Of
>  > Jamison, Shawn
>  > Sent: 29 April 2008 15:56
>  > To: perforce-user at perforce.com
>  > Subject: [p4] Getting the size of a branch
>  >
>  > Howdy everyone,
>  >
>  > Is there a way to get the size of a branch from Perforce
>  > without having to sync the files out to local disk?
>  >
>  > Thanks for all your help.
>  > -Shawn Jamison>
>  > Ciena Corp.
>  > Perforce Admin
>  >
>  > _______________________________________________
>  > perforce-user mailing list  -  perforce-user at perforce.com
>  > http://maillist.perforce.com/mailman/listinfo/perforce-user
>  >
>  _______________________________________________
>  perforce-user mailing list  -  perforce-user at perforce.com
>  http://maillist.perforce.com/mailman/listinfo/perforce-user
>


More information about the perforce-user mailing list