2

I am trying to execute multiple mklabel commands in rcleartool from cmd in a batch file.

The commands that I am using are like:

echo Server URL | rcleartool mklabel Label_Name Object1
echo Server URL | rcleartool mklabel Label_Name Object2
echo Server URL | rcleartool mklabel Label_Name Object3
.
.

It is taking too long to execute each command.
I have tried finding a way for executing the mklabel commands in a single rcleartool session. But I didn't find any.

How to achieve this in one call instead of 3 (or n)?

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
Hemanth
  • 31
  • 3

1 Answers1

0

If you could list your objects through a rcleartool find, you could have use one mklabel in the -exec section. Sadly, -exec is not supported by rcleartool (only -print)

rlceartool mklabel supports multiple pname though

pname ...

(Required) One or more path names, indicating versions to be labeled:

  • A standard or view-extended path name to an element specifies the version selected in the view.
  • A version-extended path name specifies a version, independent of view.

That means you should be able to use:

echo Server URL | rcleartool mklabel Label_Name Object1 Object2 Object3

Depending on the number of files to label, you might want to find them first and assign their list (space separated) to variable, then call rcleartool mklabel Label_Name %list%.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250