Git submodule mess: how to use git submodules with developers not familar with git?
I am really frustated about using git's submodule feature. Either I still don't get it right or it just don't work as I am expecting this. Following project situation is given:
| source (submodule)
In this scenario source is pointing to another repository containing the common source data across all our projects. There is a lot of development happening under source as also under projsrc. Unfortunately Project points to some commit of the source submodule and not to the actual HEAD of it. This is the usual git behaviour, as far as I got it know.
I already found out that
git submodule update
just get the version of submodule which was commited together with the main Project. However, I would really like to be always up-to date with the submodules development, but do not have any real clue how to do this right. Hence my question is:
Is it possible to attach the Project to the HEAD of the submodule, reagardless of the fact if this will break the compilation of Project or not. I just don't want to go always into the submodule directory and do git pull there. Since I think I could loose my changes done in the submodule directory, because this is simple attached to a commit and not really to any branch or so.
Please consider following constraints:
- Developers in our group are not that familiar with all VCS around. We are used to use really huge svn repository before, without any external repo features at all.
- We are working on Windows
- A click'n'forget solution would be best, since most of project members are rather scared by using a command line interface :)
Thanks in advance!
I have a project with a submodule that is pointing to an invalid commit: the submodule commit remained local and when I try to fetch it from another repo I get: $ git submodule update fatal: reference
Currently I have a few submodules in my parent project. How can I tell if one of the submodules has recently changed and I need to do a git submodule foreach git pull origin master
I've the following situation: One internal server (server1) with the main repo with 2 branches master and dev, four developers with 3 clones of the git working with branches of the dev Rules: the ser
Say I have a super-project with N sub-modules. Which I have created following this guide: Git Submodule Tutorial So I have public repositories for all sub modules plus a public repo for the super proj
I have no idea how to write Bash and after googling around for a while, I'm in no better position to achieve what I need. I have a csv file consisting of a list of git submodules and their paths-to-be
If I want to submodule a Git repository: https://github.com/shadowhand/paypal ...that has a config file: https://github.com/shadowhand/paypal/blob/master/config/paypal.php ...how do I contribute to th
I'd like to use a local copy of jQuery 1.8.3 for my github project. I'd like to do it the right way, which would be to add it as a submodule: git submodule add git://github.com/jquery/jquery.git js/li
I'm not clear on what the following means (from git submodule update docs): ...will make the submodules HEAD be detached, unless --rebase or --merge is specified... How does --rebase/--merge chang
I'm working with three branches master develop feature-new-theme Where feature-new-themeis a fork of develop. In feature-new-theme I've added a new git submodule, called bootswatch, in protected/vend
Is it possible to download submodules for a repository with only the working directory? If I download a tarball of a repository from GitHub, that is equivalent to a shallow clone without the .git fold
Using msysgit on windows, whenever I do git diff on a repository that has a submodule or several, the command prompt (and also PowerShell) crash. Is this a known but and is there a fix/workaround? Can
We use GIT to manage our project. Each project has a core (like a framework from who we'll built the project) So each project has at least 2 remotes branches: 1 repository for that core framework.
I accidentally added a cloned git repository to a working copy clone of my repository, and pushed the changes to my remote. I did not use git submodule to do that, but rather did something like git a
I have a project that contains many submodules. I want to loop over each submodule with the following command: git submodule foreach npm install And I want the script to continue looping over each sub
In svn you can link a repository to any folder in another svn repository. I'm wondering if there is a similar feature for git? Basically I want a git submodule inside my repository, but I want the sub
I found Using Git, what's the best way to subtree merge an external project that has submodules? but while related, it doesn't answer my question. Suppose I have my Parent project and my Child project
I added two submodules to my vim repository, and the git status command always outputs this: On branch master Changed but not updated: (use git add <file>... to update what will be committed)
I'm sure something is wrong with my git directory. I set up my submodule using git submodule add ssh://someUrl/confusionutil.git confusionUtil and this all works well. Seems like the submodule is act
Our team has experimented with git submodules for some core CRUD functionality shared by most of our products. We have also successfully used Nuget packages (self-hosted now) for some common utilities
This seems a to be a common issue, but i just can't find a reasonable solution: IMHO, the worse problem with git submodules is where submodule committed but not pushed changes are easily deleted with
I need to clone a repository from Github and am using Git Shell provided with the Github for Windows package. The repository contains submodules and I don't know why, (first time) I cannot use submodu
What is the best approach for importing a Git project with submodules into a Subversion repository? Not sure if it matters, but the submodules are pointing to the Kohana core and module repositories
Originally, I thought my problem was How to maintain branches in Apache's DocumentRoots? but realized the right question actually is How to use Git to deploy stuff to web -server such as Apache?. I fe
When I run these steps: mkdir dev cd dev git clone git://github.com/facebook/hhvm.git cd hhvm git submodule init export CMAKE_PREFIX_PATH=`pwd`/.. export HPHP_HOME=`pwd` cd .. url: https://github.com
Is this possible? Imagine I have projects Parent & Child. Both are git respositories. Child is a submodule of Parent. Can I make edits to the version of Child that is inside Parent & commit &a
Is there a way to automatically have git submodule update (or preferably git submodule update --init called whenever git pull is done? Looking for a git config setting, or a git alias to help with thi
I recently wanted to adopt submodules from GIT with my Android projects but stumbled into some problems. Backstory I have multiple projects but many use the same external library (Android library-proj
I am working on a website, and I need to use Git for practical reasons. However, I think I have not totally understood how it works. I want to do something quite simple, and I am working on localhost.
If you add a submodule in git, afaik it points to a certain commit in that submodule. Is there any way to see which commit it's actually pointing at? Without actually checking out the submodule.
To include a few external git repositories in my main repository, there are a few options: submodules braid subtree The first seems to be advised against by basically everybody. The second and thi
I have a git repository set up with several submodules, which creates a .gitmodules file that is a tracked file in the parent repository. However, there are other developers wanting to work on this re
I know this question has been beaten to death. But I still don't have a clear understanding of why my submodule is trying to refer to a commit in my superproject. I have a project which has a number o
I am trying to update the submodules of this git repositary but I keep getting a fatal errors: [root@iptlock ProdigyView]# git submodule update --recursive Cloning into core... Permission denied (publ
I am working on a GIT repository (called A here). It includes a submodule (called B here). When clone a new copy of A by git clone --recursive <repository url for A> A and B are cloned, but the
I'm referencing a git submodule in my project, and now need to reference a specific SHA in the target git repo. # .gitmodules [submodule vendor/plugins/ssl_requirement] path = vendor/plugins/ssl_req
Given a git repository, with a directory in which I've checked out a submodule, how can I rename the top level directory? $ git init Initialized empty Git repository in /home/work/asdasd/.git/ $ mkdir
After a painful merge, when I run git submodule update, I get this: >git submodule update error: invalid key (newline): submodule.external/mono-reactive external/mono-reactive.url error: invalid ke
user$ sudo git submodule update fatal: reference is not a tree: a094dcfeeb43fcd62a9e466156e05e7581026f33 Unable to checkout 'a094dcfeeb43fcd62a9e466156e05e7581026f33' in submodule path 'client/src/uti
I have a project that has submodules added. Thing is, I always want these submodules up to date with the current version. How can I always tell these submodules to look for the latest commit and sync
I have created a php project. In this project under vendor/ I have included using composer some other 3rd party modules. I think they came with a .git folder. Finally I decided to add my code under g
After a changing in a git submodule a manual searching is necessary to find out the main projects that track it. So, is there any way to know which remote super repos it is linked?
I would like to use swagger (https://github.com/wordnik/swagger-ui) as part of my project. Using swagger requires editing one file. Can I add a submodule and make edits to certain files, commits and p
I cloned repository A to repository B using git clone . /somedirectory/b.git . Later on, I decided to submodule repository C in B git submodule add /path/to/c.git c_in_b. So how do i push back this ad
I am using git GUI. How can I implement the git bash command git pull --rebase? I am going to use this command before push.
I have a git repo with a dev and a master branch. Now I am trying to use a different revision of a submodule in each branch. So for example I do this: git checkout master cd submodule git checkout v1.
Is there any way in git to know if you're in a submodule? You can do thinks like git submodule foreach in the parent directory but I can't seem to come up with a generic way to show that you're in a s
I have a git submodule in my main git repo. As I understand it, the main repo stores a SHA value (somewhere...), pointing to the specific commit of the submodule that it is linked to. I went in to
Source Tree is as follows: core // root .gitmodules // this has box-sdk as submodule box-sdk // git submodule BoxJavaLibraryV2 // Box related files I also created settings.gradle include 'box-sdk:Box
I have trouble understanding how submodules work. I have a remote repository PARENT and a remote repository CHILD. I would like to make repository CHILD a submodule of repository PARENT, so when I ch
I have a new team member who gets a Permission Error when trying to perform their initial git submodule update: [mrTeamMember@desktop application]$ git submodule update Initialized empty Git repositor