Tag: git submodules

git tracks files in directory, but not directory itself – bug in git?

My understanding of git doesn’t include this situation. I cannot make ‘git status’ clean by running git reset –hard HEAD and git clean -fd. It appears that git is tracking the two files inside a directory, but not the directory itself. Here is an excerpt ~/work/ghc/libraries/haskeline ((no branch)) $ git status # Not currently on […]

Git Submodule Merge

I have a git repository, and in a branch I’ve created a submodule. The submodule, called foo, replaces a file called foo. The foo repository contains one file called bar. I committed my changes on the branch, and merged in to master. There were no conflicts, but I’m now left in the state where it […]

How to share files/folders across git repo?

I have a git repository, inside there are files/folders, that I want to share across repo. repo/ .git/ html-coding css-shared js-app css-shared ttf-shared font-files ttf-shared Using Submodules for this task looks like overkill. At times of SVN I’ve used snv:externals flag, which worked just fine for my purposes. Subtree is again referencing to external repos, […]

git submodule in superproject has later commits not seen in submodule itself

I have a super-module “Research” that includes a submodule “Simulator”. When I clone Simulator repository, and do git log, I get this ~/Simulator$ git log commit abcd… Date: Feb 1……. …….. When I clone Research repository, and do git submodule update –init and do git log inside Research/Simulator, I get this ~/Research/Simulator$ git log commit […]

Is it possible to add a git submodule with recursive flag?

I am adding a submodule to my project which contains another git repo. To get the module I ran: git submodule add git://github.com/biakaveron/debug-toolbar.git modules/debug-toolbar Then ran: git submodule update –init –recursive Which generated this error: fatal: Not a git repository: ../../../../../../..//d/websites/project/.git/modules/modules/debug-toolbar/modules/vendor/firephp Failed to recurse into submodule path ‘modules/debug-toolbar’ I have run into similar problems before. […]

Git submodules, not sure if its the right thing to use

So I have a a repo with my nodejs server. We also have a webapp that runs as a stand alone webapp only as a single html file on enterprise servers. For our cloud version we need ot run this with a backend, hence I am using nodejs. The thing that im no sure about […]

Check out file in multiple locations within the same repo similar to SVN externals

I’ve ported a SVN repo to GIT, but previously I have an svn:external file and it’s not recognized in GIT. Is it possible to do external files like SVN where you have a single source of a file, but checked-out into other directories of the same repo? For example: – test/img/hello.gif (original file) – test2/img/hello.gif […]

How to locate a commit of a submodule in GitHub?

How do you locate in GitHub a specific commit of a submodule from code that was cloned but is no longer in GitHub? For example, I have a project that uses submodule A that in turns uses submodules B and C. I have all the source in my hard drive. Using this source, I just […]

Properly build a git submodule with gnu make

I currently try to write a Makefile that build properly a project which contains a git submodule. This submodule have its own set of makefiles and produce several targets at once, including some libraries. This Makefile should have the following properties. Don’t rebuild twice the submodule even with parallel build. Update the submodule targets when […]

Remap dirs and files in git? Kind of clientspec in P4?

There is a large project which is stored in a remote GIT repository in the way: root/ | * module1/ | * include/ | | | * lib1/ | | header1.h | | headerN.h | * libN/ | headerX.h * sources/ | * lib1/ | file1.cxx | fileN.cxx * libN/ … The product is built […]

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