T
Tony
I'm trying to use the output of the the date/time from localtime into a
label.:
($sec,$min,$hour,$mday,$mon,$year,$wday,
$yday,$isdst)=localtime(time);
$year = ($year + 1900) - 2000;
$labelname = printf "REL_" . $proj[0] . "_%02d%02d%02d_%02d%02d%02d",
$hour,$min,$sec,$mon+1,$mday,$year;
print "$labelname\\n";
The problem is that when I input $labelname into a system command, an error
is returned saying
REL_Tony_021138_0824051
cleartool: Error: Name cannot be an integer: "1".
cleartool: Error: Unable to create label type "1".
Why do I get the extra 1 when adding \n?
How can I make this a string so it will be read as a string?
Tony
label.:
($sec,$min,$hour,$mday,$mon,$year,$wday,
$yday,$isdst)=localtime(time);
$year = ($year + 1900) - 2000;
$labelname = printf "REL_" . $proj[0] . "_%02d%02d%02d_%02d%02d%02d",
$hour,$min,$sec,$mon+1,$mday,$year;
print "$labelname\\n";
The problem is that when I input $labelname into a system command, an error
is returned saying
REL_Tony_021138_0824051
cleartool: Error: Name cannot be an integer: "1".
cleartool: Error: Unable to create label type "1".
Why do I get the extra 1 when adding \n?
How can I make this a string so it will be read as a string?
Tony