Questions tagged [git]

Git is a distributed source control system.

Git is a source control system that allows for many people to work on the same project simultaneously. It is distributed, makes it possible for many different branches of the same project to co-exist at the same time, and offers many other advanced features.

Git was originally authored by Linus Torvalds, the creator of the Linux kernel, and the official Git homepage is at git-scm.com

For git quick guide, see gitready.com. More information, see wikipedia

1127 questions
5
votes
3 answers

Howto Nginx + git-http-backend + fcgiwrap (Debian Squeeze)

I am trying to setup git-http-backend with Nginx but after 24 hours wasting time and reading everything I could I think this config should work but doesn't. server { listen 80; server_name mydevserver; access_log…
brainsqueezer
  • 81
  • 1
  • 5
5
votes
1 answer

git http-backend show info when accessing per browser

I'm currently hosting my own git-repos for my private projects. For this, I use Apache and the standard git http-backend. Now, a repo can be accessed under an URL like this: http://vcs.myserver.lc/git/Repo.git With this URL, I can push, fetch and…
5
votes
3 answers

Is it an unsafe practice to symlink /etc conf files?

To manage the configuration of a server, I keep some configuration flies (located in /etc) under version control (in the home folder) and then symlink to them from their /etc locations: /etc/someprog/c.conf ->…
5
votes
3 answers

Problems validating Puppet manifests with "puppet parser validate"

I'm using puppet parser validate in a git pre-commit hook in order to spot problems before committing files to our Puppet configuration repository. Unfortunately, this command appears to be a very lightweight syntax check that only marks errors…
larsks
  • 43,623
  • 14
  • 121
  • 180
5
votes
2 answers

can't git rm a directory

I accidentally added a directory to the list of items i'm supposed to git commit. Now when I try to run a git rm dirname, I get the error rm 'dirname' fatal: git rm: 'dirname': Is a directory I tried the following commands git rm -rf dirname and…
John
  • 7,343
  • 23
  • 63
  • 87
5
votes
3 answers

GIT, SSH, and GIT-SHELL

I'm trying to set up a secure git repository server using ssh-keys and git-shell. Since our user database is stored in a central LDAP directory, I can't change users' default shell to git-shell, so I've tried prepending the git-shell command to the…
Frank Brenner
  • 175
  • 5
  • 11
5
votes
2 answers

push commits to git (gitolite) repository messes up file permissions (no more trac access)

already posted here so feel free to answer there. everytime i commit/push something to the git server the file permissions change (all added/edited files in the repository have no read and execute access for the group). thus trac can't access the…
fetzig
  • 251
  • 1
  • 6
5
votes
1 answer

git diff between two branches when the path has changed

I need to understand changes to a file between two releases represented by my current master and branch new_branch. Normally, I would run the following if path/name are the same in both branches. git diff new_branch -- path/file What do I do when…
Mike Jr
  • 187
  • 1
  • 7
5
votes
2 answers

How to prevent ssh git push to set file ownership?

I have a remote bare Git repository on an Ubuntu server, where the files are owned by the user my_project and the group my_project, with permissions set accordingly. All commiters are themself in the group my_project. When somebody commit then push…
Bite code
  • 409
  • 5
  • 17
5
votes
2 answers

UNIX - How to give user rights over another user and so I don't need to sudo or type password?

I have 2 users in question • git user - used for gitosis - so it's a No password user and it can be accessed only through root... • user user - where my files reside so what I would like to do is give the user git rights to navigate to a luddico…
zanona
  • 345
  • 2
  • 3
  • 8
5
votes
5 answers

Git, WSL2, SSH: unexpected disconnect while reading sideband packet

While attempting to clone a remote Git repo using SSH I got the following error: git clone user@remote-repo:project.git . remote: Counting objects: 187444, done. remote: Compressing objects: 100% (73430/73430), done. client_loop: send disconnect:…
amateur barista
  • 498
  • 3
  • 7
  • 21
4
votes
1 answer

Git access fails in EC2 instance startup script (Ubuntu)

I am creating an ec2 instance from an AMI using aws ec2 run-instances [lots of arguments] --user-data file://my_sh_file.sh my_sh_file.sh looks like this: su ubuntu # fails with or without this cd /home/ubuntu/my_working_dir git pull origin…
Omroth
  • 207
  • 2
  • 7
4
votes
0 answers

Git clone from Gitlab incredibly slow in Docker container

I am trying to clone our Gitlab repository into a docker container, running on a fresh VM running Ubuntu 18.04.1. For some reason, when I try to clone the repository, I spend a long time (several minutes) looking at Cloning into ${REPONAME} before…
VBwhatnow
  • 111
  • 6
4
votes
3 answers

Version Control and Backup, which combination?

I'm a sole developer and I have 3 computers. Plus a friend of mine has an account, but never uses it. My current setup is GIT + my own ad hoc backup job that clones the repository, zips it, gnupg it, and send it to a remote ftp. This has worked…
neoneye
  • 143
  • 5
4
votes
1 answer

How to prevent Git client hanging during post-receive hook

I have a Git repository that contains a collection of config files and python scripts. On the server repository, I have a post-receive hook that will: checkout the master branch, setup a python virtualenv, install the pip requirements, and run…
user233054