Harvest

Expand all | Collapse all

Is there a tool to migrate source code from CA harvest to TFS ?

Jump to Best Answer
  • 1.  Is there a tool to migrate source code from CA harvest to TFS ?

    Posted 08-06-2018 02:11 PM

    Hi all,

     

    Is there a migration tool or API to migrate source code from CA harvest to TFS along with history details ?

    We are planning to move few of our projects from CA harvest to TFS ..

     

    Thanks

    KN



  • 2.  Re: Is there a tool to migrate source code from CA harvest to TFS ?
    Best Answer

    Posted 08-06-2018 05:17 PM

    Harvest does not have a tool that will allow you to migrate versions from SCM into TFS.  

     

    By "along with history details" do you mean you want all versions that were previously checked into Harvest to now be checked into TFS?

     

    If not, what details do you need?

     

    If you just need the "diffs" between the versions, there are 2 command line utilities that might help:

     

    The "hsv" command (Select Version) works in a way similar to Workbench's Find Version tool.  It can be used to get a complete list of version numbers for an item (or folder, or viewpath, etc).  hsv Command-Select Version - CA Harvest SCM - 13.0 - CA Technologies Documentation 

     

    The "hlv" command (List Version) has an option that lets you list the actual changes in "diff" format for a version of an item as compared to the previous version.  hlv Command-List Version - CA Harvest SCM - 13.0 - CA Technologies Documentation 

     

    Let me know if this is the information you needed.

     

    Thanks



  • 3.  Re: Is there a tool to migrate source code from CA harvest to TFS ?

    Posted 08-07-2018 12:14 AM

    Thanks Melinda for your answers..

    As there is no tool for migrating source codes, should we dump the code into tfs manually after downloading from harvest ? 

    If yes , how do you suggest the source code move from Harvest to TFS? should the latest versions in production state alone be migrated or all versions in the production state  ?

     

    With 2 commands you suggested for retrieving the history of changes between 2 versions , we retrieve the history information in command line and how do we transfer that to TFS ? please post your suggestion..

     

    Thanks in advance !!



  • 4.  Re: Is there a tool to migrate source code from CA harvest to TFS ?

    Posted 08-07-2018 12:21 PM

    I am not familiar with how TFS is structured, so don't have a recommendation for how best to do this.  If keeping reports of the changes would be sufficient as a reference point, just checking out the latest versions from production and checking those into TFS would create a good "starting from here" point.  

     

    The other end of the spectrum would be to create a script that would check out from Harvest and check into TFS one version at a time.  You could use the "hsv" command to create your list of all versions of all files in the production state, then just go through the list and do a Harvest check out - TFS check in for each row in the list.

     

    Let me know if this helps.



  • 5.  Re: Is there a tool to migrate source code from CA harvest to TFS ?

    Posted 08-07-2018 12:43 PM

    Thanks Melinda!! that gives some clue..

    Does Hlv command to list differences , supports listing of differences for multiple files ? like list all differences of all files in production state of a project? so that we get all history information for all files in a single command? 

    Is so can you please let me know an example? or it goes only by single file at a time ?  



  • 6.  RE: Re: Is there a tool to migrate source code from CA harvest to TFS ?

    Posted 10-11-2019 06:56 PM
    Melinda,

    once you have run the hsv command, how do you view the list?


  • 7.  RE: Re: Is there a tool to migrate source code from CA harvest to TFS ?

    Posted 10-14-2019 09:23 AM
    All the Harvest command line utilities write their results to a log file rather than to the screen.  By default, the log file has the same name as the command with a .log file extension, and is written to the current working directory.  The one exception is if you don't have permission to create or update files in the current working directory you don't get the log file.

    To override the default, you would add the "-o" option or the "-oa" option and a file name.  "-o" creates a new file, or overwrites the file if it exists, and "-oa" creates a new file or appends the result to the file if it already exists.

    Here's where you can read more about "-o" and "-oa": https://techdocs.broadcom.com/content/broadcom/techdocs/us/en/ca-enterprise-software/business-management/harvest-scm/13-0/command-reference/get-started-with-ca-harvest-scm-commands.html

    Let me know if this helps.  :)

    ------------------------------
    Melinda Skelton
    ------------------------------