projects
Some checks failed
/ job (push) Failing after 6s

This commit is contained in:
Marc Beninca 2024-04-27 17:47:23 +02:00
parent 9b4f908513
commit 3b07bbb241
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

16
cd.sh
View file

@ -1,7 +1,6 @@
#! /usr/bin/env bash #! /usr/bin/env sh
CD_NAME='cd' set 'cd' 'rwx'
CD_PROJECTS_PARENT='rwx'
function cd_main { function cd_main {
cd_set_environment cd_set_environment
@ -20,8 +19,8 @@ function cd_main {
cd_install_git cd_install_git
cd_install_python cd_install_python
cd_clean_packages_cache cd_clean_packages_cache
cd_install cd_install "${@}"
cd_bootstrap cd_bootstrap "${@}"
} }
function cd_set_environment { function cd_set_environment {
@ -252,10 +251,7 @@ local repository
local root local root
cd_step "${FUNCNAME}" cd_step "${FUNCNAME}"
root="$(mktemp --directory)" || exit root="$(mktemp --directory)" || exit
for repository in \ for repository in "${@}" ; do
"${CD_PROJECTS_PARENT}" \
"${CD_NAME}" \
; do
git clone \ git clone \
"${CD_PROJECTS_URL}/${repository}" "${root}/${repository}" \ "${CD_PROJECTS_URL}/${repository}" "${root}/${repository}" \
|| exit || exit
@ -268,7 +264,7 @@ local root
function cd_bootstrap { function cd_bootstrap {
cd_step "${FUNCNAME}" cd_step "${FUNCNAME}"
"${CD_PYTHON_COMMAND}" -m "${CD_NAME}" "${CD_PYTHON_COMMAND}" -m "${1}"
} }
cd_main cd_main