set git safe.directory to workspace to get commit hash during make (recursive)

This commit is contained in:
Mauro Vietri 2025-12-27 23:27:09 -03:00
parent 4788136b10
commit 4074ee4f3c

View file

@ -16,7 +16,7 @@ NORM=$(shell tput sgr0)
ifeq ($(CONTAINER_NAME),) ifeq ($(CONTAINER_NAME),)
shell: .build shell: .build
$(info $(BOLD)Starting $(TOOLCHAIN_NAME)...$(NORM)) $(info $(BOLD)Starting $(TOOLCHAIN_NAME)...$(NORM))
docker run -it --rm -v "$(WORKSPACE_DIR)":/root/workspace $(TOOLCHAIN_NAME) /bin/bash -c "git config --global --add safe.directory /root/workspace && exec bash" docker run -it --rm -v "$(WORKSPACE_DIR)":/root/workspace $(TOOLCHAIN_NAME) /bin/bash -c "git config --global --add safe.directory '*' && exec bash"
else else
shell: shell:
$(info $(BOLD)Connecting to running $(TOOLCHAIN_NAME)...$(NORM)) $(info $(BOLD)Connecting to running $(TOOLCHAIN_NAME)...$(NORM))