hco on Linux Cannot Find the Files
search cancel

hco on Linux Cannot Find the Files

book

Article ID: 411966

calendar_today

Updated On:

Products

CA Harvest Software Change Manager CA Harvest Software Change Manager - OpenMake Meister

Issue/Introduction

When trying to do a "hco" command on the Linux platform, the log file shows that it tries to checkout file names from my current working directory, but does not find those files in the Harvest repository.  For example:

Here is my current working directory:

[example-user@example-broker ~]$ ls
hgetusg.log  oradiag_cascm  scripts  set_env.sh


Here is my hco command:

[example-user@example-broker ~]$ hco -o "hco.log" -b "example-broker" -en "SampleProject" -st "Development" -usr "*******" -pw "*******" -vp "/SampleRepository" -br -s * -r -op pc -cp "SampleRepository"


And here is the result in my hco.log file:

[example-user@example-broker ~]$ cat hco.log
I00060040: New connection with Broker example-broker  established.
W010a0074: Warning: No version found for filename or pattern: hgetusg.log .
W010a0074: Warning: No version found for filename or pattern: oradiag_cascm .
W010a0074: Warning: No version found for filename or pattern: scripts .
W010a0074: Warning: No version found for filename or pattern: set_env.sh .
I000a0080: Check out summary: Total: 0 ; Success: 0 ; Failed: 0 ; Not Processed: 0 .

Environment

Harvest Software Change Manager v14.x and higher
Linux/Unix platforms only

Cause

When trying to reproduce the same error on Windows we could not.  But on Linux and Unix, the operating system handles the command line parameters differently.

The rule on both Windows and Linux/Unix is to always put double-quotes around any value containing spaces or special characters when building a command line.  In the example command above, the value for the "-s" parameter is listed as an asterisk without double quotes

[example-user@example-broker ~]$ hco -o "hco.log" -b "example-broker" -en "SampleProject" -st "Development" -usr "*******" -pw "*******" -vp "/SampleRepository" -br -s * -r -op pc -cp "SampleRepository"

Resolution

Placing double quotes around the asterisk causes the command to work correctly:

[example-user@example-broker ~]$ hco -o "hco.log" -b "example-broker" -en "SampleProject" -st "Development" -usr "harvest" -pw "harvest" -vp "/SampleRepository" -br -s "*" -r -op pc -cp "SampleRepository"
[example-user@example-broker ~]$ cat hco.log
I00060040: New connection with Broker example-broker  established.
...
I00060080: Check out summary: Total: 32 ; Success: 32 ; Failed: 0 ; Not Processed: 0 .
Checkout has been executed successfully.

Additional Information

More details about the hco command can be found here: hco Command-Check-out