diff options
| -rw-r--r-- | cmake/hugo.cmake | 4 | ||||
| -rw-r--r-- | web/CMakeLists.txt | 7 | 
2 files changed, 9 insertions, 2 deletions
diff --git a/cmake/hugo.cmake b/cmake/hugo.cmake index e065f8b..0180958 100644 --- a/cmake/hugo.cmake +++ b/cmake/hugo.cmake @@ -2,7 +2,7 @@  # License, v. 2.0. If a copy of the MPL was not distributed with this  # file, You can obtain one at https://mozilla.org/MPL/2.0/. -function(hugo_site target source sink) +function(hugo_site target source sink dependencies)  	add_custom_target(  		"${target}"  		ALL @@ -16,6 +16,6 @@ function(hugo_site target source sink)  		COMMAND  			hugo --source ${source} --destination ${sink}  		DEPENDS -			${source} +			${dependencies}  	)  endfunction() diff --git a/web/CMakeLists.txt b/web/CMakeLists.txt index 0cdb498..92af0cb 100644 --- a/web/CMakeLists.txt +++ b/web/CMakeLists.txt @@ -2,8 +2,15 @@ cmake_minimum_required(VERSION 3.10)  include(hugo) +set(dependencies +	hugo.toml +	layouts/baseof.html +	layouts/home.html +) +  hugo_site(  	"website"  	"${CMAKE_CURRENT_SOURCE_DIR}"  	"${CMAKE_CURRENT_BINARY_DIR}/public" +	"${dependencies}"  )  | 
