Skip to content

Conversation

@nuno-silva
Copy link

In #164, a || $(MAKE) vendor-install was added to the vendor-install target to help with "poor network circumstances":

vendor-install:
@echo Installing vendored packages
@$(DEPENV) dep ensure -v -vendor-only || $(MAKE) vendor-install
@echo

However, this leads to an infinite fork loop when dep fails or is not installed, possibly crashing the host machine.

This PR works around the infinite loop by checking the MAKELEVEL and aborting if it gets too high, which still allows the command to be retried a reasonable number of times.
Another possible approach is just looping around dep a set number of times.

Fixes #195.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

'make vendor-install' can lead to an infinite fork loop

1 participant