Questions tagged [git]
Git is a distributed revision control system with an emphasis on speed.
820
questions
245
votes
15
answers
383k
views
How do I show the git branch with colours in Bash prompt?
I am using this guide to show the branch name in gnome terminal (Ubuntu 15.10) when working in a git repository. Based on the above I now have the below in my ~/.bashrc file:
# uncomment for a colored ...
228
votes
13
answers
333k
views
Is there a GUI client for Git?
I am using git for version control of various projects.
Is there GUI software for navigating through commits and branches of a project and for retrieving versions in git projects?
204
votes
5
answers
182k
views
Really verbose way to test Git connection over SSH?
When using GIT, I have problems with using GIT over SSH, and since it works just fine both from work, and at home with a different modem, it's obviously my home modem that is acting up. I have no ...
180
votes
11
answers
243k
views
Enter SSH passphrase once
Before upgrade
When I was running git clone git@... (using ssh) once per computer restart a window dialog appeared containing a textbox for inserting my SSH passphrase and confirmed with OK. Then the ...
143
votes
4
answers
74k
views
How do I install the latest version of Git with apt?
I read about a security flaw in Git, which was fixed in version 2.2.1. I currently have Git 2.1.0 on my system (Ubuntu 14.10), and tried to reinstall it with apt. However, apt told me that I currently ...
109
votes
8
answers
373k
views
git config global file - remove settings
The following command:
$git config --global --list
gives me:
user.name=test user
user.name=gotqn
I want to remove the first name. I referred to this article and have done the following commands ...
91
votes
4
answers
118k
views
WSL Ubuntu Distro | How to solve `Operation not permitted` on cloning repository
I am running Ubuntu 18.04, as a Subsystem for Windows. I have done this in mutliple PCs and never had this problem. I try to to git clone <repo>, and I get this:
Cloning into '<repo>'...
...
77
votes
3
answers
99k
views
How to remove offending key in git when you try to push your changes?
I've done tons of search and tested different solutions, but gain no success!
When I want to push my codes, I receive the following error:
Warning: the ECDSA host key for 'git.mywebsite.ir' ...
71
votes
4
answers
51k
views
What is the correct way to use git with gnome-keyring and http(s) repos?
Currently, whenever I git pull or git push to a http(s) repository, I get the following:
$ git pull
Username for 'https://gitrepos.reposdomain.com': me@mydomain.com
Password for 'https://me@mydomain....
69
votes
3
answers
198k
views
"error: gnutls_handshake() failed" when connecting to https servers
When I try to connect to any HTTPS server with git, it gives the following error:
error: gnutls_handshake() failed: A TLS packet with unexpected length was received. while accessing ...
fatal: HTTP ...
67
votes
1
answer
31k
views
What are the differences between the git and git-core packages?
Why there is a git package and a git-core package? Is there any difference?
65
votes
4
answers
24k
views
Nautilus Git integration
Is there any equivalent to TortoiseSVN but for Ubuntu / Git? I'd like to integrate Git commands to Nautilus.
64
votes
3
answers
147k
views
How to start git-gui?
I've installed git-gui tool via sudo apt-get install git-gui. But how do I start it? Trying with search or git-gui command did not find and UI tool for Git.
60
votes
2
answers
57k
views
Upgrade Git version on Ubuntu 14.04
Can please somebody tell me what is wrong with this?
I run
$ sudo apt-get purge git; sudo apt-get autoremove; sudo apt-get install git
Reading package lists... Done
Building dependency tree
Reading ...
57
votes
8
answers
132k
views
Setting up a git server
I've recently set up ubuntu-server on Amazon EC2. I would like to use it as my git server, so I could store my repos there.
So, where can I find some detailed instructions of how to setup git on ...
47
votes
4
answers
164k
views
How to install git-lfs on Ubuntu 16.04?
I am trying to install git-lfs package and it looks like expected paths are not Ubuntu friendly. From Downloads section of git-lfs I choose Linux AMD64 file name git-lfs-freebsd-amd64-1.2.1.tar.gz, ...
46
votes
9
answers
305k
views
How to clone only some directories from a git repository?
For example, I want to download PCL 3d_rec_framework.
This is the git repository of PCL: https://github.com/PointCloudLibrary/pcl.git
How can I download this directory?
https://github.com/...
46
votes
8
answers
9k
views
Is it bad practice to git init in the $home directory to keep track of dot files?
I want to backup and sync my dotfiles using github. Since all the dotfiles resides in $home by default, should I just git init in my $home folder, or is that a bad idea?
Having performed git init in $...
41
votes
3
answers
22k
views
Difference between installing git vs installing git-all
What's the difference between
sudo apt-get install git-all
vs
sudo apt-get install git
Is there any advantage of installing either or all?
38
votes
2
answers
156k
views
How to access a git repository using SSH?
I have the public key. I think this is needed for the SSH connection to the server where the git repo is located.
Now I don't know how to get the code. Can someone please tell me the complete ...
35
votes
4
answers
40k
views
Why do I get this warning from Gnome keyring in Xubuntu?
I have installed xubuntu-desktop ontop of a stock Ubuntu installation.
When using ssh, or more specifically git, I always get this warning
WARNING: gnome-keyring:: couldn't connect to: /tmp/keyring-...
35
votes
2
answers
21k
views
How can I get GPG Agent to cache my password?
I'm a developer, and I commonly sign my Git commits with my GPG key. I've been able to get GPG Agent working properly on OSX so that it only asks me for my password once per day, but I'm having ...
34
votes
1
answer
77k
views
How to fix processing with runit and git-daemon-run
I'm trying to install Django using
sudo apt-get install python-django
But I'm getting error
Reading package lists... Done
Building dependency tree
Reading state information... Done
python-...
34
votes
8
answers
13k
views
How to alias 'git' to 'g' so that bash-completion rules are preserved?
If I do this:
alias g='git'
I loose all completion rules (i.e. branches and remotes are no longer being automatically completed when I hit TAB after typing, for example g push o).
34
votes
3
answers
5k
views
youtube-dl from git no longer available
Right now I would download a small video from walkthroug from a game. so I started with
alex@Guilmon:~/Videos$ sudo youtube-dl -U
ERROR: can't find the current version. Please try again later.
alex@...
31
votes
5
answers
7k
views
Creating a Git repo at / (root) for tracking settings?
So I use Git mostly for development purposes, but I just realized that I could use it for storing versions of the settings files I have on my Ubuntu installation.
My proposed setup is:
git init a ...
29
votes
0
answers
25k
views
How to setup a Git server? [duplicate]
I am trying to setup a Git server could. Can anyone tell me how to set up a Git server, so that client machines can connect to that server and make use of Git version control for their projects... ...
26
votes
3
answers
118k
views
E: Unable to locate package git
I am trying to install git, I used sudo apt-get install git command and it results:
E: Unable to locate package git
This question have been asked by many people but not a single answer has fixed my ...
25
votes
2
answers
154k
views
ssh: connect to host github.com port 22: Connection refused
So I followed the guide on how to add a SSH key to GitHub, and added a new SSH key with a passphrase to GitHub and the SSH agent. Now, if I run ssh -T g[email protected] as described in the guide to test ...
22
votes
5
answers
23k
views
"Unable to connect to Upstart" error when installing git-all
I am using 15.04.
So I'm working with git and I installed the standard version. I set up the ssh keys and was able to clone one of my repositories to the correct folder. Everything was working great ...
22
votes
3
answers
6k
views
Can I scroll to new lines using mouse wheel inside git diff?
I'm using Ubuntu 16.04 default terminal (it's GNOME I believe?)
The problem I'm facing is that when I use git diff command to inspect my local changes I can scroll up/down using the mouse wheel, but ...
22
votes
2
answers
20k
views
How to use multiple ssh keys with different accounts and hosts
i have multiple ssh keys and i have also have account on bitbucket and github. how when ever i use pull it gives me error
:/var/www/proj$ git pull origin master
conq: repository access denied.
fatal:...
21
votes
2
answers
27k
views
Change git's language to English without changing the locale
My locale is German. LANG=de_DE.UTF-8. I would like to keep it.
Is it possible to change git's language to English without changing the locale?
21
votes
4
answers
30k
views
Prepend current git branch in terminal [duplicate]
How can I configure the terminal to display the current git branch?
I'd like to see the second line rather than the first:
andy@bob:~/my_projects/project_x$
(master)~/my_projects/project_x$
I don'...
21
votes
2
answers
5k
views
Git on Launchpad
I develop most of my code in Git repos, now that I've become slightly more active on Launchpad I've started picking up Bazaar which has two "small" difference from Git's workflow that ride against how ...
21
votes
2
answers
2k
views
How do I submit a patch to a Launchpad project?
With a Git/GitHub background and knowing very little about Bazaar VCS, I would like to occasionally report a bug to projects hosted on Launchpad, and even send a patch. I'd like to do it in a "proper"...
20
votes
1
answer
16k
views
Gitkraken won't open gui
When I try to run gitkraken, the app does not open. This is a brand new installation of Ubuntu 18.04. When run in the terminal it puts out this:
Gtk-Message: 23:23:20.033: Failed to load module "...
20
votes
4
answers
13k
views
How do you install hub (git wrapper) on Ubuntu with autocomplete and man documentation working?
According to the official docs you just download a pre-compiled binary but this would leave things like man documentation and autocompletion not working.
20
votes
2
answers
62k
views
key_load_public: invalid format with scp or git clone on Ubuntu 15.10
After a fresh install of Ubuntu 15.10, when using scp or git clone, I get the following warning (the command itself doesn't fail): key_load_public: invalid format
How can I get rid of this warning?
...
20
votes
2
answers
27k
views
How do I setup SSH key based authentication for GitHub by using ~/.ssh/config file?
I am trying to set up my SSH keys for GitHub and created a new SSH key for the same. I have managed to setup the SSH key but I wish to retain these settings and save them in the configuration file ~/....
20
votes
3
answers
3k
views
Using Git as off-line alternative for Dropbox
I am working with lots of text files daily and I use Dropbox as a way to restore earlier versions of files in case something goes wrong.
I am looking for simple way to suplement/replace Dropbox in ...
19
votes
8
answers
162k
views
Trouble setting up git error: could not lock config file
I'm getting this error when trying to set the global config:
$ git config --global user.name "Your Name Here"
error: could not lock config file /pathto/file/.gitconfig: No such file or directory
and ...
18
votes
1
answer
28k
views
Intellij unable to fetch from git
I've cloned an existing git repository. Git is working fine when I pull using command line. However, when I try doing the same from Intellij, it says
Fetch failed. Fatal : Could not read from remote ...
18
votes
4
answers
30k
views
How to execute a Bash script from Github?
Say this I have the following file my_cool_file.sh in a Git repository in Github (or BitBucket for that matter) named my_cool_repo. The file is a script used to install ConfigServer's well known CSF-...
18
votes
2
answers
16k
views
upgrade git on Ubuntu 10.04 (Lucid Lynx)
I currently have Git 1.7.1.0 installed but need to upgrade to 1.7.1.1 (at least). I tried running:
sudo apt-get update
sudo apt-get upgrade
and also tried
sudo apt-get install git-core
but each ...
17
votes
3
answers
14k
views
Can't install GitKraken
I just installed GitKraken (A Git GUI) by downloading it from the website. When I try to install it via 'Discover Center', it doesn't work. So I found somewhere online the command dpkg -i [filename], ...
17
votes
2
answers
40k
views
Which is the best git client for linux? [closed]
I am moving out of a windows enviroment where i used Tortoise Git. I heard linux git clients are pretty poor... can you guys help me finding a good one?
16
votes
2
answers
66k
views
tortoisegit for ubuntu
Are there any alternatives to ToroiseGIT for Ubuntu?
I'm looking for something to integrate GIT with nautilus in the context menu.
Like TortoiseHG used to (replaced with HG scripts)
16
votes
1
answer
480
views
How do I get "Quickly" to use Git?
How do I get Quickly to use Git as its default version control instead of Bazaar?
15
votes
2
answers
52k
views
git branch not showing branches in terminal?
I'm using Ubuntu 16.04 and Git 2.7.4.
I just did git init and then git branch but nothing appears at all:
~/node/uui$ git init
Initialized empty Git repository in /home/alex/node/uui/.git/
~/node/...