Tag: git submodules

Cloning a git starter project without throwing away the original git linkage?

I would like to clone a starter project for a javascript application. The starter project contains pre-configurations for development and nice folder structures etc. I would be developing my app inside that folder structure. I will be committing the starter project and all my files to my own repo. What I want to know is, […]

Completed with errors, not showing in source tree

I have cloned a project using source tree which came out with the following error: No submodule mapping found in .gitmodules for path ‘frontend/bower_components/global’ Completed with errors, see above. I have been told to just ignore the error for now, but the project is not showing in SourceTree, I can see the files in win […]

Should we be using git submodule?

How handy would git submodule come into a collaborating project? If I have a project that contains multiple separate works in different repositories, it sounds logical to use submodule. However, I have read there are certain drawbacks, including how difficult it is when it comes to merging. So can anyone who has experience using submodule […]

How to `git submodule add` Existing sub Repository?

The Question How to add existing sub repository as a submodule in git? The Why I have a private codespace supermodule with submodules scattered randomly: codespace (git repo, private) ├── Archived_projects (git repos) └── Projects    ├── project-foo (git repo)    └── project-bar (git repo) Sometimes submodules have commits not ready to be pushed. But […]

How to automatically merge git submodules

I have looked at this question, but the asker seems to asking something completely different. I want to know how to (scriptably) merge a supermodule history where the remote has a new commit in a submodule, and the local has a new commit as well. An example 1. Foo(a1) – Bar1(b1) – Bar2(c1) A git […]

How to add a shallow git submodule at a given tag

I want to include a large git repository as a submodule in my project. To reduce download times for developers in the project, I’d like to add the submodule so that when it is cloned, only one version is retrieved. Also, the version I need is an older version which is marked with a tag. […]

Git submodules peer2peer workflow

I have a tools collection which I sync between my computers via git pull on remote repo with working tree. Whenever some of the tools have git source I add them by ‘git submodule add’ . Sometimes I do small modifications, compile tools, and add want to commit it in git repo – my aim […]

Re-staging new submodule's directory

The following scenario happens to me unfortunately frequently, and although I consider myself a fairly advanced Git user, I have no idea how to fix it. Suppose I have added a submodule git://foo.com/bar.git to my repository: git submodule add git://foo.com/bar.git ./vendor/bar git submodule update –init –recursive So far, so good. Now Git has added the […]

Git repository using directory as externals

I have an SVN repository with some documents using the same reference (bibtex) files via svn:externals. Its contents looks like this: bibtex/ doc1/ -doc1.tex -bibtex/ (svn:externals) doc2/ -doc2.tex -bibtex/ (svn:externals) This way I could checkout each paper individually and obtaining the same reference. How can I setup the same with git? I read that submodules […]

How to see commits applied to a submodule between two commits of parent repository?

Let’s say I have a repository with two submodules: Foo – sub1 – sub2 I would like to see the commits applied to each of the submodules by a certain commit. Is there an easy way to do this? In case my question isn’t clear, in my use case, sub1 and sub2 are tracking the […]

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