12/8/2023 0 Comments Git submodule specific branch![]() ![]() The submodule commit f68bed6 has three branches on it that may be used for checkout in the submodule directory. The "superproject" shows the sm2 submodule at commit f68bed6 but sm2 has it's HEAD at 5b8d48f. In the Branches dialog box, select the branch and the commit to which you want your top-level project to point. Nothing to commit (working directory clean) ![]() There is a special git submodule command included with git, and this command takes various arguments in order to add/update/delete your submodules. ![]() gitmodulesÄ¡00644 blob e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 mainÄ¡60000 commit 7c5889497938cd5699a9234a98ee93947e52b1ed sm1Ä¡60000 commit f68bed61cba6f94cef57554f2cf46a45a4a0d337 sm2į68bed6 (origin/master, origin/HEAD, master) Initial commit. A submodule in a git repository is like a sub-directory which is really a separate git repository in its own right. In this instance, the configured submodules respective configured. No changes added to commit (use "git add" and/or "git commit -a")Ä¡00644 blob 76813a07ae558db274cefc6d903ec24323fdeb0d. As an alternative to tracking a branch, you can decide which submodule commit should be used. " to discard changes in working directory) Using some test directories I set up, here's what the commands might look like: $ git -version removing a file or running a perl rewrite on all files) or information about each commit. gitmodules file located at the root of the parent repository. DESCRIPTION Lets you rewrite Git revision history by rewriting the branches mentioned in the , applying custom filters on each revision.A submodule can be located anywhere in a parent Git repositoryâs working directory and is configured via a. Finally, git checkout original-commit-branch. Submodules are Git repositories nested inside a parent Git repository at a specific path in the parent repositoryâs working directory. Then change into the submodule directory and use git log -oneline -decorate to see what branch the original commit is on. Lets note a few basic facts: A submodule is a Git repository (so it has its own branch names, tag names, and commit objects). Use git ls-tree HEAD in the "superproject" folder to see what commit your submodule was originally at. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |