Github: Why do I need it? [closed] - windows

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 10 years ago.
Improve this question
I am still quite unsure how to use it, but I just downloaded Git and I was setting it up according to their web page. The section on password caching says if I don't have to enter my password every time, I can use Github for Windows. I was confused so I found a question here asking "what is github anyway?" and the answers say it's a website or it's web hosting. So I clicked the Github for Windows link on the how-to page and next thing I know I'm downloading an .exe file.
If Github is a website, why do I need an .exe file?
Is the only benefit to not type in your password?
How does Github relate to Git Bash?
Are Git and Git Bash the same thing?
P.S. I have 2 computers, 1 is XP and the other Win7. The downloads I'm talking about were on the XP but I will also put it on the 7 if I can determine that I need it.

How does Github relate to Git Bash?
Are Git and Git Bash the same thing?
The latter question first: Not exactly. Git is a collection of programs allowing you to track changes in source files (really any kind of non-binary file and some binary files). Git Bash is one of the ways to actually run Git on Windows. Since Git was written for Linux, it relies heavily on Unix-like functionality which isn't present in Windows; that problem is solved by msysGit, a package containining Git and a Unix compatibility layer.
Git Bash is the version of the Bash shell, provided as part of msysGit. If you're familiar with the Windows command prompt, Bash is basically like a Unix/Linux equivalent. It opens a command-line window where you can type Git commands or other commands.
The former question: GitHub for Windows is another, GUI-based Git client. I don't have it myself to check, but from what I've found online it looks like GitHub for Windows includes msysGit also, and thus Git Bash. But you shouldn't need to use Git Bash much (if at all) with GitHub for Windows.

the exe is simply a windows interface to sync code to the github website (where you can track changes and then download it to your other computer)
normally you use a command line interface to control git (bash is a linux command line- 'git bash' would be for linux command line)

Stick with msysgit on the command line. The GUI client leaves a lot to be desired. you don't get command history, you don't get tab completion, you don't get scripting and you don't get piping.
You will also find a lot more material on line to help you if you use msysgit or git on Linux.

git is a version control system.
Github is a web service providing webspace that is accessible via the git version control system.
git can be used without Github.
There are several clients that "implement" git (e.g. TortoiseGit or the "original" git) on various platforms.
Github for Windows is an application facilitating work with Github, but not necessary for using Github or git.

You should visit github home, it says following:
"Git is an extremely fast, efficient, distributed version control system ideal for the collaborative development of software."
Basically Github is a hosted repository for your software source code. It maintains versioning for your source code files and you have various plans for that. For example if you are planning to host an open source project you can host unlimited of them with free account while if you want private repository you have to start looking for some paid plan.
It's social development environment on top of Git version control system. It similar to SVN, Microsoft VSS but it's hosted while if you use Microsoft VSS, generally we host it on intranet by setting up some VSS Server in network itself.
Windows Binary file (.exe) is the tool to manage your repositories/project directories on GitHub and get it synced on local / repos. So more like VSS Client but much much different at the same time.

Related

where to download GIT for windows? [duplicate]

I want to install git on windows. my main interest is using it from command line rather than a gui.
Googling takes me to http://code.google.com/p/msysgit/downloads/list but this has words like preview and beta - gives me a cool feeling. Where can I download it and which version.
I am using the msys based version of git on Windows. It's actually really well done. You get lots of niceties for free like bash tab completion, branch indication, gitk is hooked up, etc.
The fact that they are unwilling to call these releases "final" has never been an issue. I've never had any problems.
And btw, github sends you to that installer for git on Windows too. Which should give you a bit more confidence.
gitforwindows.org and git-scm.com are both legit.
The Download for Windows page links to git-for-windows.github.io, which is now a redirect to https://gitforwindows.org/.

GIT GUI client on Windows for Unix GIT installation

Our company programs and runs data analysis on a Linux server. The programming is done in Windows clients (SAS, generally). Each project is only programmed by one person and is reviewed by another.
We would like to put our projects under version control but leave the code on the server (ie not pulling to local Windows repositories). The advantage is incremental backup and helps with confirming changes from the reviewer.
Does anyone know of a Windows client that can read remote repositories but perform GIT actions using GIT on Linux, rather than on Windows? Trying a few clients (e.g. SourceTree and SmartGIT) suggests only the latter is possible.
Thanks, Rich
One way to achieve what you want is to export the directories containing the Git repositories on your server over CIFS (via Samba) and then mount them as network disks on your workstations.
But really I can't understand what's wrong with using Git the normal way.
Deployment is best done using native packages for the target system (hard to do on Windows, I admit) or a tar.gz archive (doable using git archive) or a tool like git-ftp or rsync.
If you need code review, consider using Gerrit.
As to backups, each Git repository clone is, in a sense, a set of differential backups of itself. That is, the more (local) clones you have the safer you are.

Is there a good way to work with a remote git repo in Windows?

I want to be able to use Windows-based development tools (e.g. Winmerge, Eclipse, etc.) on a repo sitting on a remote Linux machine. With my current setup, I issue git commands in a shell via VNC, and therefore use the Linux-based tools -- kdiff3, gitk, gedit, etc. I do have access to all elements in the repo (source, .git/, etc.) via a Samba share. With this share -- mapped to a Windows network drive -- I work with whatever version my current git branch is pointing to.
Is there a Windows-based solution that works with a remote repo (say, over SSH) that allows me to execute the majority of my workflow (checkout, commit, diff, merge, etc.)?
Have you tried msysgit? Its a cygwin mingw based git client for Windows. I used it while I was using Windows and it works fairly well.
GitExtensions is a Windows GUI around msysgit, mentioned by Chaitanya. It has drawbacks but allows most Git operations to work in a graphical interface. I use it since I switched to Git.
You can use TortoiseGit to manage a clone of the repo right on your local machine. Your IDE should then be able to perform git operations directly on it. (Well, NetBeans can at least, I'm not an Eclipse user, so I'm not sure what git support it has built-in.)
MsysGit and the Git Gui are pretty effective from Windows. Start here
I have found that they do all the basics pretty well, and then I swap over to a git bash window [a git/unix version of a DOS cmd window, though more powerful] for the more specialist commands.
It has worked quite effectively and doesn't need any great expertise.

Git on windows :| [duplicate]

This question already has answers here:
Using Git on Windows
(5 answers)
Closed 5 years ago.
i've been experimenting with git as my personal code rep.. and it has been a bit of a disaster with windows.
i've used Subversion, CVS, and Perforce in the past.. none were as annoying to use as git.
i've figured out the PGP part (for github), although my workstation no longer lets me check in, and after searching around it turns out that git bash is using putty which is not that reliable and should be configured with something else..
i was not able to configure it with windows shell extension for a nice visual of what is part of the repository, what is modified, and easy check ins, and easy pushes..
has anyone successfully configured some kind of windows shell client and can efficiently and quickly synchronize various machines?
It just seems to be more pain to use than it is worth..
I use http://code.google.com/p/msysgit/ to great success. I get a nice cygwin bash shell. And even git gui works just fine.
I avoid all shell extensions (except for git-bash shell here, which is trivial) the vast majority of easy things can be achieved from git gui and gitk
My advice is to stay away from cygwin git. I found it unreliable, and making it use an ssh agent like pageant is a nightmare. msysgit and plink is the best combination. Also, don't mess around with line-endings: check out as-is, commit as-is.
As a graphical frontend, I like Git Extensions, which comes bundled with msysgit, and is more reliable than TortoiseGit, which is a shell extension that frequently takes down the entire Windows Explorer in flames...

Setup a Git server with msysgit on Windows [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
My friends and I are trying to setup Git for Windows using the tutorial Git Server: Gitosis and Cygwin on Windows, but we just keep running into problems.
What would a "Setup Git Server" guide for Windows using msysgit be like?
There is a comment in the tutorial above suggesting it can't be done with msysgit because gitosis requires the use of an SSH Server and Bash? What is a step by step guide (as there is not one available)?
Install mysisgit
?
I found this post and I have just posted something on my blog that might help.
See Setting up a Msysgit Server with copSSH on Windows. It's long, but I have successfully got this working on Windows 7 Ultimate x64.
Bonobo Git Server for Windows
From the Bonobo Git Server web page:
Bonobo Git Server for Windows is a web application you can install on
your IIS and easily manage and connect to your git repositories.
Bonobo Git Server is a open-source project and you can find the
source on github.
Features:
Secure and anonymous access to your git repositories
User friendly web interface for management
User and team based repository access management
Repository file browser
Commit browser
Localization
Brad Kingsley has a nice tutorial for installing and configuring Bonobo Git Server.
GitStack
Git Stack is another option. Here is a description from their web site:
GitStack is a software that lets you setup your own private Git server
for Windows. This means that you create a leading edge versioning
system without any prior Git knowledge. GitStack also makes it super
easy to secure and keep your server up to date. GitStack is built on
the top of the genuine Git for Windows and is compatible with any
other Git clients. GitStack is completely free for small teams1.
1 the basic edition is free for up to 2 users
With regards to the reference to the Tim Davis page - Setting up a Msysgit Server with copSSH on Windows - I used this to get a Git server running on Windows 7 Home Premium 64.
Below is a postmortem/update of what I learned in addition to his instructions.
Like Tim Davis said, this was an arduous and frustrating process, at least for me - I'm not too good with integration of this sort, but I learned alot in the process. I hope my pain benefits someone else in the future, because this was an arduous process.
There is a step to copy all the Git
executables into your CopSsh bin
directory. Instead of copying files
and figuring out which files are
needed, add the git bin path to your
git path. I did so by modifying my
.bashrc and CopSsh profile.
Here's what I added to .bashrc (in your CopSsh and Windows home directory):
gitpath='/cygdrive/c/Program Files (x86)/Git/bin'
gitcorepath='cygdrive/c/Program Files (x86)/Git/libexec/git-core'
PATH=${gitpath}:${gitcorepath}:${PATH}
Here's what I added to the bash profile (in CopSsh etc/profile):
gitpath='/c/Program Files (x86)/Git/bin'
gitcorepath='cygdrive/c/Program Files (x86)/Git/libexec/git-core'
export PATH="/bin:$syspath:$gitpath:$gitcorepath:$winpath"
There is some duplication here - it works for me, so someone chime in which is the correct place to modify the path.
The newer msysgit versions might not give you
the screen to choose the ssh
executable where you choose between the Git
ssh and PuTTY ssh. You'll have to
set GIT_SSH manually if you use PuTTY.
I didn't follow one part of the
instructions and that was installing
Tortoise - I used the command line
instead as that's how I prefer to
learn a vcs like I did with rcs and Subversion and
found that to work for me. I had
problems with the clone command
using ssh. Here's how I did it:
Git clone using ssh - can't find repository
This is where I banged my head the most.
The CopSsh install directory was
/Program Files (x86)/ICW. I got
away with this, but if I were doing
it again, I'd use a directory name
with no spaces.
These other sources helped me figure things out:
Another way to setup a Git server
on Windows:
http://code.google.com/p/tortoisegit/wiki/HOWTO_CentralServerWindowsXP
The client side of things:
http://toolmantim.com/thoughts/setting_up_a_new_remote_git_repository
An explanation of Git as a server
(not related to Windows, but a more
in depth look than installation
steps):
http://progit.org/book/ch4-0.html
Plus O'Reilly's Version Control with Git - the Remote Repositories chapter.
In retrospect, if I had known how time consuming this would be, I might have started out with Mercurial as I read the install on Windows is easier, but I'll have an opinion on that after I work with Git awhile and then try Mercurial.
I am not sure why anyone hasn't suggested http://gitblit.com. Pure java based solution, allow HTTP protocol and really easy to setup.
After following Tim Davis' guide and Steve's follow-up, here is what I did:
Server PC
Install CopSSH, msysgit.
When creating the CopSSH user, uncheck Password Authentication and check Public Key Authentication so your public/private keys will work.
Create public/private keys using PuTTygen. put both keys in the user's CopSSH/home/user/.ssh directory.
Add the following to the user's CopSSH/home/user/.bashrc file:
GITPATH='/cygdrive/c/Program Files (x86)/Git/bin'
GITCOREPATH='/cygdrive/c/Program Files (x86)/Git/libexec/git-core'
PATH=${GITPATH}:${GITCOREPATH}:${PATH}
Open Git Bash and create a repository anywhere on your PC:
$ git --bare init repo.git
Initialized empty Git repository in C:/repopath/repo.git/
Client PC
Install msysgit.
Use the private key you created on the server to clone your repo from ssh://user#server:port/repopath/repo.git (for some reason, the root is the C: drive)
This allowed me to successfully clone and commit, but I could not push to the bare repo on the server. I kept getting:
git: '/repopath/repo.git' is not a git command. See 'git --help'.
fatal: The remote end hung up unexpectedly
This led me to Rui's trace and solution which was to create or add the following lines to .gitconfig in your Client PC's %USERPROFILE% path (C:\Users\UserName).
[remote "origin"]
receivepack = git receive-pack
I am not sure why this is needed...if anybody could provide insight, this would be helpful.
my git version is 1.7.3.1.msysgit.0
GitStack should meet your goal. I has a wizard setup.
It is free for 2 users and has a web based user interface. It is based on msysgit.
There is a nice open source Git stack called Git Blit. It is available for different platform and in different packages. You can also easily deploy it to your existing Tomcat or any other servlet container. Take a look at Setup git server on windows in few clicks tutorial for more details, it will take you around 10 minutes to get basic setup.
You don't need SSH for sharing git. If you're on a LAN or VPN, you can export a git project as a shared folder, and mount it on a remote machine. Then configure the remote repo using "file://" URLs instead of "git#" URLs. Takes all of 30 seconds. Done!
There may simply not be such a guide. If so, you may not have much luck convincing anybody to write one, because it would be a lot of work.
I would recommend either of two things. The easier one is to follow the guide you have slavishly, which means forgetting about msysgit.
The harder one is to put up a Linux server - perhaps as a guest under Windows using VirtualBox (free) or VMWare or Parallels (pay), and then follow one of the many sets of instructions Google will lead you to. But you will probably find those instructions are insufficient - they usually assume you've already set up an ssh server, for example, so you have to get that info elsewhere. I've done that twice, and can say that unless you're already something of a Linux guru, it will be a struggle.
I did what Bob Murphy suggested was the "hard" option.
I installed Ubuntu under VMWare Server (free) at work and then followed this guide on setting up Gitosis. I found it much easier than trying to get it going under Windows. Once it's set up you really don't have to touch it because Gitosis administration can be done from Windows by pushing updated versions of the gitosis.conf file. Any work I do need to do on the server directly is done via PuTTY so I don't have to use the horrible VMWare Server interface.
I've recently been messing around with VirtualBox at home and I've found it much nicer/easier to work with than VMWare Server, so it may be worth looking at that.
I just wanted to add my experiences with the PATH setup that Steve and timc mentions above: I got permission problems using shell tools (like mv and cp) having Git's shell executables first in the path.
Appending them after the existing PATH instead this solved my problems. Example:
GITPATH='/cygdrive/c/Program Files (x86)/Git/bin'
GITCOREPATH='/cygdrive/c/Program Files (x86)/Git/libexec/git-core'
PATH=${PATH}:${GITPATH}:${GITCOREPATH}
I guess CopSSH doesn't go along well with all of msysgit's shell executables...
I'm using GitWebAccess for many projects for half a year now, and it's proven to be the best of what I've tried. It seems, though, that lately sources are not supported, so - don't take latest binaries/sources. Currently they're broken :(
You can build from this version or download compiled binaries which I use from here.

Resources