Open nhasabni opened 3 years ago
Hi @nhasabni,
But Graal does not:
The git executable path is hardcoded here: https://github.com/chaoss/grimoirelab-graal/blob/master/graal/graal.py#L50. The code should be modified to accept the git executable path via the command line.
Please try to create a soft link, it worked for me
cd /home/valcos/Desktop
git clone https://github.com/git/git
sudo apt-get install tcl build-essential tk gettext
sudo apt-get install libcurl4-gnutls-dev
sudo apt-get install libssl-dev
make configure
check git version
git --version
git version 2.25.1
create soft link and backup old executable
sudo cp /usr/bin/git /usr/bin/git.backup
sudo rm /usr/bin/git
sudo ln -s /home/valcos/Desktop/git/git /usr/bin/git
check git version
git --version
git version 2.34.1.75.gabe6bb3905
execute cocom backend
graal cocom https://github.com/chaoss/grimoirelab-perceval --git-path /tmp/graal-cocom
restore old executable
sudo rm /usr/bin/git
sudo cp /usr/bin/git.backup /usr/bin/git
Hope it helps!
Thx, @valeriocos!
Hi @nhasabni,
But Graal does not:
The git executable path is hardcoded here: https://github.com/chaoss/grimoirelab-graal/blob/master/graal/graal.py#L50. The code should be modified to accept the git executable path via the command line.
Please try to create a soft link, it worked for me
- install git latest version
cd /home/valcos/Desktop git clone https://github.com/git/git sudo apt-get install tcl build-essential tk gettext sudo apt-get install libcurl4-gnutls-dev sudo apt-get install libssl-dev make configure
- check git version
git --version git version 2.25.1
- create soft link and backup old executable
sudo cp /usr/bin/git /usr/bin/git.backup sudo rm /usr/bin/git sudo ln -s /home/valcos/Desktop/git/git /usr/bin/git
- check git version
git --version git version 2.34.1.75.gabe6bb3905
- execute cocom backend
graal cocom https://github.com/chaoss/grimoirelab-perceval --git-path /tmp/graal-cocom
- restore old executable
sudo rm /usr/bin/git sudo cp /usr/bin/git.backup /usr/bin/git
Hope it helps!
Thanks @valeriocos for looking into this. Unfortunately, --exec-path
command line param does not help.
$ graal cocom https://github.com/chaoss/grimoirelab-perceval --git-path /tmp/graal-cocom --exec-path ~/bin/git
[2021-12-03 10:25:39,906] - Starting the quest for the Graal.
[2021-12-03 10:25:39,921] - Error!: git command - git: 'worktree' is not a git command. See 'git --help'.
[2021-12-03 10:25:39,921] - Quest completed.
Also, I do not have sudo access in the machine that I am using for setup. So I cannot create a softlink for /usr/bin/git
. I think I will modify the Graal script to use path of git binary for my environment. Thanks.
@nhasabni if that suits you, feel free to fork Graal, patch it so that instead of using an specific path for git it uses the one in $PATH, and make it public. It seems some other people in the hackathon could benefit from that. Also, feel free to pull request the modification to the Graal repo.
BTW, if you do this, please ensure that is mention in your final paper: not only working with the tools as such, but also adapting them to your specific needs, show a high level of engagement.
I am using a different version of
git
than the one installed on the system by default. Newer version of thegit
is installed in~/bin
andPATH
variable is set to~/bin
. Shell command forgit
picks it up correctly as:But Graal does not:
worktree
is part ofgit
installed under~/bin
: