git-subtree

How can I list the git subtrees on the root?

本小妞迷上赌 提交于 2019-11-28 16:59:44
For example, you can do a git remote --verbose and git will show all the remotes you have on your project, git branch will show all the branches and signal the current branch, but how to list all subtrees, without any destructive command? git subtree will give the usage examples, but won't list anything. subtree only have add , pull , push , split , merge . There isn't any explicit way to do that (at least, for now), the only available commands are listed here (as you noted yourself, but here's a reference for future seekers): https://github.com/git/git/blob/master/contrib/subtree/git-subtree

When to use git subtree?

左心房为你撑大大i 提交于 2019-11-28 16:57:54
What problem does git subtree solve? When and why should I use that feature? I've read that it is used for repository separation . But why would I not just create two independent repositories instead of sticking two unrelated ones into one? This GitHub tutorial explains how to perform Git subtree merges . I kind of know how to use it, but not when (use cases) and why , and how it relates to git submodule . I'd use submodules when I have a dependency on another project or library. Matthew Sanders You should be careful to note explicitly what you are talking about when you use the term 'subtree'

Add subdirectory of remote repo with git-subtree

只谈情不闲聊 提交于 2019-11-28 15:40:15
问题 Is there a way to add a subdirectory of a remote repository into a subdirectory of my repository with git-subtree? Suppose I have this main repository: / dir1 dir2 And this library repository: / libdir some-file some-file-to-be-ignored I want to import library /libdir into main /dir1 so that it looks like this: / dir1 some-file dir2 Using git-subtree, I can specify to import into dir1 with the --prefix argument, but can I also specify to only take the contents of a specific directory in the

git subtree: possible to change subtree branch/path in a forked repository?

牧云@^-^@ 提交于 2019-11-27 19:26:25
In a repository A the folder sub is included as git subtree of the repository S - pointing to master branch. I have forked repository A into F . Now I want to do one of the following in F : change sub to use a different branch of S (ie develop branch) or: change sub to use a different repository altogether Is either one of these possible, and if so, how? Will there be any side effects I should know of? And how can I make sure my subtree change won't be updated in repository A when I merge my changes (pull request)? I mean besides isolating commits. If you used git subtree (and not git

Forking a sub directory of a repository on GitHub and making it part of my own repo

落爺英雄遲暮 提交于 2019-11-27 18:02:00
Apologies, I am very new to Git and GitHub, I've read through a few things but I'm not sure if what I'm trying to do is entirely possible. Basically I want to fork the Confluence Skin used on XBMC and modify various elements located here: https://github.com/xbmc/xbmc/tree/master/addons/skin.confluence However I don't want to fork the entire XBMC repository, so a simple fork action won't do. Here are my general requirements: I would like to take the contents of the skin.confluence folder and put it into a repository on my own GitHub account I need to be able to keep it linked within the

Git subtree and multiple directories

微笑、不失礼 提交于 2019-11-27 16:33:46
问题 I have a rather large git repository that has a directory where I maintain library code. The directory contains a number of subdirectories. repo +--- lib | +--- A | +--- B ... | +--- Z Now let us assume that I want to open source subdirectories A,...,M and keep subdirectories N,...,Z close sourced. Let us also assume that I would like to: Keep A,...,M in a single open source repository. The reason for this is that the directories A,...,M have interdependencies and it would be confusing to

git-subtree pull complications

时光毁灭记忆、已成空白 提交于 2019-11-27 13:43:56
问题 We have been trying to get git-subtree working on a project (with git version 1.7.9.4) and have run into a bit of a complication. Someone else previous added the subtree with this command some months ago: git subtree add --prefix=foo git@example.com:foo.git master Now there have been substantive changes to foo and we'd like to merge in those changes, ideally squashing them in. None of the files have been modified since they were imported. I've tried three things to try and merge in the

Managing 3rd party sources and binaries used by code under source control

安稳与你 提交于 2019-11-27 11:33:57
问题 I have a large code base under source control (was subversion, now git). To compile the code and run the tests I use a set of 3rd party libraries. These libraries can be divided into few categoriesL Binaries only 3rd party sources 3rd party sources + local modifications Each library has its {Windows, Linux} X {debug, release} X {32bit, 64bit} configurations. In addition these libraries evolve with time and different versions of my project use different versions/builds of these libraries. My

Merge multiple git repositories into one, keeping branches history

亡梦爱人 提交于 2019-11-27 10:21:23
问题 I have four separate projects. They have their own git repository. and the same name of branches for all projects. /project/ /project/projA/ /project/projA/.git/ /project/projB/ /project/projB/.git/ /project/projC/ /project/projC/.git/ /project/projD/ /project/projD/.git/ All git repositories have the same name of branches, and of course their own master branch. Question I would like to merge all projects into one like so: /Project/.git/ /project/projA/ /project/projB/ /project/projC/

How can I list the git subtrees on the root?

孤街浪徒 提交于 2019-11-27 10:18:11
问题 For example, you can do a git remote --verbose and git will show all the remotes you have on your project, git branch will show all the branches and signal the current branch, but how to list all subtrees, without any destructive command? git subtree will give the usage examples, but won't list anything. subtree only have add , pull , push , split , merge . 回答1: There isn't any explicit way to do that (at least, for now), the only available commands are listed here (as you noted yourself, but