I need to run “git log” command from Makefile and store the logs in another file. This I need to do for 2 different paths i.e. for 2 different repos
I have tried this in Makefile-
git_logs:
cd $(PATH1)
@git log -1 --stat > path1_logs.txt
cd $(PATH2)
@git log -1 --stat > path2_logs.txt
@echo "Git logs stored"
It seems however that cd doesn’t change directory & only echoes “cd $(PATH1). How can I modify the cd command? Or is there some other easier way to do what I expect?