Skip to content

Problems with git submodules #8

Closed
@Javex

Description

@Javex

Short: When I run git up it does not run on my current working directories' git repository.

Long: I have a master repository that has several submodules. To keep everything synced, I run git pull && git submodule foreach pull (and some more commands). This worked but always caused problems when pushing later. As I understand git up solves this. However, I noticed that git up seems to be running on the master each time in the submodule.

For example, the master module has the branches master and reduced while one submodule only has master and no reduced. However, this is the output produced when running above command (with only one submodule):

Fetching origin
stashing 1 changes
master   up to date
reduced  up to date
unstashing
Entering 'mysubmodule'
Fetching origin
stashing 1 changes
master   up to date
reduced  up to date
unstashing

Making things even more weird, when I go into the directory myself and do git up, the same thing happens:

stashing 1 changes
master   up to date
reduced  up to date
unstashing

There isn't even a change in this directory, only in the master. I read up on PyGit docs so I ran this: GIT_PYTHON_TRACE=y git up:

git status --porcelain --untracked-files=no
git config git-up.rebase.auto
git config git-up.rebase.log-hook
git config git-up.bundler.rbenv
git config git-up.bundler.check
git config git-up.bundler.autoinstall
git config git-up.updates.check
git config git-up.fetch.prune
git config git-up.bundler.local
git config git-up.fetch.all
git config git-up.rebase.arguments
git version
git fetch --multiple --prune origin
Fetching origin
git cat-file --batch-check
git diff HEAD --cached --abbrev=40 --full-index --raw
git diff --abbrev=40 --full-index --raw
git status --porcelain --untracked-files=no
stashing 1 changes
git stash
master   up to date
reduced  up to date
unstashing
git stash pop

It still doesn't say that much about what's really going on though :(
But I executed some of the commands myself and it does behave differently, for example git fetch --multiple --prune origin did delete a branch on the first run but not on the second, indicating this command was never executed on this repository.

Since I don't know so much about PyGitUp (or PyGit for that matter), I don't know how to debug this efficiently (I am capable of Python though, so I can assist there). I am not sure if I have a major configuration screwup or if this is a bug in PyGitUp but if someone could provide details on how to track this down, I would be very happy.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions