Skip mdgen build in case of valid mdgen in Makefile (#1214)
## Description `_validatemdgen` resulted in the build for mdgen to always happen. This fixes that. ## Type of change <!--- Please check the type of change your PR introduces: ---> - [ ] 🌻 Feature - [ ] 🐛 Bugfix - [x] 🗺️ Documentation - [ ] 🤖 Test - [x] 💻 CI/Deployment - [ ] 🐹 Trivial/Minor ## Issue(s) <!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. --> * #<issue> ## Test Plan <!-- How will this be tested prior to merging.--> - [x] 💪 Manual - [ ] ⚡ Unit test - [ ] 💚 E2E
This commit is contained in:
parent
afa8734268
commit
6846ebf964
@ -39,15 +39,16 @@ dockershell:
|
||||
build: genclidocs
|
||||
$(DOCSC) npm run build
|
||||
|
||||
genclidocs: ${MDGEN_BINARY}
|
||||
genclidocs: _validatemdgen ${MDGEN_BINARY}
|
||||
@echo 'Auto-generating Corso CLI docs...'
|
||||
$(DOCSC) rm -rf docs/cli
|
||||
$(GOC) ${MDGEN_BINARY} --cli-folder ${CLI_DOCS}
|
||||
|
||||
_validatemdgen: # in case we have a different architecture
|
||||
@echo 'Verifying dependencies...'
|
||||
$(GOC) ${MDGEN_BINARY} --help >/dev/null || $(GOC) rm -rf ${MDGEN_BINARY}
|
||||
|
||||
${MDGEN_BINARY}: $(shell find ${CORSO_LOCAL_PATH}/src -type f -name *.go) $(shell find ${CORSO_LOCAL_PATH}/src -type d ) _validatemdgen
|
||||
${MDGEN_BINARY}: $(shell find ${CORSO_LOCAL_PATH}/src -type f -name *.go) $(shell find ${CORSO_LOCAL_PATH}/src -type d )
|
||||
@echo 'Re-building Corso CLI docs auto-gen tooling...'
|
||||
$(GOC) go mod download
|
||||
$(GOC) go build -o ${MDGEN_BINARY} ${MDGEN_SRC}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user