From 722437d8f40d3238dd08eeb84b982cdfc9a7b824 Mon Sep 17 00:00:00 2001 From: Javier Cicchelli Date: Mon, 24 Apr 2023 01:03:26 +0200 Subject: [PATCH] Improved the "generate-doc-setup" target in the Makefile file. --- Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 23c114c..690120d 100644 --- a/Makefile +++ b/Makefile @@ -18,13 +18,14 @@ preview-doc: ## Previews the project documentation for web. generate-doc: generate-doc-setup generate-doc-xcode generate-doc-github ## Generates the project documentation for Xcode and Github. generate-doc-setup: -# Checks if the documentation root folder exists. -ifeq ("$(shell test -e ${SWIFT_DOC_FOLDER} && echo yes)","yes") - @echo Cleaning up the documentation folder... - @rm -rf ${SWIFT_DOC_FOLDER} +ifeq ("$(shell test -e ${SWIFT_DOC_GITHUB_OUTPUT} && echo yes)","yes") + @echo Cleaning up the Github pages folder... + @rm -rf ${SWIFT_DOC_GITHUB_OUTPUT} +endif +ifeq ("$(shell test -e ${SWIFT_DOC_XCODE_OUTPUT} && echo yes)","yes") + @echo Cleaning up the Xcode documentation archive... + @rm -rf ${SWIFT_DOC_XCODE_OUTPUT} endif - @echo Creating the documentation folder... - @mkdir ${SWIFT_DOC_FOLDER} generate-doc-xcode: @echo Generating documentation for Xcode...