How do I init/update a git submodule in a working tree after pushing to a bare working directory?
I have a git repository with an attached working tree that I'm pushing to a bare repo on a remote. The repository includes a submodule.
At the remote end: I check out the repo to a working tree
git checkout -f having set
GIT-WORK-TREE env vars.
In the working tree I now see all the expected files and an empty directory for the submodule ('MySubmodule').
I then do:
git submodule init
git submodule update
This errors with a message like:
working tree '../../workTree/' already exists
Clone of 'firstname.lastname@example.org:user/MySubmodule.git' into submodule path 'MySubmodule' failed
The empty submodule directory has now also 'vanished' from the working tree...
I'm not sure where I'm going wrong with this, basically I just want to check out the submodule files as I would with 'git submodule update'.
Have a remote git bare repo that onto which I've pushed a branch from one machine, and pulled to another machine. Made some changes on the other machine, trying to push those changes back to the remot
I ran the git --bare init in a wrong directory(in the server). I see the files branches, config, deps etc., in that directory.. How do I undo it?
I'm new to git and trying to use it with a project that has many (several hundreds) sources. The problem I have is that git is extracting all the project's sources to my working directory when doing c
Here is my project structure MainProject | README.md | src/ | lib/ # this is a submodule When I develop MainProject, I will also develop lib/, I mean MainProject/lib/. When I do push, I will copy all
Fellow coders, today is my first dive into git using Tower on the Mac - life's too short to mess with the command line ;) I did read a few intros and tutorials but none addressed the question I'm wri
I'm experimenting with some githooks, so I have setup a local bare repository with a symlink from hooks to the hooks stored elsewhere. I have pushed the master branch to the git repo and, of course, t
I have, for the last year, TouchJSON via a submodule. I no longer need to use the library and want to remove it but I am not sure if doing this: How do I remove a git submodule? will remove even the '
I am following the examples here http://wiki.dreamhost.com/Git Basically I want to create a git repo i can push to on a server from my desktop... On host: [host ~]$ mkdir project.git [host ~]$ cd proj
Is there a command line I can issue to see what directory another user is currently working in? This would be like using >pwd but for the other user.
I have my local dev repo (origin) and a remote repo which I created using git init --bare as recommended here. I also ran git --bare update-server-info git config --bool core.bare true Git remote -v
I am trying to get a method that uses the DotNetZip library to extract a file to the current working directory, although I can't seem to get it to do it, it wants a file path: private void unzipfiles(
I want to run my java algorithm from bash script. When i run my program from Netbeans i can specify my Working directory from application. So, how can i specify the Working directory from bash script
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
I have embedded Linux system that we want to store in Git. I have installed Git on the system, mount additional USB drive for storing Git data (bare repository). There is no problem with committing an
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
In case of a submodule conflict (i.e. when the two commits to merge contain different changes of the referenced commit), how can I easily set the submodule to theirs commit? In case of files, I woul
Can someone tell me difference between HEAD / Working Tree / Index in Git? From what I understand, they are all names for different branches. Is my assumption correct? EDIT: I found this A single git
I have a cakephp project. Let us call it Project Super. It has its own github repo. Super has git submodule that pulls from this repo. https://github.com/predominant/TwigView The issue is that I need
My Git was pushing without problem to our internal Git server, eg, this was working fine: $ git push origin master Today I wanted to work with a project hosted on Github, so I had to temporarily add
We've been using git-buildpackage to build debian packages with great success, but we've recently hit a wall since introducing git submodules into the mix. We normally run git-buildpackage -b -us -uc
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
When tagging in git, I can push all new tags: git push --tags or push specific tags: git push origin v1.5 But in both cases any new pending commits will get pushed out as well. How to aviod pushing
I have just added a bunch of files after I git init. Now I notice that I've made a mistake and want to undo all of them at once. How can I do that? $ git init $ git add . $ git status # On branch mast
I am trying to add a git submodule. The submodule itself works without any problem but my question is about the created layout when adding the submodule. I am adding a simple submodule called utils th
I've started project in my first laptop. git init, and start working. Tomorrow i'm going to vacations. I want to take with me my smaller laptop. And work with project from time to time. I cloned repo
I know the support for git submodules is limited in JGit, but still was wondering how can I achieve this: git submodule foreach git checkout <branchName> and similar commands using JGit. Or is t
i was wondering if there is a git command to see if a specific commit is in the current working tree. I have the shasign of the specific commit. I like to know if this commit is a commit done by anoth
I can tell Git where the Git repository is with --git-dir. I can tell Git where the working tree is with --work-tree. How do I tell Git where the gitignore file is? Q. Why would I want to do such a th
This issue is not the same as git - how to mirror file from other repo or GIT: How do I update my bare repo? Since a repository cloned with --mirror is a bare repository, can I make a repository clone
I happened to change a name of a directory within my local repository and then proceeded to push this change up to my github repository. In effect, it caused this repository to turn into a git submodu
I have a git controlled directory (actually my home directory) within which there are ignored directories (e.g. trash space, and directories controlled by other VCSs). I want to be able to have my bas
I have git installed and working as expected on my local system or a network share, but have not been able to get it to access the remote bare repository on my server using ssh. I have installed msysg
I have a project in a git repository, with a git submodule. I made changes to both the project and the submodule, and committed the project. Apparently I was supposed to commit the submodule first, th
From here http://blog.prabir.me/post/Undo-in-Git.aspx, it said This undo’s your commit and also resets your working tree to the last commit. 1 git reset --hard HEAD^ But how can I un-do my last comm
I am trying to make it so the default working directory of haskell mode updates when I load a module via C-l. Currently, the working directory is always my home directory. This makes it impossible to
I've create a submodule in my repository root in a specific folder. I can see the submodule is well registered in .git/.gitmodules and in .gitmodules, but I can't get it working. I can't see it if I m
I am attempting to revise a repo (not yet shared, so no worries about breaking anyone else's history) and git filter-branch is behaving in a rather odd fashion. $ git filter-branch -f --tree-filter /p
I have the following .gitmodules file: [submodule web/blog] path = web/blog url = git://amygdala.servebeer.com:lucky_blog.git [submodule web/old] path = web/old url = git://amygdala.servebeer.com:
Specifically I'm using Eclipse and egit: using the wizard to share a project with egit, it moved the working directory out of the eclipse workspace into the folder I had chosen to hold git depositori
Tried to use what's here, but that doesn't solve things for me. I've got a local repo in git, cloned from a remote repo, development. I branch locally to play around with a new feature in a branch cal
Is possible to clone a git bare repo as a new bare repo ? for example: git init --bare mainRepo.git Then in a remote server: git clone --bare xxx@server:/path/mainRepo.git repoReplica.git And then
Using Git and a checked out branch in Xcode 4, when I make changes to the project (add files, edit source etc) and then discard them, the physical files are left in the working directory but are remov
If I understood it correctly, Git directory is the hidden directoy named .git which resides in the working directory. And all the code and history info is stored in the Git directory. So I expected th
So I added a folder to my .gitignore file. Once I do a git status it tells me # On branch latest nothing to commit (working directory clean) However, when I try to change branches I get the following
after creating a git submodule by typing git submodule add <repo> && git submodule init my .git/config is changed, as well as a new file .gitmodules is created. It seems that I would be
As the title reveals it, we are writing a Unix-style shell utility U that is supposed to be invoked (in most cases) from bash. How exactly could U change the working directory of bash (or parent in ge
I have this on my .gitignore file: /nbproject/ /app/runtime/ /app/runtime/application.log* /app/runtime/error.log* /app/config/localdev.php* .DS_Store 1) I have checkout to master branch and then, ch
When working with the .travis.yml, is there an environment variable that contains the name of the current build directory in Travis-CI? Looking through the docs here I don't see one.
I am trying to maintain a bare copy of a Git repository and having some issues keeping the remote tracking branches up to date. I create the remote tracking branches like this: git branch -t 0.1 origi
I'm currently using gitolite, and in my post-receive hook I'm pushing to a (local) mirror if any incoming commits are on master. Thing is, that mirror only exists because I want to automate deployment