This commit is contained in:
2024-11-14 16:11:00 -05:00
parent b4a8dd848a
commit 1af25d6c61
7 changed files with 199 additions and 62 deletions
+2 -2
View File
@@ -2,8 +2,8 @@
autoload -U compinit
compinit
if [[ -e "$JJ_SOURCE_DIR/~~tmp/shEnvs.sh" ]]; then
source $JJ_SOURCE_DIR/~~tmp/shEnvs.sh
if [[ -e "$JJ_DATA_DIR/~~tmp/shEnvs.sh" ]]; then
source $JJ_DATA_DIR/~~tmp/shEnvs.sh
fi
+17 -17
View File
@@ -17,8 +17,8 @@ fi
if ! hash asdf || \
[[ ! -e $JJ_SOURCE_DIR/~~tmp/deps/asdf-tools-installed ]] \
|| jjIsFileNewerFile "$ASDF_DEFAULT_TOOL_VERSIONS_FILENAME" "$JJ_SOURCE_DIR/~~tmp/deps/asdf-tools-installed" ; then
[[ ! -e $JJ_DATA_DIR/~~tmp/deps/asdf-tools-installed ]] \
|| jjIsFileNewerFile "$ASDF_DEFAULT_TOOL_VERSIONS_FILENAME" "$JJ_DATA_DIR/~~tmp/deps/asdf-tools-installed" ; then
rm -rf $ASDF_DIR
git -c advice.detachedHead=false clone -q https://github.com/asdf-vm/asdf.git $ASDF_DIR --branch $ASDF_VERSION
@@ -39,9 +39,9 @@ if ! hash asdf || \
done <${ASDF_DEFAULT_TOOL_VERSIONS_FILENAME}
asdf install
set -e
rm -rf $JJ_SOURCE_DIR/~~tmp/deps
mkdir -p "$JJ_SOURCE_DIR/~~tmp/deps"
touch $JJ_SOURCE_DIR/~~tmp/deps/asdf-tools-installed
rm -rf $JJ_DATA_DIR/~~tmp/deps
mkdir -p "$JJ_DATA_DIR/~~tmp/deps"
touch $JJ_DATA_DIR/~~tmp/deps/asdf-tools-installed
jjCliLog jjLogSuccess "Asdf and tools installed"
fi
@@ -50,41 +50,41 @@ if [[ -e $ASDF_DIR/asdf.sh ]]; then
fi
if [[ ! -e $JJ_SOURCE_DIR/~~tmp/deps/bun-packages-installed ]] \
|| jjIsFileNewerFile "$JJ_WORKSPACE_DIR/package.json" "$JJ_SOURCE_DIR/~~tmp/deps/bun-packages-installed" \
|| jjIsFileNewerFile "$JJ_WORKSPACE_DIR/bun.lockb" "$JJ_SOURCE_DIR/~~tmp/deps/bun-packages-installed" \
if [[ ! -e $JJ_DATA_DIR/~~tmp/deps/bun-packages-installed ]] \
|| jjIsFileNewerFile "$JJ_WORKSPACE_DIR/package.json" "$JJ_DATA_DIR/~~tmp/deps/bun-packages-installed" \
|| jjIsFileNewerFile "$JJ_WORKSPACE_DIR/bun.lockb" "$JJ_DATA_DIR/~~tmp/deps/bun-packages-installed" \
; then
pushd $JJ_WORKSPACE_DIR > /dev/null
bun install
popd > /dev/null
touch $JJ_SOURCE_DIR/~~tmp/deps/bun-packages-installed
touch $JJ_DATA_DIR/~~tmp/deps/bun-packages-installed
jjCliLog jjLogSuccess "Bun dependencies successfully installed"
fi
if [[ ! -e $JJ_SOURCE_DIR/~~tmp/deps/python-packages-installed ]] \
|| jjIsFileNewerFile "$JJ_WORKSPACE_DIR/requirements.txt" "$JJ_SOURCE_DIR/~~tmp/deps/python-packages-installed" \
if [[ ! -e $JJ_DATA_DIR/~~tmp/deps/python-packages-installed ]] \
|| jjIsFileNewerFile "$JJ_WORKSPACE_DIR/requirements.txt" "$JJ_DATA_DIR/~~tmp/deps/python-packages-installed" \
; then
pushd $JJ_WORKSPACE_DIR > /dev/null
pip install -r requirements.txt || pip3 install -r requirements.txt
popd > /dev/null
touch $JJ_SOURCE_DIR/~~tmp/deps/python-packages-installed
touch $JJ_DATA_DIR/~~tmp/deps/python-packages-installed
jjCliLog jjLogSuccess "Python dependencies successfully installed"
fi
if [[ ! -e $JJ_SOURCE_DIR/~~tmp/deps/npmGlobalDependencies-installed ]] \
|| jjIsFileNewerFile "$JJ_SOURCE_DIR/~~tmp/npmGlobalDependencies.txt" "$JJ_SOURCE_DIR/~~tmp/deps/npmGlobalDependencies-installed" \
if [[ ! -e $JJ_DATA_DIR/~~tmp/deps/npmGlobalDependencies-installed ]] \
|| jjIsFileNewerFile "$JJ_DATA_DIR/~~tmp/npmGlobalDependencies.txt" "$JJ_DATA_DIR/~~tmp/deps/npmGlobalDependencies-installed" \
; then
pushd $JJ_WORKSPACE_DIR > /dev/null
eval "npm i -g $BUN_GLOBAL_DEPENDENCIES"
popd > /dev/null
touch $JJ_SOURCE_DIR/~~tmp/deps/npmGlobalDependencies-installed
touch $JJ_DATA_DIR/~~tmp/deps/npmGlobalDependencies-installed
jjCliLog jjLogSuccess "Global dependencies successfully installed"
fi
if [[ ! -e $JJ_SOURCE_DIR/~~tmp/deps/libpq-installed ]]; then
if [[ ! -e $JJ_DATA_DIR/~~tmp/deps/libpq-installed ]]; then
if [[ ${UNAME} == "Linux" ]]; then
eval "$PACKAGE_MANAGER_INSTALL libpq-dev g++ make"
else
@@ -92,7 +92,7 @@ if [[ ! -e $JJ_SOURCE_DIR/~~tmp/deps/libpq-installed ]]; then
eval "$PACKAGE_MANAGER_INSTALL postgresql@14"
fi
touch $JJ_SOURCE_DIR/~~tmp/deps/libpq-installed
touch $JJ_DATA_DIR/~~tmp/deps/libpq-installed
fi
if [[ ! -d "$JJ_GIT_METADATA_DIR" ]]; then