From 41f4a86947db2c603026375d7af23899bba7902d Mon Sep 17 00:00:00 2001 From: Steven de Ridder Date: Wed, 2 Feb 2022 09:49:52 +0100 Subject: [PATCH] divided submodules.list into open and closed. --- scripts/setup_submodules | 27 +++++++++++++-------------- scripts/submodules.list | 4 +++- 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/scripts/setup_submodules b/scripts/setup_submodules index 5c19076..0aad384 100755 --- a/scripts/setup_submodules +++ b/scripts/setup_submodules @@ -3,10 +3,8 @@ # =============================================== # == Setting some environment variables # =============================================== -GIT_URL_SUBS="http://gitlab.osdev.nl/open_source" -GIT_URL_SUBS_CLOSED="http://gitlab.osdev.nl/closed_source" - -OPEN_REPOS=("mqtt-cpp" "transqueue" "orm" "network" "jobscheduler" "global" "dbconnector" "logutils" "pugixml" "qt-mqtt" "iputils" "crypter" "qt-bluetooth" "versioning" "cmake") +GIT_URL_OPEN="http://gitlab.osdev.nl/open_source" +GIT_URL_CLOSED="git@gitlab.osdev.nl:closed_source" FUNC_RESULT="-1" @@ -102,18 +100,19 @@ function read_submodules() function add_submodules() { echo -e "Adding SubModule(s)." - for SUB_MODULE in ${SUB_MODULES} + for SUB_MODULE in ${SUB_MODULES_OPEN} do - echo -e "< ${SUB_MODULE} >" - if [[ "${OPEN_REPOS[*]}" =~ "${SUB_MODULE}" ]]; - then - git submodule add -f ${GIT_URL_SUBS}/${SUB_MODULE}.git submodules/${SUB_MODULE} - git config submodule.${SUB_MODULE}.url ${GIT_URL_SUBS}/${SUB_MODULE}.git - else - git submodule add -f ${GIT_URL_SUBS_CLOSED}/${SUB_MODULE}.git submodules/${SUB_MODULE} - git config submodule.${SUB_MODULE}.url ${GIT_URL_SUBS_CLOSED}/${SUB_MODULE}.git - fi + git submodule add -f ${GIT_URL_OPEN}/${SUB_MODULE}.git submodules/${SUB_MODULE} + git config submodule.${SUB_MODULE}.url ${GIT_URL_OPEN}/${SUB_MODULE}.git + done + + for SUB_MODULE in ${SUB_MODULES_CLOSED} + do + echo {GIT_URL_CLOSED}/${SUB_MODULE}.git + git submodule add -f ${GIT_URL_CLOSED}/${SUB_MODULE}.git submodules/${SUB_MODULE} + git config submodule.${SUB_MODULE}.url ${GIT_URL_CLOSED}/${SUB_MODULE}.git done + } # Name : get_submodules diff --git a/scripts/submodules.list b/scripts/submodules.list index 49b09ae..3ff00aa 100644 --- a/scripts/submodules.list +++ b/scripts/submodules.list @@ -1,3 +1,5 @@ -SUB_MODULES="versioning +SUB_MODULES_OPEN="versioning cmake logutils" + +SUB_MODULES_CLOSED="" -- libgit2 0.21.4