Got Git? Then Git Going!

Y’all got Git?  Then ‘Git’ going by connecting your GitHub repository to your Stat Repository.  And by golly, you’ll be versioning Git code quicker than two shakes of a sheep’s tail.
So here’s what I’m fixin to do.  This here’s the first in a series on Stat and 3rd party Version Control Management (VCM) applications.  (Perhaps with a bit less southern flair and high cotton.) 




What’s Git?

According to https://git-scm.com/ Git is the following:

“Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency.”

Q: Is there a difference between “Git*  and “GitHub*”?   

A: You Betcha! Please refer to each of the hyperlinks to see what those are.  For simplicity, we will use “GitHub” for our work.  
A concise difference statement can be found at the top of this page on https://help.github.com/articles/set-up-git/ which states the following:

At the heart of GitHub is an open source version control system (VCS) called Git. Git is responsible for everything GitHub-related that happens locally on your computer. 
If you're not comfortable using the command line right now, GitHub lets you complete many Git-related actions without using the command line…

Let’s Talk!  (Stat & GitHub Connectivity)

We’ve been using another VCM application along with Stat.  Now we want to hook GitHub into Stat.  How can we do that?

I’m glad you asked partner!  At this point we will assume you have already created your GitHub account, have repositories created, and have confirmed connectivity/version control with GitHub.

Whoa Little Doggie! Before you make a connection, let’s be sure of a few things:

  1. You must be running Stat 5.7.3 or above.
  2. You must have a valid GitHub user ID and Repository stood up and populated.
  3. Ensure your Stat Central Agent (SCA) is up and responding.
  4. Ensure that there is a version of Git running on the Stat Central Agent machine.  It will need to call the application executables in order to work successfully.
  5. In GitHub, ensure the “Default Shell” is set to “Cmd” for Stat to be able to interface with GitHub.

Let’s “Git” Connecting!

Ah-Yup!  The following steps should allow you to quickly connect your current Stat 5.7.3/+ into your GitHub Repository:  

(You will need “Stat Administrator” privileges to make this connection.) 

Within Stat: Go to “Maintenance > General > VCM Connect”.

Select “New” to create a new row in the VCM connection table.  Enter in values to define your GitHub connection and select the “Apply” button.  

Next, select the “Setup” button.

This will open a new window entitled “VCM Connection Setup – {Your VCM Name}”.

Since GitHub always uses a secure connection be sure that the “GIT_CONNECTION_TYPE” is set to “https” for HTTP –Secure.

In the “GIT_HOST” field, enter only the following: “github.com/Your_GitHub_Acct_Name”.
- No leading “https” or “www” entries.
- Ensure no trailing backslash“/”. 
- No spaces or other values after the account name.

In the “GIT_REPOSITORY_PATH” field, enter a leading backslash, "/", then your GitHub repository.  (See below screenshot.)

Letter case matching is not required.  “StatCode” is the same as “statcode” to both Stat and GitHub.

Enter your “GIT_USERNAME” and “GIT_PASSWORD” in the fields provided. 

If your connection entry looks similar to the screenshot below than select “Apply” to save your new entry. 

Once saved, select the “Test Connect” button in the upper right corner of the window. 
If all your values are proper, you should receive the “Successful connection to {Your_GitHub} server” message. 

If things done gone a bit cattywampus on ya, see Appendix A below for tips on connecting.

And that’s the connection setup and verified all pretty like.   

In the next entry of the series we will continue by using Stat to version control our objects from GitHub by adding objects to Stat Archive Sets.

I reckon it’s time to get on down the line now.  Thanks for taking the time to read this here paper and I hope y’all done found it informative. 

Y’all, comeback real soon!

Much Obliged,

William R. Hart

Solutions Architect

Dell | Pre-Sales, Quest, Inc.

* Git, GitHub and Git/GitHub logos are copyright 2015 GitHub, Inc.  All trademarks, service marks, trade names, trade dress, product names and logos appearing on the site are the property of their respective owners. 

Any rights not expressly granted herein are reserved.

Appendix A: Tips & Troubleshooting a Git Connection:

When establishing a connection do not place any leading “https” values in the GIT_HOST Field. Begin the entry with “github.com/Your_Account”.  

Begin the entry with “github.com/Your_Account

The second thing to check is that one, and only one, of the entries has a backslash such that it forms a valid path when sewn together as follows: 

 

The above highlighted box is missing a forward slash, "/", between the Account Name (wrh34685) and the Repository Name (StatCode).

Anonymous