Using the Rational OSLC Adapter for Git with Rational Team Concert Sally Hehir, Steve Wasleski, Joseph Leong, Ben Weinstein-Raun Last updated: January 4, 2013 Build basis: Rational Team Concert 4.0 A trial version of the IBM Rational Adapter for Git is available for internal evaluation, testing and demonstration purposes. For more details, visit this page. A supported version of the the IBM Rational OSLC Adapter for Git is now generally available with the Rational Lifecycle Integration Adapters Standard Edition offering. For more details, visit this page. This article presents user assistance for the technical preview of the Rational OSLC Adapter for Git. For information on obtaining the tech preview, see this link. Overview The IBM Rational OSLC Adapter for Git integrates Git commits with Rational Team Concert work items. You can continue working in Git, with the added ability to create a link between a Git commit and a Rational Team Concert work item. You create a link by annotating commit messages so that when a push operation is made to a configured shared repository, a link is made between the commit and the work item specified in the annotation. You can work from either the Git command line or Gitweb. A commit can reference more than one work item, and the same work item can be referenced in multiple commits. Links are visible in Rational Team Concert and in Gitweb. Links can be followed in either direction and deleted from the Rational Team Concert work item. In addition, links can be added between commits and to new or existing work items from Gitweb. This technical preview also includes a REST-based query service that you can use to obtain a list of Rational Team Concert work items associated with a Git commit id. Note: This technical preview is not intended for production use and should be deployed only into an evaluation environment. Work done with this version cannot be migrated to a later version of the Rational OSLC adapter for Git. Also, the preview has been tested only as part of Rational Team Concert deployments on Tomcat. The Rational Team Concert 4.0 server rename feature is not supported. Next steps Follow these steps to install and begin using the Rational OSLC Adapter for Git. Each step is explained in the following sections. 1. Download the IBM Rational OSLC Adapter for Git. 2. Install and configure the adapter. 3. Use the adapter through the command line or through Gitweb. For more help If you run into problems while completing the tasks in these topics or have general questions about the adapter, you can take these actions: Submit a defect in the Collaborative Lifecycle Management project area on jazz.net, and file it against Third Party Integrations Post a topic to the jazz.net discussion forum (https://jazz.net/forum) with the tags integrations or git. Downloading the adapter The adapter is available as a free download. To obtain it: 1. 2. 3. 4. Go to this link. Click All (356.96KB) under Platform. Login with your jazz.net ID. Review the accompanying license by clicking the View License link. If you agree to the license terms, select the checkbox to agree with the terms, and click Accept. 5. Your download should begin. If the download does not begin, follow the instructions provided. 6. Click the download tab and follow the instructions to obtain the adapter. 7. Download the archive file and uncompress it to a location that you can access later. About the download The Rational OSLC Adapter for Git is delivered as a single zip file. The zip file contains three other zip files and the license for the Rational OSLC Adapter for Git. Be sure to read the license information. The three zip files contained in the download correspond to the three parts of the adapter to be deployed and configured. They are: An extension to the Rational Team Concert CCM application Additions to the Gitweb user interface The Git pre-receive hook for your shared repositories Note: All the zip files include a date and time stamp as part of the file name. In these instructions those stamps are referenced as yyyymmdd-hhmm rather than as specific values. Installing and configuring the adapter Prerequisites Server software Rational Team Concert 4.0 Git and Gitweb 1.7.1 or later Server environments For Rational Team Concert, supported server environments are listed here. For Git and Gitweb, supported server environments are: Redhat Enterprise Linux (RHEL) 5 Update 5 or Server 6 SUSE Linux Enterprise Server (SLES) 10 SP3 or 11 SP1 Client software Developer Git compatible with the server version of Git Internet Explorer® 8 or 9 Firefox 3.6 or 10 ESR Software for command-line support Perl 5.10.1 LWP 6.04 LWP::Protocol::https 6.03 Overview The general steps for installing and configuring the adapter are: 1. Uncompress the download file as described in the section Downloading the adapter. 2. Deploy the CCM application extension 3. Deploy Gitweb additions 4. Optionally, deploy the Git receive hook These steps are explained in the following sections. Git adapter concepts As you go through the installation, you will create two new entities: a logical adapter and an adapted project. These are defined as follows: logical adapter A logical adapter is the Rational Team Concert Git adapter's representation of a single Gitweb instance. At registration a logical adapter is given a URI that uniquely identifies the Gitweb instance. This URI is used in subsequent interactions with the Rational Team Concert Git adapter. adapted project An adapted project is the Rational Team Concert Git adapter's representation of a single Gitweb project (that is, the Git repository). An adapted project has, among other properties, relationships to Rational Team Concert projects, one of which is selected as the default change request provider for Git receive hook processing. Each related Rational Team Concert project can have an abbreviation assigned to reduce the developer's memory burden when a non-default change request provider needs to be specified in a commit message. Deploy the CCM application extension This extension manages Gitweb registrations and registrations of projects within those Gitweb environments. It also manages the commit/work item links themselves. For the technical preview, only Rational Team Concert project areas defined within the extended CCM application are available for linking work items. Note: Examples in these sections assume ccm is the application root context for your installation. If not, you must update some of the example pathnames used in these installation steps. These differences are noted in the procedures. 1. Stop the Rational Team Concert application server. 2. Go to the directory in which you uncompressed the download and locate the gitAdapter-yyyymmdd-hhmm.zip file. 3. Uncompress this file to the folder <RTC-server-installationfolder>/server/conf/ccm. If you have a different context root, change the last segment of the destination path to that root and also change the git-adapter-profile.ini file as follows: o Open the following file in an editor: <RTC-server-installationfolder>/server/conf/<yourCCMRoot>/provision_profiles/gitadapter-profile.ini o Change the context root in the first line to match this: url=file:<yourCCMRoot>/sites/git-adapter-update-site Remember to save a copy of the git-adapter-profile.ini file to reuse, if you ever update the adapter. 4. Start the Rational Team Concert application server. 5. Verify that the installation was successful. o Go to the following URL (specifying your server name for <your.server> and accounting for any context root differences): https://<your.server>:9443/ccm/admin?internal#action=com.ibm. team.repository.admin.componentStatus o Verify that the component com.ibm.gearbox.adapter.git is listed. Redeploying the CCM application extension Follow these steps if you need to redeploy the CCM application extension: 1. Request a server reset. o Go to https://<your.server>:9443/ccm/admin?internal#action=com.ibm. team.repository.admin.serverReset (specifying your server name for <your.server> and accounting for any context root differences). Click Request Server Reset. Stop the Rational Team Concert application server. Delete the folder <RTC-server-installationfolder>/server/conf/ccm/sites/git-adapter-update-site, accounting for any context root differences. Uncompress the adapter you are deploying.. If needed, adjust the context root in the git-adapter-profile.ini file. Start the Rational Team Concert application server. o 2. 3. 4. 5. 6. Deploy Gitweb additions These additions support the creation of links between commits and Rational Team Concert work items as well as enabling you to see and traverse existing links. Perform these steps for each Gitweb instance you want to integrate with the Rational OSLC adapter for Git. This step creates the logical adapter. For more information about logical adapters see the section Git adapter concepts in this documentation. 1. Uncompress the gitwebAdditions-yyyymmdd-hhmm.zip file to your Gitweb installation folder; for example, /usr/share/gitweb. This adds a number of files to the ./static folder at that location. 2. Set gitweb.conf variables. The gitweb.conf file is typically found in your /etc folder. Use the following settings, also described in the ./static/gitweb.conf.README file that was added in the previous steps. 3. #Add the OSLC Style Sheet 4. push @stylesheets,"./static/OSLC.css"; 5. #Point the gitweb site header to the html file we've packaged our $site_header = './static/GitwebSiteHeader.html'; 6. Open the ./static/oslcConfig.js file in an editor and follow the instructions there. In this step you enable the Gitweb additions to find the extension you added to Rational Team Concert. This is used in the upcoming registration step. You will be directed back to this file to set the final configuration value for this same variable. 7. Register this Gitweb instance. This step makes this instance of Gitweb known to the adapter CCM extension and enables you to complete the configuration of Gitweb. For this step you must log in as a Rational Team Concert user with administrator or project administrator privileges. If you are already logged into Rational Team Concert in your current browser session with a userid that does not have these privileges, log out before beginning this step. o Open your browser to the Gitweb home page; for example, o http://our.git.server/git Add the parameter ?rtcRegisterSite to the end of the URL and reload the page; for example: http://our.git.server/git?rtcRegisterSite o If prompted to log into Rational Team Concert, log in as a user with administrator or project administrator rights. o A window opens showing the URL to be registered. Click Register. o After registration is complete, a logical adapter exists for this Gitweb. You will see further instructions that will direct you to take the logical adapter URI and update the same variable in the ./static/oslcConfig.js file that you set in a prior step. Complete the steps as instructed. You will register projects in the next step. 8. Register a project. This step makes the project known to the adapter CCM extension and enables the Gitweb features of the adapter. For this step you must be logged in as a Rational Team Concert user with administrator or project administrator privileges. Repeat this step for each project you want to register. This step creates an adapted project. For more infomation about adapted projects, see the Git adapter concepts section of this document. o o From the Gitweb home page, navigate to a project page. For example, click the "summary" link to proceed to that project page; for example, http://our.git.server/git?p=testproj1.git;a=summary Add the parameter ;rtcRegisterProject to the end of the URL and reload the page; for example, http://our.git.server/git?p=testproj1.git;a=summary;rtcRegi sterProject o If prompted to log into Rational Team Concert, log in as a user with administrator or project administrator rights. o o o A pop-up window is displayed in which you specify configuration choices. For the technical preview, there is no interface available to change these selections, so be careful at this point. The window displays a table listing all Rational Team Concert project areas contained in the extended CCM application. Supply values for the three other columns: In the default column, select a single project area to be the default work item provider for the receive hook you will configure later. This enables developers to enter strings such as bug 123 in their commit messages without having to specify a Rational Team Concert project area. This will also be the first project area in the project area dropdown when you create a link from Gitweb. In the others column, you select zero or more other Rational Team Concert project areas to be available for creating links from either a developer's commit message or Gitweb. In a commit message, a developer could use the project area name like this: bug(Our ABC project) 123. In the abbreviation column, enter a short abbreviation for the Rational Team Concert project area. This enables developers to shorten what they type in commit messages; for example, bug(abc)123. Once you have completed the table, click Register. Upon successful completion of the registration an adapted project exists for this Gitweb project. Further instructions will appear. These instructions direct you to record the adapted project URI. You will need the URI if you choose to configure the receive hook for the project in the next section. Gitweb, the adapter's Gitweb additions, and the adaptor-enabled project are now ready to use. Deploy the Git receive hook (optional) Each project you registered when you deployed additions to Gitweb has a shared Git repository. If you want developers to be able to add work item references to commit messages and have links created automatically when they push to this shared repository from the command line, you must deploy this hook. In your technical preview evaluation environment, this will probably be the only Git prereceive hook that you want to have active. In a production environment that might not be the case. If you already use pre-receive hooks in production, try that hook (or a simple shell of it) in the evaluation environment and use them in combination. You must rename the Git adapter hook and create a wrapper around this hook and yours. The wrapper will be the pre-receive hook and invokes the adapter hook and your existing hook. The wrapper must redirect everything from stdin to the adapter hook, exactly as it is received. We are hopeful of getting feedback in this area. These instructions assume the adapter hook will be the only pre-receive hook. Notice that there is a separate rtc_credentials.pl script. This enables you to decide how to store Rational Team Concert credentials (userid and password) for the hook. Our basic implementation reads plain text values from the Git configuration. You can replace this script with a solution that meets your particular security needs. You can provide comments about this feature through the jazz.net forum (https://jazz.net/forum/) with the tags “integration” or “git”. Installing the receive hook Before deploying the Git receive hook, check that you have the following software installed: Perl 5.10.1 Git 1.7.1 LWP 6.0.4 LWP::Protocol::https 6.03 The first two can be installed from your Linux distribution's package management repository or from source, and the last two should be installed through CPAN, Perl's software network. 1. Uncompress the gitHook-yyyymmdd-hhmm.zip file to the hooks folder for your shared Git repository; for example, /srv/git/testproj1.git/hooks. 2. All users who push to this repository must have execute permission for the prereceive file. From the command line, type: chmod a+x "/<path-to-repository-hooks>/pre-receive" This gives all users execute permission; if you need more granular control, read the chmod manual to determine a correct replacement for "a+". Configuring the receive hook Modify the Git configuration to include information about how to connect to Rational Team Concert. Note that the userid and password can be in a Git configuration level that is shared across several repositories. However, the adapted project URI must be configured uniquely for each Git repository. The adapted project URI is the the URI you were given when you registered the project from Gitweb. 1. From the command line, navigate to the shared repository and type the following command: git config rtc.adaptedProjectURL <Your adapted project URL> 2. When using the provided rtc_credentials.pl file you also need to set the userid and password. From a command line inside the shared repository, type the following commands where <username> and <password> are for the user you created at the beginning of these instructions: git config rtc.user <username> git config rtc.password <password> Your installation and configuration are now complete. Developers can now push commits with work item reference in the commit message and have links created. See the following sections for more information on using adapter from the command line or through Gitweb, and on using the query service for finding work items associated with a commit. Using the adapter from the Git command line The Rational OSLC adapter for Git supports command line and web interfaces. This section describes using the command line. You can create links between a Git commit and a change request in a registered Rational Team Project area by annotating a Git commit message with an identifier for the change request to which you want to link. By default, links are made to your primary Rational Team Concert project. You can also create links to other Rational Team concert projects. A single commit can link to multiple Rational Team Concert change requests and multiple commits can link to a single change request. Once created, links are visible as part of the change request in Rational Team Concert. Deleting links is done from the Links tab on the work item (change request) page in Rational Team Concert. To link a commit and a change request in a non- default Rational Team Concert project area Complete your Git work as you normally would. When writing the commit message, you must include the word bug followed by the number of the Rational Team Concert change request to which you are linking. Any errors are printed in the results of the Git push. You can use any of the following forms: bug 123 bug: 123 Example 1. in the following commit message the phrase "bug 10" on line 4 creates a link to defect 10 in the default Rational Team Concert project: 1 2 3 4 5 6 7 8 9 10 11 12 13 Fixed the instructions in the readme file Updated the instructions in the readme file fix bug 10 # # # # # # # # Please enter the commit message for your changes. Lines starting with '#' will be ignored, and an empty message aborts the commit. On branch master Changes to be committed: (use "git reset HEAD <file>..." to unstage) modified: readme.txt Example 2: The following command creates a link to defect 113 in the default Rational Team Concert project. > git commit -m bug 113 To link a commit and a change request in a non-default registered Rational Team Concert project area Complete your Git work as you normally would. When writing the commit message, you must include the word bug followed by the number of the Rational Team Concert change request to which you are linking. You can also specify the full Rational Team Concert project name or the project abbreviation that was specified when the project was registered. Any errors are printed in the results of the Git push. You can use any of the following forms: bug (my_full_project_name) 456 bug (project_alias) 456 bug (my_full_project_name): 456 bug (project_alias): 456 Example: 1 Fixed the instructions in the shared readme file 2 3 Updated the instructions in the shared readme file 4 fix bug(JKE) 12 Using the adapter from Gitweb The Rational OSLC adapter for Git supports command-line and web interfaces. This section describes Gitweb. With the Gitweb interface, you can create linkages between Git commits and existing Rational Team Concert change requests as you can on the Git command line. You can also create new Rational Team Concert change requests and links from Gitweb. Note that a commit can be linked to multiple change records and a change record can be linked to multiple commits. Workflow 1: From the Gitweb interface, create and link to a new change request in Rational Team Concert There are two typical work flows when using the adapter with the Gitweb interface. The first is when you want to link a commit to a new Rational Team Concert work item. 1. Start at a Gitweb home page 2. From a Gitweb commit page, create a new change request in Rational Team Concert using the Link Change Request dialog. Select Create new request and specify values for the dialog fields. This creates a change request in Rational Team Concert and links it to the Gitweb commit page. 3. When you click Show Change Requests on the Gitweb commit page, the new, linked, defect is listed. 4. Click the list item to go to the Rational Team Concert page for the change request. 5. Click the Links tab there to see the link back to the Gitweb commit page. You can traverse to the Gitweb page by clicking on the link. Workflow 2: From the Gitweb interface, link to an existing change request in Rational Team Concert The second workflow is for when you want to link a commit to an existing Rational Team Concert change request: 1. From the Gitweb home page, go to the commit page. 2. Click Link Change Requests. In the dialog, select Link to Existing and select the change request to which you want to link. Search methods are provided to help you locate the work item. 3. When you click Show Change Requests on the Gitweb commit page, the new link is listed. 4. Click the list item to go to the Rational Team Concert page for the change request. 5. Click the Links tab there to see the link back to the Gitweb commit page. You can traverse to the Gitweb page by clicking on the link. Deleting links Links can be deleted from the Rational Team Concert page. To delete a link: 1. Navigate to the Rational Team Concert page for the defect whose link you wish to remove. 2. Go to the Links tab. Select the link and click x to delete the link. If you go to the git commit page and click Show Change Requests, you will see that the defect has been removed from the list. IBM Rational OSLC Adapter for Git: query service The Git adapter provides a REST-based query service that enables you to obtain a list of Rational Team Concert work items associated with a Git commit id, The list is returned in JavaScript Object Notation (JSON) form. This functionality can help you compile reports about which work items are included in a build. Because a query is performed in the context of an RTC user account, the query request must be authenticated. Performing a query You perform a query by invoking an HTTP GET call with the following format: https://<your.server>:9443/ccm/gitAdaptercommit/<logical_adapter_id>/<Git_project>/<SHA1> Parameters are defined as: logical_adapter_id Identifier of the Gitweb instance to Rational Team Concert . This is assigned to the Gitweb instance during the initial configuration phase. Additionally, it can be found by observing existing links created from this Gitweb instance. Git_project The Git project name. SHA1 The Git hash that identifies that commit. Example script The following python script provides an example of a script to use with the query service. Notice that because queries are done in the context of Rational Team Concert projects, it's necessary to create an authentication step. You can change this script to suit your needs. #!/usr/bin/env python ccm_location = "https://oslcrox.my.server.location.com:9443/ccm/" user = "tanuj" password = "tanuj" logical_adapter = 0 project = "jkebanking.git" # Git project's name *in gitweb* import urllib2 import sys import json # the default urllib2 url-opener doesn't store cookies, which are required # for authentication with RTC, so we need to build our own opener: opener = urllib2.build_opener(urllib2.BaseHandler(), urllib2.HTTPSHandler(), urllib2.HTTPRedirectHandler(),# CCM May redirect us urllib2.HTTPCookieProcessor()) def auth_with_rtc(host, user, password): # First, we need to get a cookie, so RTC can identify us on future requests: opener.open(host+"authenticated/identity") # Next, send RTC our username and password: opener.open(host + "authenticated/j_security_check?j_username=" + user + "&j_password=" + password) # That's all! Now any responses with our session cookie will be authenticated. def find_associated_work_items(host, la_id, adapted_project, commit): try: res = opener.open(host + "gitAdapter-commit/" + str(la_id) + "/" + adapted_project + "/" + commit) except urllib2.HTTPError: # Misconfiguration, mistyping, or network error print "Could not find commit. Is the script configured with the proper" print "logical adapter? Also note that truncated commit hashes are" print "not accepted as inputs." return 1 try: query_response = json.load(res) except ValueError: # This probably means there's no JSON object in the response print "There are no work items associated with this commit." return 1 # The query service's response is a JSON array containing project areas. # Each project area is a dictionary with one entry. for project_area_dict in query_response: for project_area in project_area_dict.itervalues(): # The project area contains a second level of stringified JSON. # Inside this dictionary, all we care about are the oslc:results for result in json.loads(project_area)[u'oslc:results']: # oslc:results is an array of the matched work items in this project. # In a given work item, the info is contained in the rdf:about key. print result[u'rdf:about'] if __name__ == "__main__": auth_with_rtc(ccm_location, user, password) for arg in sys.argv[1:]: find_associated_work_items(ccm_location, logical_adapter, project, arg) Query response The following is an example of information that is returned from a query. The information is organized by Rational Team Concert projects and includes: The name of your Rational Team Concert project (CM Provider Project) The title of the work items associated with the commit A URL for each work item A count of the number of work items associated with the commit for that project. About the authors Sally Hehir is a technical writer at IBM. Steve Wasleski, Joseph Leong, and Ben Weinstein-Raun are software developers at IBM. Copyright © 2012 IBM Corporation Discussion Unsubscribe me li qiang wrote on June 14, 2012 11:28:07: Do you have plan to release git adaptor for production use? or do you have any plan to integrate Git just like done with SVN, import or bridge? thanks. Benjamin Shtark wrote on October 29, 2012 11:44:29: Hi Guys, i have installed module on CLM server successfuly, and configured the Gitweb according to the descriptions here. I also got 2 new "link" buttons in upper left corner of gitweb interface, they are: "Show Change Requests | Link Change Requests" but when i click on them, nothing happens. i tried to register the "git" server with clm by adding "?rtcRegisterSite" to end of URL, but nothing happened.. never got any buttons to click or any pages opened.. i double checked all config files (/etc/gitweb.conf and ./static/oslcConfig.js) - both seems fine. i have added 4 lines to the first config file and changed the URL on second file (added the hostname of CLM server). there are no problems with firewall/DNS - both servers are in same subnet.. please assist :) thanx Giacomo Gentile wrote on January 4, 2013 01:07:04: Any news on supporting GIT for production? roger layani wrote on January 23, 2013 02:53:11: we would replace word "bug:" by word "wi:" how can we do this? Is it not righter to use a post-receive hook in git (instead pre-receive) for adding link ? what happen when push failed for external reason? Rosa Naranjo wrote on April 23, 2013 11:47:25: Ben, Roger - better to post these questions to the Jazz.net forum for assistance. Giacomo and Li - I don't quite understand your questions regarding supporting GIT for production or releasing the GIT adapter for production use. This is already the case. The Rational Lifecycle Adapter for GIT has been generally available since Nov 2012. See http://www01.ibm.com/common/ssi/ShowDoc.wss?docURL=/common/ssi/rep_ca/3/897/ENUS212433/index.html&lang=en&request_locale=en#softx and http://www.ibm.com/developerworks/downloads/r/lifecycle/ and https://jazz.net/products/clm/features/clm_integrations/ Rosa Naranjo wrote on April 23, 2013 11:50:25: See this article for assistance with the 60 day trial version of the adapter for GIT. https://jazz.net/library/article/1209 Log in to submit a comment. Using the Rational Adapter for Git 60-day trial with Rational Team Concert Steve Wasleski, IBM, Joseph Leong, IBM, Robin Bobbitt, IBM, Sally Hehir, IBM, Melanie Steckham, IBM Last updated: June 11, 2013 Build basis: Rational Lifecycle Integration Adapters Standard Edition 1.1 This article presents user assistance for the 60-day trial version of the IBM® Rational Adapter for Git. This trial version is intended for internal evaluation, testing or demonstration purposes. A supported version of the Rational Adapter for Git is generally available with the Rational Lifecycle Integration Adapters Standard Edition offering. For more details, visit this page. Overview The Rational Adapter for Git allows you to link Rational Team Concert work items and Git commits or Gerrit changes. You can use the Rational Adapter for Git from any Git developer repository interface such as the Git command line or EGit, Gitweb, or Gerrit. Working from any of these interfaces, you can link a Git commit or Gerrit change to a Rational Team Concert work item. By default, links are made to your primary Rational Team Concert project. You can also create links to other Rational Team Concert projects. A single commit or Gerrit change can link to multiple Rational Team Concert work items and multiple commits or Gerrit changes can link to a single Rational Team Concert work item. Once created, links are visible from Gitweb, Gerrit, and Rational Team Concert. Important: This trial version of the Rational Adapter for Git is the same as the Rational Adapter for Git that is available with the Rational Lifecycle Integration Adapters Standard Edition offering, except that the trial version of the Rational Adapter for Git includes a trial license key that expires 60 days after activation. You need to purchase the entitled license key to continue to use the Rational Adapter for Git after the expiration date. Work done with the trial version of Rational Adapter for Git can continue to be used after you install the Rational Lifecycle Integration Adapters offering. Install and configure the Git adapter Several steps are required to install and configure the Rational Adapter for Git trial version before you can use it. Before you begin Verify that your hardware and software meet the minimum requirements. For a list of supported hardware and software platforms for Rational Adapter for Git, see Detailed System Requirements for Rational Lifecycle Integration Adapters Standard Edition. About this task This task provides an overview of the steps to complete before you can use the Git adapter. Procedure 1. Download and extract the Git adapter, see Download the Git adapter. 2. Install the Git adapter, see Install the Git adapter. Download the Git adapter The Rational Adapter for Git is available as a 60-day trial download. Before you begin Your hardware and software should meet the minimum requirements for the Rational Adapter for Git. About this task The Rational Adapter for Git is delivered as a single zip file. The zip file contains the files and the license for the Rational Adapter for Git trial version. Follow these steps to download this zip file. Procedure 1. 2. 3. 4. Go to Rational Adapter for Git download page. Click All (672.78 MB) under Platform. Login with your jazz.net ID. Review the accompanying license by clicking the View License link. If you agree to the license terms, select the checkbox to agree with the terms, and click Download. Your download should begin. If the download does not begin, follow the instructions provided. 5. Extract the downloaded file to a location that you can access. Install the Git adapter Several steps are required to install the Git adapter. Before you begin You have downloaded the Git adapter and extracted the files to a location that you can access. About this task You follow the same installation steps provided in the Rational Lifecycle Integration Adapters Standard Edition information center to install the Rational Adapter for Git trial version. Procedure Use the installation roadmap as a guide to the high-level steps required to install and configure the Git adapter, see Installation roadmap. Use the Git adapter The Rational Adapter for Git supports command line and web interfaces. Before you begin You have installed and configured the Git adapter. About this task You follow the same steps provided in the Rational Lifecycle Integration Adapters Standard Edition information center to use the Rational Adapter for Git trial version. Procedure Associate Git commits with Rational Team Concert work items, see Using Rational Adapter for Git. For more information If you run into problems while completing the tasks in these topics or have general questions about the Git adapter, you can take these actions: Submit a defect in the Collaborative Lifecycle Management project area on jazz.net and file it against Third Party Integrations. Post a topic to the jazz.net discussion forum (https://jazz.net/forum) with the tags integration or git. About the authors Steve Wasleski, Joseph Leong and Robin Bobbitt are software developers at IBM. Sally Hehir and Melanie Steckham are technical writers at IBM. Copyright © 2013 IBM Corporation Discussion Subscribe me Rosa Naranjo wrote on February 20, 2013 04:25:35: Note that if you have CLM configured without a port number in the public URI such as https://clm.jkebanking.net/jts there is a problem completing the GIT adapter installation. A defect has been filed. Angelo Giampa wrote on March 18, 2013 01:41:09: @Rosa do you have an WI that we can track for this defect? Rosa Naranjo wrote on March 18, 2013 02:00:34: https://jazz.net/jazz/web/projects/Jazz%20Lifecycle%20Integration%20Platform#action= com.ibm.team.workitem.viewWorkItem&id=253178 https://jazz.net/jazz/web/projects/Jazz%20Lifecycle%20Integration%20Platform#action= com.ibm.team.workitem.viewWorkItem&id=252649 Angelo Giampa wrote on March 18, 2013 02:07:36: Another question - does the Git adapter offering support using gitblit as an alternative to gitweb? Robin Yehle Bobbitt wrote on March 18, 2013 03:16:03: Angelo, we currently only support gitweb and gerrit. The development team has taken note of your request. Feel free to email me at [email protected] with additional input/feedback. Thanks! Angelo Giampa wrote on March 18, 2013 03:48:15: Thanks Robin. Will get back to you. Thanks Rosa. Unfortunately, I can't access the WIs. Is that PA restricted? Rosa Naranjo wrote on April 23, 2013 11:49:05: Yes Angelo, unfortunately, it is. Igor Vilenski wrote on July 11, 2013 01:17:18: Since these WIs are in restricted area, can somebody please let me know the status of these issue. Is there a fix, workaround, an upcoming release? Robin Yehle Bobbitt wrote on July 11, 2013 01:59:50: The original issue reported above by Rosa re: no port number is fixed in the V1.1 release, which is now available. As far as supporting additional Git servers, we only support Gitweb and Gerrit in V1.1. Igor Vilenski wrote on July 11, 2013 02:24:32: Thanks Robin! I’ll give it a try. P.S.: Posts in this thread are having a strange time stamp. Your post marked as "July 11, 2013 01:59:50". There is no place in the world (I know of :) currently with this time . (If this is 24 hrs. formats, otherwise it should be marked with AM/PM). Besides, it’s should be ether in local time or ( in worst case) GMT Log in to submit a comment. Git Versus Subversion Versus Rational Team Concert - Basic Commandline Syntax Reference AaronM.Cohen | Mar 27 2012 | Tags: syntax git rtc concert line command team rational subversion comment-line | 2 Comments | 3,810 Visits 1 I recently came across a Nick Boldt article called " Git vs. SVN - Basic Commandline Syntax Reference." I decided to enhance his table to include Syntax for the Rational Team Concert Command-line client. Action Git Syntax Subversion Syntax Rational Team Concert Syntax Initial checkout from existing repo for a given branch git clone <url> ; cd <module>; git checkout <branch> SVN checkout <url>/<branch> lscm load <workspace> -r <url> Update locally checked out files from central repo git pull svn update lscm accept -v List locally changes files/folders git status svn stat lscm status Diff locally changed file git diff somefile.txt svn diff somefile.txt lscm diff file somefile.txt Revert locally changed file* git checkout somefile.txt svn revert somefile.txt lscm undo somefile.txt Revert ALL local changes (except untracked files)* git reset --hard HEAD svn revert . -R lscm load <workspace> -r <url> Add new file git add file.txt svn add file.txt lscm checkin file.txt Add new folder recursively git add folder svn add folder lscm checkin folder Delete file git rm file.txt svn rm file.txt rm file.txt lscm checkin <parent folder> Delete folder git rm -r folder (non-recursive by default; use -r to recurse) Commit changed file to central repo git commit -m "<message>" file.txt; git push svn rm folder (recursive by default; use -N to not recurse) svn ci -m "<message>" file.txt rm folder lscm checkin <parent folder> lscm checkin file.txt lscm changeset comment <changeset> <message> Legend: <URL> - Repository URL <branch> - Branch or Stream or workspace <module>.- the component of the repository. <workspace> - Workspace is the Rational Team Concert equivalent of private Stream. <changeset> - Alias or UUID of target change set. <message> - Comment Text Add a Comment More Actions Comments (2) 1 - 2 of 2 Previous Next Page 1 1 Vijay_IBM commented Nov 7 Permalink Hi Aaron Its a good article and something i was looking for , only problem is its not displayed correctly . I have tried both mozilla firefox and chrome . Can you please correct this or send this article by email. 2 AaronM.Cohen commented Nov 7 Permalink Due to the formatting issue on Developerworks. I have moved this post to my personal blog. http://www.aaroncohen.me/2013/07/git-versus-subversion-versus-rational-teamconcert-basic-commandline-syntax-reference/ Integrations with Git Type to search Show Details Rational Lifecycle Integration Adapters (Git, Gitweb, Gerrit), Standard Edition Provided by: Rational integrations gearbox development Release type: GA *There may be a charge for this solution. The Rational Lifecycle Integration Adapters extend Rational products with integrations to select third-party tools. These adapters enable customers to gain greater value from Rational products when practicing ALM in a heterogeneous lifecycle tools environment. The second release of this offering (v.1.1) includes adapters for integrating with HP ALM 11 and 11.5, Atlassian JIRA 4.4.x and 5.x, and open source Git 1.7.1, Gitweb 1.7.1, Gerrit 2.2.2 and subsequent fixpacks. The IBM Rational Adapter for Git associates Git commits with Rational Team Concert work items. You can continue working in Git, with the added ability to create a link between a Git commit and a Rational Team Concert work item. You create a link by annotating commit messages so that when a push operation is made to a configured shared repository, the commit and the work item specified in the annotation are linked. Learn more > Rational OSLC Adapter for GIT 60-day Trial Provided by: Rational integrations gearbox development Release type: GA The Rational Lifecycle Integration Adapters extend Rational products with integrations to select third-party tools. These adapters enable customers to gain greater value from Rational products when practicing ALM in a heterogeneous lifecycle tools environment. The second release of this offering (v.1.1) includes adapters for integrating with HP ALM 11 and 11.5, Atlassian JIRA 4.4.x and 5.x, and open source Git 1.7.1, Gitweb 1.7.1, Gerrit 2.2.2 and subsequent fixpacks. The IBM Rational Adapter for Git associates Git commits with Rational Team Concert work items. You can continue working in Git, with the added ability to create a link between a Git commit and a Rational Team Concert work item. You create a link by annotating commit messages so that when a push operation is made to a configured shared repository, the commit and the work item specified in the annotation are linked. There is a reason they call it Git Martin.Nally | Nov 15 2012 | 495 Visits A very large portion of the 9 days we've spent working on this project has been spent setting up and learning a lot of new software. No piece of software that we have tackled has been remotely as challenging as Git. We are using Git via the Eclipse plug-in EGit. The user interface is bad, and we have not found any reasonable tutorials to explain what the basic model and operating procedures are. We wasted many hours being defeated by EGIt/Git. Even when we struggled though and got what we wanted to happen, we were often unable to repeat it the next time. The experience was infuriating - I don't often use foul language, but I was sorely tested by Git. I believe Git itself is somewhat challenging. Googling around for solutions and help, I have found POSTs from numerous folks who are struggling and a few who have given up on Git in disgust. Still, Git has become wildly popular, so I have to believe that the general experience that people have had is better than ours. One (unproven) hypothesis I have is that Eclipse.EGit actually makes the experience much worse. If you know exactly what you are doing with Git itself, I think you might be able to figure out how to use Git through EGit, but if you are trying to learn with EGit, the experience is horrible. The developers of EGit (Aptana, I think) are presumably trying to protect our SCM business in RTC. I suspect, but cannot prove, that if we had just used Git from the command line we would have been much happier, at least until we had really learned the concepts, terminology and workflows. Git Outta Here Posted on March 20, 2012 by Jim Ruehlin Lots of people have been liking Git over the last few years. Git is the SCM system created by Linus Torvalds, aka Mr. Linux. But not everyone likes Git and they’re starting to say so. One of the big knocks against Git is its complexity for the user. The information model, command line syntax, and multiple steps required for basic operations are fine with some people but frustrate others. Steveko’s Blog has a great rundown of many of the difficulties with Git. It’s a good read whether or not you’re a Git fan. In other Git news, GitHub was recently hacked. There’s a lot of code up there, and now people are worried about the security of their work. At this point I should warn you that a shameless plug is coming. But since I have no shame… Rational Team Concert’s SCM systems is philosophically similar to Git’s, but doesn’t load up the user with a lot of extra complexity. Git’s patches are much like RTC’s change sets. Both systems have workspace areas locally and remotely, with separate actions required to move code from your workspace to a common delivery area. There are lots of terminology differences, but many similar perspectives on how to get the work done. At the same time, RTC manages to keep the code/check-in/deliver cycle reasonably simple. Check-ins can even be done automatically since the code stays in your own workspace (on the server). And RTC provides licenses for small teams (up to 10 developers) when you download the product. At the same time, RTC includes process enactment, project planning, change management, and other goodies. IBM has also started JazzHub, an SCM hosting environment for academic projects based on RTC. You might want to check this out if you’re part of the academic community. So if you want a Git-like SCM model plus a lot of other integrated functionality, check out RTC. And now I’m putting my Shame Glasses back on. Jazz Build Engine with GIT SCM 0 kathleen sharp (28●2●2●5) | asked Oct 01, 12:47 p.m. I want to use a Jazz Build Engine to build source from GIT. Does anyone have any experience of doing this? My current thought is to have a Build Workspace set up and clone the GIT repo to that at the start of every build, using jgit ant tasks, then build as normal (our other builds use RTC SCM). Is this the recommended approach? One answer Most liked answers ↑|Newest answers|Oldest answers 1 link Nick Edgar (5.6k●2●7) | answered Oct 01, 4:14 p.m. JAZZ DEVELOPER Hi Kathleen, do your other builds do any modifications (delivering changes etc) back to RTC SCM? If not, and it's just a question of getting the latest sources down to the build machine, I would not recommend trying to maintain the code in both SCM systems. In the simplest case, you could create a command line or Ant build definition in RTC, configured to point to a script on the build machine whose first step uses the Git command line to bring in changes from Git. If you want to maintain this script under version control, then you could create an RTC SCM stream and corresponding build workspace just for that, and include the Jazz Source Control option in the build definition to bring the script down to the build machine. One limitation here is that there's no way for the RTC build to do a pre-build check for whether there are new changes in Git to build. This check could be done early in your build script, and if no changes are found the script could invoke our completeTeamBuild Ant task with buildNotNecessary="true", which will close off the build and delete it. Another option is to use Jenkins to run these Git builds, as it has good support for CI builds with Git. With our Team Concert plugin for Jenkins, you could configure the job to refer to a corresponding build definition in RTC, and the plugin will take care of creating an RTC build result corresponding to the Jenkins build, and cross-linking them. From within the main build script, you could still use our other Ant tasks for publishing downloads / logs / compilation- and test results, to the RTC build, like you do for regular JBE-based builds. GIT or RTC source control? 0 1 Leonardo Marzo (176●4●8●12) | asked Feb 04, 1:18 p.m. Hi, We have a large SVN repository, and we're planing to migrate it to either, GIT or RTC SCM. Do you know if there is some comparative analysis done? I would like to know which are the differences between both tools. The cost is not important, I just want to see something like a comparative chart between the features of both, GIT and RTC. We´re currently using RTC for planning, and RQM as testing management tool, so the integration with this tools is a important point to take into account. I will really appreciate your help. Regards, 6 answers Most liked answers ↑|Newest answers|Oldest answers 5 link Millard Ellingsworth (1.9k●1●2●15) | answered Feb 04, 8:00 p.m. FORUM ADMINISTRATOR / JAZZ DEVELOPER I searched a bit on your behalf and could not find anything that is both current and relevant as a general comparison. Given how well integrated RTC SCM is with the rest of the CLM suite, including the build capabilities and build reporting and the fact that you are already using RTC and RQM, I have a hard time imagining what would make Git a better choice for your team(s). Some items you may find helpful: Comparison of Command Line features (GIT, SVN, RTC) at developerWorks Using the Rational OSLC Adapter for Git with Rational Team Concert RTC Git Integrations A slightly older discussion at StackOverflow: http://stackoverflow.com/questions/9369516/using-git-with-rtchow-about-rsync Martin Nally, Rational's CTO, recently blogged about difficulties they had using git (though if you are not using eGit you may have better results than he reports) Reading through some of these, it's hard to imagine choosing Git over RTC SCM when you are free to make any choice you want and are already an RTC/RQM user. Comments Leonardo Marzo commented Feb 05, 8:26 p.m. Thanks for your answer Millard! Guido Schneider commented Feb 06, 3:58 a.m. I think the most important question is "Integration" vs. "Functionality and Performance". We had in the past the concept of a toolchain with "Best In Class". Today, thanks CLM we are complettly switching to the "Full Integrated" Tool Chain because we worked to much on copies of copies because of synchronisations instead of linkeages and we spend to much time in tool connectors maintenance. End user may save time in a individual tool which has some big advantages in one function. But all this saving is more than lost in other areas or by other team members, roles. Millard Ellingsworth commented Feb 06, 12:12 p.m. FORUM ADMINISTRATOR / JAZZ DEVELOPER @schneidg I made exactly this same point (about how local optimization of point tools was uninteresting in the larger scope of the project) with someone that pinged me via email. Even before I worked for Rational my evaluation of various tools pointed to RTC as the best overall experience for the team. 3 link Jim Ruehlin (536●1●4) | answered Feb 04, 8:34 p.m. JAZZ DEVELOPER Here's a short article I wrote that has some high-level comparisons between Git and RTC. It includes a couple of links to other articles about Git that you might find useful as well. The integration between RTC and other parts of the development environment are a big plus. I also think RTC is much easier to use in a day-to-day scenario, while Git is more focused on making life easier for the admin. The to SCM systems have different vocabularies, but similar SCM models in my opinion. Comments Leonardo Marzo commented Feb 05, 8:25 p.m. Thank you Jim, that article was interesting 0 link Stuart (41●2●2) | answered Jul 02, 10:42 a.m. Many of the teams I'm working on have started to move to git. The main reason is that we found scm (Jazz's CLI) to be very hard to use. We really tried to integrate it into our scripted builds but there were just too many problems that we finally gave up. It's a pity because Jazz's overall tight integration between SCM, issue and bug tracking and managing the command development workflows are indeed very impressive. But for the command line junkies in our group, scm was a show stopper. Comments 1 Geoffrey Clemm commented Jul 02, 11:05 a.m. FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER Do you remember what the problems were? sam detweiler commented Jul 02, 1:08 p.m. | edited Jul 02, 4:23 p.m. prior to RTC V4, the SCM CLI was not up par with other SCM tools. so it was near impossible to do some of the actions teams had already used in other integrations. Stuart commented Jul 02, 1:49 p.m. Many issues discussed here. 1 Sreerupa Sen commented Nov 12, 3:55 a.m. | edited Nov 12, 3:56 a.m. FORUM MODERATOR / JAZZ DEVELOPER The command line has actually undergone a huge UX boost this year, as well as a performance boost. We spent a lot of time making it more usable from scripts, generating consumable output in JSON/XML, having a much more predictable syntax, being faster and so on. If you're interested, please have a look at the Plan Items that we've done this year and the last year or are doing this year. 1 Sreerupa Sen commented Nov 12, 3:56 a.m. | edited Nov 12, 3:57 a.m. FORUM MODERATOR / JAZZ DEVELOPER [CCM] Usability improvements in the SCM CLI (272065) [CCM] Improve scriptability of the SCM CLI (169844) [CCM] Reduce functional gaps between the SCM CLI with Eclipse SCM (170275) [CCM] improve performance and responsiveness of the scm command line (249753) [CCM] Further performance improvements for the scm command line (259382) showing 5 of 6 show 1 more comments 0 link Jens Melgaard (36●1●4) | answered Nov 06, 4:34 a.m. After 3 years or so with RTC, I can't vouch for it in any way... It is not just the command line that is flawed as @stuart points out, there are allot of aspects in RTC that is implemented poorly, the tight integration may impress some (not me), but what does it matter when all the interfaces on top of it is poorly designed and becomes a pain to use. There are much worse contenders out there, but there are also tools that is far greater IMO... RTC Tasks and Planning: I would take Jira/YouTrack/Mingle... RTC Source Control: I would take TFS, SVN, GIT, Mercurial etc... RTC Builds: I would look at TeamCity, Go, Bamboo... RTC keeps pointing it's "integration" out as the best thing ever, but there are so many 3rd party options for the other SCM's that integrates flawlessly so it is an academic exercise at best to pull that argument... At the end, ones a SCM starts overwriting my local files in unexpected situations (like accepting incoming changes) all my trust for it goes out the window. Comments Darcy Wiborg-Weber commented Nov 06, 3:30 p.m. Hi Jens, I'm sorry to hear that you've had a bad experience. Can you provide more information about the problems you had with local files being overwritten? Can you point us at a work item? Jens Melgaard commented Nov 07, 4:28 a.m. | edited Nov 07, 5:02 a.m. @Darcy Since the Task and planning part of RTC is so horrible to search in I can't find that for you, (or I won't bother to spent time on figuring it out rather)... I will leave the search to you instead (Eat your own dog-food as they say)... I am added as subscriber to a range of issues reported, but I report them internally in our organization and then they report them to IBM so I don't directly have a number or link... This issue should be in there, it may however be reported under it's root cause which is that you overwrite files at all doing a number of operations: (continued) (Many might be directly linked to that we use RTC in Visual Studio) Jens Melgaard commented Nov 07, 4:40 a.m. RTC Overwrites your local files during these operations where it shouldn't: - Accepting incoming changes, although RTC does bring up a dialog stating this and offers to check in changes, this all falls apart combined with the fact that RTC is inherently bad at discovering files that are changed outside your IDE, it also ignores files which you started to change but didn't yet save (which is a DARN common thing)... At the end of the day... This all points to a major flaw in RTC where the relationship between your Sandbox and Workspace is not considered separate streams/branches, but something that should always be in complete sync... Git/SVN/TFS would require you to merge incoming changes into your sandbox, not just overwrite. - Synchronizing your workspace and sandbox, an idea that shouldn't even exist, this is considered as an "error" situation, however one that you will easily get into. Basically it seems that canceling any SCM related operation tends to leave you out of sync, like cancel a suspend, check-in etc. (Joke: Maybe write "break my sandbox" on that button instead, it's what it seems to do anyways?) Jens Melgaard commented Nov 07, 4:47 a.m. - The unexplained situations, I have seen other situations than mentioned above, but I have yet to be able to put my finger on it, but it might have been in a combination of things (files not saved, files RTC didn't discover changes it or others). At the end of the day, there should be a single situation where RTC reverts your changes, and that is when you ask it to Undo, Discard CS are acceptable situations, although It would be nice if you could say Discard CS and then get the changes down into your sandbox like you can with git, but I think there is other tools in RTC to leverage the use-cases catered by that git feature (e.g. that you can move changes between change sets) Jens Melgaard commented Nov 07, 5:02 a.m. And beginning to talk about Undo and Discard, when it comes to those a new set of issues just arises... When I have accepted incoming changes and then merged a file and good to go but down the road says... hey I no longer need my own changes to this file because I did a refactoring, guess what I can't do... Undo that file... An operation what would basically put that file in the state it is in the current "head" or change my workspace is currently based on. But RTC denies that possibility... There is a workaround however... Move that merged file into it's own change-set and kill that change-set (discard)... But that is just silly. I have also been in situations where I can't revert files, even if I wanted to as they would create a fork/conflict... This for a file which when comparing it to the one on the remote stream I am tracking has no changes. Which brings me to yet another thing. Files that has no changes at all are still recorded as changes in RTC on occasion. Add a line-break, check-in, remove line-break, check-in - file remains a change. And that's what I have time for mentioning for now. showing 5 of 13 show 8 more comments 0 link N Z (111●8) | answered Nov 10, 4:56 p.m. Integration is very important, and since you are already using RTC and RQM, then extending the use of RTC to use scm is something that is hard to ignore. On the other hand, I think the SCM component of RTC is probably the weakest part of the product. Functionally, it's ok, but all the interfaces are poor, limited and/or confusing, including eclipse, lscm, windows explorer and the web interface. In the 2 organisations that had RTC I have worked in, in the first, project teams were given the option of SVN and RTC/scm and after being shown both, and the pros/cons, they nearly always picked SVN, in the other organisation, they use RTC extensively, except for the scm component. Having said that, you should definitely trial it out, YMMV. Comments Sreerupa Sen commented Nov 12, 4:26 a.m. FORUM MODERATOR / JAZZ DEVELOPER Hi N Z, Would you be able to elaborate a bit more on the RTC interfaces - what we can do to improve them? When you say they're limited, is it w.r.t other competing tools, or you're talking about feature parity between the RTC Clients? For lscm - is it not at par, not consumable easily, or is it's UX an issue? For the Windows Explorer, is it not rich enough or are the work flows not what you expected? Or is it the SCM model that you'd like for us to improve? I work on the RTC Clients, and one of my tasks is to improve user experiences on the different clients we have. We've done some good UX/Client parity improvements on some of the RTC Clients this year, but I know that there's a lot of scope for improvement so your feedback would be really valuable. Thanks --Rupa 0 link Stuart (41●2●2) | answered Nov 12, 9:06 a.m. Thanks for all the additional info. If the need ever arises I'll give the revised scm a shot. You have to remember that unlike with git, our team doesn't typically have a choice about what version of scm to use. Our RTC infrastructure is maintained by others and we only recently (within the last 6 months) got a 3.x server. Given how long it took to get there from our antiquated 2.x server, I'm not optimistic that I'd have the opportunity to even try the latest CLI anytime soon. Even if if I could get my hands on the latest version tomorrow, I don't know that it'd be an easy sell on my teams. The ease and flexibility of git (we really like the fact that every cloned copy of a repository is itself a working repository) has really made it the go to scm platform on most of our recent projects. Via gitweb, we're able to almost integrate (close enough for our purposes) our scm and other components.
© Copyright 2025 Paperzz