diff --git a/.gitmodules b/.gitmodules index 3063baf..9e25602 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ [submodule "common"] path = common - url = git@github.com:G-Epitech/MAYBDF-ArcadeShared.git + url = https://github.com/G-Epitech/MAYBDF-ArcadeShared.git diff --git a/Jenkinsfile b/Jenkinsfile index 47e4a21..f09f005 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,12 +1,21 @@ pipeline { - agent { - docker { - image 'epitechcontent/epitest-docker' - } - } + agent any stages { + stage('Project setup') { + steps { + sh 'git rm --cached common' + sh 'make update' + } + } + stage('Project compilation') { + agent { + docker { + image 'epitechcontent/epitest-docker' + } + } + steps { sh 'make clean' sh 'make' @@ -15,6 +24,12 @@ pipeline { } stage('Project tests') { + agent { + docker { + image 'epitechcontent/epitest-docker' + } + } + steps { sh 'make tests_run' } diff --git a/Makefile b/Makefile index 2e39f2a..88a6311 100644 --- a/Makefile +++ b/Makefile @@ -8,7 +8,7 @@ NAME = arcade BUILD_PATH = build -all: +all: update @cmake -S . -B build cmake --build $(BUILD_PATH) @cp $(BUILD_PATH)/src/$(NAME) . @@ -24,5 +24,9 @@ re: fclean all tests_run: echo "pass" -.PHONY: all clean fclean re tests_run +update: + @git submodule init + @git submodule update + +.PHONY: all clean fclean re tests_run update DEFAULT_GOAL := all