Git is a free & open source, distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
1
vote
0answers
12 views
Git-annex link to different file names
Maybe this is just a crazy use case that doesn't work, but I was wondering if there's a way to build a file's history from files with different file names. I'm exploring this idea because I'd like to ...
0
votes
2answers
34 views
Understanding what git branch means, in this context
I'm trying to understand what does this code means:
function git_branch {
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ \1/'
}
but I don't get it. Someone said this ...
3
votes
1answer
37 views
I have nested git repos, will it cause a problem?
A history
I installed etckeeper
I decided to track e.g. shorewall firewall configuration as its own git repository. I think I wanted it to be easier to look at specific configuration changes. I ...
4
votes
4answers
56 views
List files not stored in Git repos
I want to find out what files in a certain directory are not managed by Git. This is so I because I use Git for backups, and I want to eventually get all my files personal in there.
What unix tool ...
0
votes
0answers
15 views
automatic create directory “git-shell-commands” in home directory when login to git-shell
I want to create directory "git-shell-commands" in home directory when login to git-shell
I need to user in Active Directory to use git-shell.
Now AD user can login to FreeBSD (Samba 4.4 + winbindd +...
4
votes
2answers
38 views
Add file outside git repository [closed]
Assume I have local workstation with root access and a server without root access. I want to share (mostly configuration) files between these two computers. So I set up a git repository with top-level ...
1
vote
1answer
20 views
“not regular file” when trying to scp .gitignore file [closed]
The remote directory already contains a .gitignore file, which I want to overwrite and upload a new one. After doing:
scp -P[portnumber] [email protected]:path/for/file/ location/of/file/.gitignore
I ...
1
vote
0answers
19 views
How to store different username-password key pair in SSH in GIT Bash?
Current Machine: Git Bash on Windows.
Trying to connect to a Mac through SSH.
When I execute the below command:
ssh [email protected] "ls"
Password: <myPassword>
Output (works as desired)...
1
vote
3answers
37 views
Run git fetch after any cd command
I need to run git fetch after any cd command in the background and only if I'm in a git directory.
I'm horrible at zsh/bash scripting and could use some help with this
0
votes
0answers
7 views
no gitlab connection possible, mac osx wifi git clone from gitlab stuck
I have a macbook mid 2009 running El Capitan and git client installed and properly working, I also have a Server running gitlab and it is also working pretty good. I have a normal wifi connection. ...
1
vote
1answer
29 views
Git Server: ignore whitespace changes in new commits
I found a lot of ways to deal with the whitespace problem in Git, but all of them require some sort of action on the user side: configure Git to ignore ws changes, setup a pre-commit hook with warning,...
1
vote
1answer
23 views
How to prevent `git difftool` from calling another `vimdiff`?
I have git configured (like below) to use vimdiff as difftool and compare another pair of files without prompting as soon as I call :qa. It's awesome. The only problem is sometimes there are ...
3
votes
1answer
22 views
Storing git results in a variable results in weird behaviour [duplicate]
I have a git repository with 2 branches:
$ git branch
* master
test/branch
I can list specific branches individually by doing the following:
$ git branch --list master
* master
$ git branch --...
1
vote
2answers
57 views
Dealing with machine specific configs when using git for configuration management
I've been using a git repo for managing my systems configs for a while now. I used the documentation on Digital Ocean tutorials here. Pretty much I have a remote repo on a server. Do a git clone of ...
0
votes
1answer
34 views
bash if condition on git command result
I have the following error due an invalid git command within my shell-script. git push blabla master results in fatal: 'blabla' does not appear to be a git repository
I would like to respond to ...
0
votes
0answers
13 views
Cause of git error - Insufficient permission for adding an object to repository database ./objects? [duplicate]
I'm skeptical about this error and want to share one cause. PLease share your views on whether it could be a reason for above mentioned error.
Scenario 1:-
i). I have cloned a local git repo which ...
0
votes
1answer
8 views
Remove all objects in repo but specified object
I'm trying to write a program that will get an object from github, without cloning the entire repo. The last line does not work, giving me
a Syntax error: "(" unexpected. It is supposed to remove ...
1
vote
2answers
28 views
Git - Remove file from two branches
I have two branches, which contain a file that has recently been added to git ignore. It is an auto-generated file. I removed it in the master branch from the cache using git rm --cached fileName. ...
1
vote
1answer
21 views
Git tracking dotfiles that are symlinked
I keep my dotfiles in a private git repo on bitbucket and this works great for the majority of my files (.vimrc, .tmux.conf etc) then I just set up symlinks from my home directory to my cloned gitrepo ...
1
vote
0answers
62 views
What is return code 1 for git-rebase? What are other values it could return?
I've got a script that takes changes from master and applies them to all branches. The script works well for us because we tag our releases and use dev-branches. We don't maintain a separate branch ...
1
vote
1answer
64 views
RepoForge used across many StackOverflow docs is down, What is the alternative?
I'm trying to download git. I could build from source except I have no source packages.
I tried yum install git but that couldn't find it.
I tried downloading the git rpm directly from Repoforge , ...
2
votes
0answers
69 views
Git Server with several repos
I'm setting up a Git server, and there will be three different groups working on different projects iOS, WebDevel, Android. I need to do it in a secure/safe way.
Meanwhile, I don't want iOS ...
2
votes
1answer
34 views
Merging part of kernel - best way?
For example: I have a kernel 3.16 from my embedded support, but I want to have some network wireless drivers from 3.19. What is the best way to merge only this drivers (not full kernel)?
I tried ...
1
vote
1answer
84 views
Checking for errors in bash script
How can I modified this script to conditionally execute ${deleteOldBranchRemote} when there is no error executing ${getRename}?
Now_hourly=$(date +%d%b%H%M)
#echo "$Now_hourly"
newrcName="rc$...
1
vote
1answer
25 views
Bash command inside .gitconfig file
I have a string (Github token) inside a file and I want this to be accessible via gitconfig only after I enter my keyring password.
For this I created a file /secret/token, and then chmod it to 400. ...
1
vote
1answer
40 views
Colored word-diff just like git's?
I've been for long using git's (colored) --word-diff which I find awesome. I found myself today in a situation where I had two strings I needed to compare word by word and craving for something just ...
1
vote
1answer
56 views
How to install custom source from git using my package manager in Gentoo?
I would like to install custom source from a git repository, but using my package manager (emerge for portage).
Background
I have installed Gentoo using EFI using Sakaki's tutorial, so I have ...
1
vote
0answers
15 views
How to handle multi-machine-dot-file-versioning
I'm thinking about versioning my dot-files via git on a public repository. I've moved all the interesting dot-files like .profiles or .vimrc to the repository and subsequently symlinked them to there ...
1
vote
2answers
82 views
git not using global config file or public key
I've setup a global git username and password while logged in as root on my Fedora server with the following commands:
git config --global user.email "[my email]"
git config --global user.name "[my ...
0
votes
0answers
15 views
Unknown mergtetool vimdiff
I'm running Red Hat 2.6.32. When I run "vimdiff", vim gets pulled up. When I do a "git mergetool" on my repo, it says "Hit return to start merge resolution tool (vimdiff)". I hit return, but then I ...
0
votes
2answers
18 views
How to make git clone install cli tool?
I am creating a cli tool in nodejs, that i want people to be able to run like this:
git clone mytool.git
mytool -arg1
Is it possible, or there needs to be a step in between. What would it be.
3
votes
1answer
28 views
“git show” shows strange characters on XTerm
On FreeBSD 10.3, I run a command like git show on xterm, the output contains some strange irrelevant characters as below. I'm not sure why.
2
votes
2answers
73 views
how to temporarily configure SSH proxy server
I'm often in a network that for some silly reason blocks TCP destination port 22. It doesn't seem practical to use a full VPN just to overcome this issue, so I'm sometimes using SSH proxy (via ...
-2
votes
1answer
18 views
How could I find those git documents('Everyday Git[1]' & 'Git User's Manual[2]') mentioned in the man pages?
The git(1) manual page says:
See gittutorial(7) to get started, then see Everyday Git[1]
for a useful minimum set of commands. The Git User’s Manual[2]
has a more in-depth introduction.
Where is ...
0
votes
1answer
130 views
Git Bash for both Ubuntu/Linux and Windows requires ssh-agent on restart
Each time I need to use git for both my Linux server as well as my home computer running Windows 10, I need to start ssh-agent, then provide it with my GitHub RSA key, the problem being that doing so ...
3
votes
1answer
73 views
Git pull error always for a binary file
I finished a git push to a Bitbucket repository and in the Bitbucket account I found these update were done. But when I do a git pull in a production CentOS server, I got error below. Does anyone know ...
1
vote
1answer
24 views
After git, folders and files gone
I had a directory such that
$ ls
$ README.md testA.c testB.c a_large_folder another_folder
my most recent add->commit->push consisted of
$ README.md testA.c
Normally, my lazy self is used to doing ...
1
vote
0answers
32 views
How can I ship an executable file?
I have a project that is hosted on GitHub. On my local machine I have created an executable file that installs the program. However, once uploaded to GitHub and cloned somewhere else the user must ...
0
votes
1answer
41 views
upload ssh key on github from command line
I have found a way to upload an SSH key to my GitHub account with command line, but there is small problem.
I am able to do this with following command:
curl -u "user:pass" --data '{"title":"test-...
-1
votes
1answer
107 views
Using git push to create remote branch on the fly without creating local branch [closed]
So here is what i want to achieve:
When I clone a repository from Github and checkout some stable branch, and make some local changes in it, then I don't want to create a local feature branch nor do ...
0
votes
2answers
163 views
Unable to clone git repository on ubuntu [closed]
While cloning git repository I am getting the following error
Failed to connect to github.com port 443:Network is ureachable while I am able to clone on my windows machine
Edited-
git clone https:/...
1
vote
2answers
49 views
inaccessible directory
I git cloned into a directory "/source" before I mkdired it. It did not show up in its parent directory, but when I run the ls command, the output is indented like this:
database static ...
3
votes
0answers
49 views
Tar - Transform stdin without extracting
I am attempting to transform the paths of a tar file coming from standard input without having to extract the tar first.
This is an apparent duplicate of this question, I am looking for a solution ...
0
votes
1answer
47 views
git retains remote information from a deleted repository
I cannot clone any repository anymore.
$ git clone [email protected]:myaccount/myrep.git
Cloning into 'myrep'...
conq: repository does not exist.
fatal: Could not read from remote repository.
...
0
votes
0answers
27 views
Clone git repo via ssh'ing from another pc
How can I clone git repos in a non-interactive way as follows:
for h in server1 server2; do
ssh $h "git clone [email protected]:username/reponame.git"
done
When I interactively clone the repository,...
2
votes
1answer
74 views
Have tree hide gitignored files
Is there a way to make tree not show files that are ignored in .gitignore?
Thanks!
2
votes
0answers
18 views
How did I get the git commits to show up in autocomplete?
Git tab completion on my mac:
Git tab completion on my Ubuntu server:
On my mac and my Ubuntu server I get very different output from tab completion despite having the same version of zsh, same ...
1
vote
1answer
36 views
Why you cannot `git pull SHA…650839#file-diff.pach`?
I want to download a portion of this diff: https://gist.github.com/sergeykish/650839#file-dvorak-de-diff. Pseudocode
git pull https://gist.github.com/sergeykish/650839#file-dvorak-de-diff.patch
1
vote
1answer
274 views
Why I cannot purge mono-devel on Ubuntu Linux 16.04?
After I sudo apt-get install mono-devel , when I try to purge mono-devel on Ubuntu Linux 16.04, I get the following error message:
Reading package lists... Done
Building dependency tree
...
1
vote
1answer
95 views
Does anyone know a surefire way of installing git on Solaris 9?
I tried the OpenCSW method but I am afraid that is only Solaris 10 and 11. git command just yields command not found. Surely someone out there has configured/used git on Solaris 9.