- Python 58.4%
- R 38.8%
- Shell 2.8%
| src | ||
| tests | ||
| .gitignore | ||
| .gitmodules | ||
| LICENSE | ||
| README.md | ||
c
Trace entities in a Python git commit history ; given the json reduced format representing functions/methods evolution build trace to study survival
install
Remember you need the 3 modules utils, symtab and diff
BE AWARE
AVOID HTTPS and USE SSH be sure bothmachines are ssh-key authenticated on te git server
git submodule add git@gitlab.mazarol-gate.org:antoniol/utils.git src/utils
git submodule add git@gitlab.mazarol-gate.org:antoniol/package-symtab.git src/symtab
git submodule add git@gitlab.mazarol-gate.org:antoniol/diff_tools.git src/diff_tools
IF REALLY YOU USE HTTPS
git submodule add https://gitlab.mazarol-gate.org/antoniol/utils.git src/utils
git submodule add https://gitlab.mazarol-gate.org/antoniol/package-symtab.git src/symtab
git submodule add https://gitlab.mazarol-gate.org/antoniol/diff_tools.git src/diff_tools
the you must enter username and password by hand on the server when installing modules !
BE AWARE
Mayb be it is juts gitlab BUT in order to propagate changes to modules you MUST do a two steps commit:
-
first commit the change e to the module and push it on the server; and then
-
move a step up in the directory structure (say into trace4py/src) and then to a commit and push of the directory alias module.
Remember, project root hosts the .gitmodules !!!! Consider the scenario:
-
cloned trace4py as usual with git clone
-
updated modules i.e. for the project root run:
git submodule update --init --recursive
- you perform a change on one sub-module, say the file selector.py was modifier inside
py2jsel/src/symtab/src/
to propagate the change to the module git repository you MUST
-
commit and push the change in the symtab directory (the module) ; then
-
inside py2jsel or py2jsel/src commit and push the change to py2jsel/src/symtab
SUB-MODULES
Whe we do a submodule checkout it creates a detached head , do not panic, it is normal. You cab work in the detached head and then switch to the main master branch or attach the head. To do this to all modules go into the top directory and do:
git submodule update git submodule foreach git checkout master git submodule foreach git pull origin master
REMEMBER !
You must do a double commit if you work with modules and you must have the head attaches.
Suppose you modified a fine into my_mod
cd my_mod
git commit -am "my nice commit"
git push
cd into_top_level
git commit -am "force module to propagate" git push
======================
Alternatively do a per-module work
to all modules
If you end up with detached head:
-
make a copy of you local work
-
go into the sub-module and do a
git submodule update --remote --merge
- go in te top module rebuild the status with the master branch
git submodule update git submodule foreach git checkout master git submodule foreach git pull origin master
- copy bach your modules work (modified files)
4.1) go into module directory do a
git status
4.2) much likely status is different thus do a
git commit -am "force update" git push
commit all changed files into the module
4.3) go into the top module and commit the new branch status
git commit -am "force update" git push
REF:
https://www.atlassian.com/git/tutorials/git-submoduleŧ
https://git-scm.com/book/en/v2/Git-Tools-Submodules
https://stackoverflow.com/questions/3965676/why-did-my-git-repo-enter-a-detached-head-state