Golden Codes - armanexplorer planet

Practical code snippets for Django, Python, Bash, Git and All!

View on GitHub

Docs

Docs2

add to the gitlab ci file

variables:
  GIT_SUBMODULE_STRATEGY: recursive
  GIT_SUBMODULE_FORCE_HTTPS: "true"
  GIT_SUBMODULE_DEPTH: 1

enable access to submodeule repo

Ref

You should enable access to the submodule repo for the current repo which want to use it as git submodule

some example


git config -f .gitmodules submodule.$UPSTREAM_PROJECT_NAME.branch $UPSTREAM_BRANCH_NAME
git config --file .gitmodules --get-regexp '\.url$' | awk '{print $2}'

git config --file .gitmodules --get-regexp path

git submodule foreach --quiet 'echo $sm_path'

# temp access to submodule project when pipeline is running
(https://gitlab-ci-token:[MASKED]@gitlab.eridanus.ir/propision/ai/property-analytics.git)
(https://gitlab-ci-token:[MASKED]@gitlab.eridanus.ir/propision/ai/property-analytics.git)

https://gitlab-ci-token:[MASKED]@gitlab.eridanus.ir/propision/ai/property-analytics.git
https://gitlab-ci-token:[MASKED]@gitlab.eridanus.ir/propision/ai/property-analytics.git