Updated the tasks in the Makefile file that are related to the DocC documentation generation and preview.
This commit is contained in:
@@ -12,10 +12,13 @@
|
|||||||
|
|
||||||
# --- DOCUMENTATION ---
|
# --- DOCUMENTATION ---
|
||||||
|
|
||||||
DOCC_GITHUB_OUTPUT=./docs
|
DOCC_ARCHIVE_BASE_PATH=archives/${DOCC_ARCHIVE_REFERENCE}
|
||||||
|
DOCC_ARCHIVE_OUTPUT=./${SPM_LIBRARY_TARGET}.doccarchive
|
||||||
|
DOCC_ARCHIVE_REFERENCE=hummingbirddocc
|
||||||
|
DOCC_CONFIG_MINIMUM_ACCESS_LEVEL=public
|
||||||
|
DOCC_CONFIG_PREVIEW_URL=http://localhost:8080/documentation/${DOCC_ARCHIVE_REFERENCE}
|
||||||
DOCC_GITHUB_BASE_PATH=hummingbird-docc
|
DOCC_GITHUB_BASE_PATH=hummingbird-docc
|
||||||
DOCC_PREVIEW_URL=http://localhost:8080/documentation/hummingbirddocc
|
DOCC_GITHUB_OUTPUT=./docs
|
||||||
DOCC_XCODE_OUTPUT=./${SPM_LIBRARY_TARGET}.doccarchive
|
|
||||||
|
|
||||||
# -- SWIFT PACKAGE MANAGER ---
|
# -- SWIFT PACKAGE MANAGER ---
|
||||||
|
|
||||||
|
|||||||
@@ -49,8 +49,8 @@ pkg-reset: ## Resets the complete SPM cache/build folder of the package
|
|||||||
@swift package reset
|
@swift package reset
|
||||||
|
|
||||||
pkg-pristine: pkg-clean pkg-reset ## Deletes all built artifacts, caches, and documentations of the package
|
pkg-pristine: pkg-clean pkg-reset ## Deletes all built artifacts, caches, and documentations of the package
|
||||||
|
@rm -drf $(DOCC_ARCHIVE_OUTPUT)
|
||||||
@rm -drf $(DOCC_GITHUB_OUTPUT)
|
@rm -drf $(DOCC_GITHUB_OUTPUT)
|
||||||
@rm -drf $(DOCC_XCODE_OUTPUT)
|
|
||||||
|
|
||||||
pkg-outdated: ## Lists the SPM package dependencies that can be updated
|
pkg-outdated: ## Lists the SPM package dependencies that can be updated
|
||||||
@swift package update --dry-run
|
@swift package update --dry-run
|
||||||
@@ -60,7 +60,18 @@ pkg-update: ## Updates the SPM package dependencies
|
|||||||
|
|
||||||
# DOCUMENTATION
|
# DOCUMENTATION
|
||||||
|
|
||||||
doc-generate: doc-generate-xcode doc-generate-github ## Generates the library documentation for both Github and Xcode
|
doc-generate: doc-generate-archive doc-generate-github ## Generates the library documentation for both Github and Xcode
|
||||||
|
|
||||||
|
doc-generate-archive: ## Generates the library documentation archive for Xcode
|
||||||
|
@swift package \
|
||||||
|
--allow-writing-to-directory $(DOCC_ARCHIVE_OUTPUT) \
|
||||||
|
generate-documentation \
|
||||||
|
--target $(SPM_LIBRARY_TARGET) \
|
||||||
|
--hosting-base-path $(DOCC_ARCHIVE_BASE_PATH) \
|
||||||
|
--output-path $(DOCC_ARCHIVE_OUTPUT) \
|
||||||
|
--symbol-graph-minimum-access-level $(DOCC_CONFIG_MINIMUM_ACCESS_LEVEL) \
|
||||||
|
--include-extended-types \
|
||||||
|
--enable-inherited-docs
|
||||||
|
|
||||||
doc-generate-github: ## Generates the library documentation for Github
|
doc-generate-github: ## Generates the library documentation for Github
|
||||||
@swift package \
|
@swift package \
|
||||||
@@ -70,21 +81,20 @@ doc-generate-github: ## Generates the library documentation for Github
|
|||||||
--disable-indexing \
|
--disable-indexing \
|
||||||
--transform-for-static-hosting \
|
--transform-for-static-hosting \
|
||||||
--hosting-base-path $(DOCC_GITHUB_BASE_PATH) \
|
--hosting-base-path $(DOCC_GITHUB_BASE_PATH) \
|
||||||
--output-path $(DOCC_GITHUB_OUTPUT)
|
--output-path $(DOCC_GITHUB_OUTPUT) \
|
||||||
|
--symbol-graph-minimum-access-level $(DOCC_CONFIG_MINIMUM_ACCESS_LEVEL) \
|
||||||
doc-generate-xcode: ## Generates the library documentation for Xcode
|
--include-extended-types \
|
||||||
@swift package \
|
--enable-inherited-docs
|
||||||
--allow-writing-to-directory $(DOCC_XCODE_OUTPUT) \
|
|
||||||
generate-documentation \
|
|
||||||
--target $(SPM_LIBRARY_TARGET) \
|
|
||||||
--output-path $(DOCC_XCODE_OUTPUT)
|
|
||||||
|
|
||||||
doc-preview: ## Previews the library documentation in Safari
|
doc-preview: ## Previews the library documentation in Safari
|
||||||
@open -a safari $(DOCC_PREVIEW_URL)
|
@open -a safari $(DOCC_CONFIG_PREVIEW_URL)
|
||||||
@swift package \
|
@swift package \
|
||||||
--disable-sandbox \
|
--disable-sandbox \
|
||||||
preview-documentation \
|
preview-documentation \
|
||||||
--target $(SPM_LIBRARY_TARGET)
|
--target $(SPM_LIBRARY_TARGET) \
|
||||||
|
--symbol-graph-minimum-access-level $(DOCC_CONFIG_MINIMUM_ACCESS_LEVEL) \
|
||||||
|
--include-extended-types \
|
||||||
|
--enable-inherited-docs
|
||||||
|
|
||||||
# IDE
|
# IDE
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user