Many managed servers use CentOS, the commercial version of RedHat Linux. If you can find a source repo with git in it, you can install using yum:
yum install gitHowever, you're quite likely to come up against dependency errors, because some dependencies for git are not in the source repo:
Error: Missing Dependency: perl(Error) is needed by package git-18.104.22.168-1.el5.x86_64 (epel) Error: Missing Dependency: perl-Git = 22.214.171.124-1.el5 is needed by package git-126.96.36.199-1.el5.x86_64 (epel) Error: Missing Dependency: perl(Git) is needed by package git-188.8.131.52-1.el5.x86_64 (epel)One solution is to install each package individually as an RPM. Use rpmfind.net to find the packages you need. You will need to install the same version of git as of perl-Git.
For CentOS, I got the latest git and perl-Git versions listed for the "Extras Packages for Enterprise Linux 5 for x86_64" distro with EL5 (I knew I had EL5 as it appeared as part of yum's output when I did a yum update). For perl(Error), I grabbed the latest version showing for "DAG packages for Red Hat Linux el5 x86_64".
Once I'd downloaded these three RPMs with wget, I installed them with the following:
rpm -i git-184.108.40.206-1.el5.x86_64.rpm perl-Git-220.127.116.11-1.el5.x86_64.rpm perl-Error-0.17016-1.el5.rf.noarch.rpmNow that git's installed, you can set up the repository. Go to the folder where the source files are (or will be), and enter:
git initIt'll say that it's initialised an empty repository at .git, even if you have source files in there. This is because you need to add those files and then commit them:
git add . git commit -m "initial import"The following command will confirm that all has gone to plan:
git statusHopefully this will tell you "nothing to commit (working directory clean)". Your git repository is now ready to be cloned by any devs who need to work on that code.