Google Groups Home
Help | Sign in
I would like to add an enhancement to ClearCase sourcecontrol
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  1 message - Collapse all
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Antebios  
View profile
 More options Apr 23 2008, 1:25 pm
From: Antebios <antebi...@gmail.com>
Date: Wed, 23 Apr 2008 10:25:38 -0700 (PDT)
Local: Wed, Apr 23 2008 1:25 pm
Subject: I would like to add an enhancement to ClearCase sourcecontrol
We use ClearCase where I work, and we leverage labels to create views
of code at that have that particular label.  So, when a developer
works and is finally finished with his completed task he/she will
apply a already created label to all of the source code.  Then we have
a config spec filter it's view to only see code files with that
particular label and build off of that.  I modified the code to
leverage a new Element that can be used within the Sourcecontrol for
ClearCase.  The new element is "readSourceLabel" and you specify to
label to filter for.  Also, the config spec needs to have this filter
also.

The change I made was to:
Source\project\core\sourcecontrol\ClearCase.cs

--------------------------------------------------------------------------- ----------------------
// New property to use ClearCase labels
[ReflectorProperty("readSourceLabel", Required = false)]
        public string ReadSourceLabel;

private string CreateHistoryArguments(string fromDate)
                {

            //added if; else was original code
            ProcessArgumentBuilder builder = new
ProcessArgumentBuilder();
            if (ReadSourceLabel != null && ReadSourceLabel.Length > 0)
            {
                builder.AppendArgument("find {0}", ViewPath);
                builder.AppendArgument(" -ver \"{{lbtype({0}) ",
ReadSourceLabel.Trim());
                builder.AppendArgument("&& created_since({0})}}\" -
exec \"", fromDate);
                builder.AppendArgument("cleartool lshist -r -nco");
                builder.AppendIf(Branch != null, "-branch \"{0}\"",
Branch);
                builder.AppendArgument("-since {0}", fromDate);
                builder.AppendArgument("-fmt
%u{0}%Vd{0}%En{0}%Vn{0}%o{0}!%l{0}!%a{0}%Nc",
ClearCaseHistoryParser.DELIMITER);

builder.Append(ClearCaseHistoryParser.END_OF_LINE_DELIMITER + "\\n");
                builder.Append(" %CLEARCASE_XPN%\"");
            }
            else
            {
                builder.AppendArgument("lshist -r -nco");
                builder.AppendIf(Branch != null, "-branch \"{0}\"",
Branch);
                builder.AppendArgument("-since {0}", fromDate);
                builder.AppendArgument("-fmt
\"%u{0}%Vd{0}%En{0}%Vn{0}%o{0}!%l{0}!%a{0}%Nc",
ClearCaseHistoryParser.DELIMITER);

builder.Append(ClearCaseHistoryParser.END_OF_LINE_DELIMITER + "\\n
\"");
                builder.AppendArgument("\"{0}\"", ViewPath);
            }
                        return builder.ToString();
                }

P.S.  I've added another new feature that allows ForceBuilds from
outside the webdashboard and cruisecontrol, comes from a custom nant
task.

P.S.S. I've also added an enhancement to get the identity of the user
doing the force builds.

I can post these code changes also, but they are more extensive.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google