Tag: linux

how to use git with a package I am distributing

I have been using git for some time now and I feel I have a good handle on it. I did however, build my first small program as a distribution (something with ./configure make and make install) and I want to put it up on github but I am not sure how to exactly go […]

Alias Multiple Commands in Linux

I am managing a website using git. One of the requirements for the git repository is that bare = true. It uses a post-receive hook to manage pushes from my local computer. The problem is that sometimes I would like to make changes to a WordPress directory on my website using the wp-admin view online. […]

How to fix a git tracked file that is treated as untracked?

Symptoms I have a strange issue where I want to checkout a different branch <branch2>, but when I try I get the message that $ git checkout <branch2> error: The following untracked working tree files would be overwritten by checkout: <filename.xlsx> Please move or remove them before you switch branches. Aborting However git ls-files lists […]

Where can I find for the location of the repos managed by Gitosis in Linux

We are using Gitosis in our Linux OS server to manage our projects. One time, I mistakenly pushed the config file which contains errors and then I wasn’t able to push changes or clone copies of other projects from the server anymore, including gitosis-admin itself. Now, I need to login to the server using the […]

How to manage permissions on Linux folders?

I’m a little bit confused with Linux permissions. I’m configuring a Git Central Repository that the users access by SSH. I’m using Filesystem ACLs(link) and regular linux permissions. What I intend to do is: Find a way in that only the users that I want will be able to list/read/write/execute the dir “/var/github” (in a […]

Unable to create a bare git repository

My git version is I want to create a bare git repository called sample.git. I tried all sorts, but it failed: Try 1: Gives a usage statement but no git created git init –bare sample.git usage: git-init [–template=<template-directory>] [–shared] Try 2: (using git-init not git init) $ git-init –bare sample.git usage: git-init [–template=<template-directory>] [–shared] […]

How to make a custom merge in multiple branchs?

I have a PHP project on a git server and I am working on local and there is a clone of it on the main server that my site is run on it. I have two branches : 1.master 2.server Now my question is: How to make some changes on master and only merge some […]

Unable to Git-add linux /dev devices with force

I run this git add –force /dev/ cmd to add /dev devices to my repo,I get the same git-status as before. I add each file in the folder independently, but I get the same git-status. here is my test,i get the same result,can git track block and char devices ? yangchar@yangchar:~/verify$ git add ttyS0 –force […]

How to avoid .git files when comparing two folders

I have git installed on my Mac. I am trying to make a diff between files in two different folders. diff -rq PATH_Folder1/ PATH_Folder2/ > Desktop/DIFF.txt The results include .git files. Example: Files PATH1/abi/cpp/.git/index and PATH2/abi/cpp/.git/index differ. How can I avoid comparing .git files. I don’t require comparing git indices.

How to give PHP write access to certain directories created by git?

There are several similar questions on here, such as this one, but the answer to that question (and several others I read) is: let PHP create the directory itself in the first place. I use git on my site, so it’s not possible to allow PHP to “create the directory itself.” To pull in changes, […]

Git Baby is a git and github fan, let's start git clone.