[FIX] script with nproc jobs, support osx

This commit is contained in:
Mathieu Benoit 2026-02-12 00:52:32 -05:00
parent 8c3a3fb4c1
commit 268cbae712
5 changed files with 35 additions and 5 deletions

View file

@ -14,10 +14,16 @@ else
MANIFEST_TARGET="$EL_MANIFEST_DEV"
fi
if command -v nproc >/dev/null 2>&1; then
JOBS="$(nproc --all)"
else
JOBS="$(sysctl -n hw.ncpu)"
fi
# Generate local manifest
.venv.erplibre/bin/python ./script/git/git_merge_repo_manifest.py --output .repo/local_manifests/erplibre_manifest.xml --with_OCA
.venv.erplibre/bin/repo init -u git://127.0.0.1:9418/ -b $(git rev-parse --verify HEAD) -m ${MANIFEST_TARGET} "$@"
.venv.erplibre/bin/repo sync -c -j $(nproc --all) -v -m ${MANIFEST_TARGET}
.venv.erplibre/bin/repo sync -c -j "$JOBS" -v -m ${MANIFEST_TARGET}
kill ${DAEMON_PID}

View file

@ -15,7 +15,13 @@ else
MANIFEST_TARGET="$EL_MANIFEST_DEV"
fi
if command -v nproc >/dev/null 2>&1; then
JOBS="$(nproc --all)"
else
JOBS="$(sysctl -n hw.ncpu)"
fi
.venv.erplibre/bin/repo init -u git://127.0.0.1:9418/ -b $(git rev-parse --verify HEAD) -m ${MANIFEST_TARGET} -g base,code_generator
.venv.erplibre/bin/repo sync -c -j $(nproc --all) -v -m ${MANIFEST_TARGET}
.venv.erplibre/bin/repo sync -c -j "$JOBS" -v -m ${MANIFEST_TARGET}
kill ${DAEMON_PID}

View file

@ -14,10 +14,16 @@ else
MANIFEST_TARGET="$EL_MANIFEST_DEV"
fi
if command -v nproc >/dev/null 2>&1; then
JOBS="$(nproc --all)"
else
JOBS="$(sysctl -n hw.ncpu)"
fi
# Generate local manifest
.venv.erplibre/bin/python ./script/git/git_merge_repo_manifest.py --output .repo/local_manifests/erplibre_manifest.xml --with_mobile
.venv.erplibre/bin/repo init -u git://127.0.0.1:9418/ -b $(git rev-parse --verify HEAD) -m ${MANIFEST_TARGET} "$@"
.venv.erplibre/bin/repo sync -c -j $(nproc --all) -v -m ${MANIFEST_TARGET}
.venv.erplibre/bin/repo sync -c -j "$JOBS" -v -m ${MANIFEST_TARGET}
kill ${DAEMON_PID}

View file

@ -15,7 +15,13 @@ else
MANIFEST_TARGET="$EL_MANIFEST_DEV"
fi
if command -v nproc >/dev/null 2>&1; then
JOBS="$(nproc --all)"
else
JOBS="$(sysctl -n hw.ncpu)"
fi
.venv.erplibre/bin/repo init -u git://127.0.0.1:9418/ -b $(git rev-parse --verify HEAD) -m ${MANIFEST_TARGET}
.venv.erplibre/bin/repo sync -c -j $(nproc --all) -v -m ${MANIFEST_TARGET}
.venv.erplibre/bin/repo sync -c -j "$JOBS" -v -m ${MANIFEST_TARGET}
kill ${DAEMON_PID}

View file

@ -5,6 +5,12 @@
#EL_MANIFEST_PROD="./default.xml"
#EL_MANIFEST_DEV="./manifest/default.dev.xml"
if command -v nproc >/dev/null 2>&1; then
JOBS="$(nproc --all)"
else
JOBS="$(sysctl -n hw.ncpu)"
fi
# Update git-repo
.venv.erplibre/bin/repo init -u https://github.com/ERPLibre/ERPLibre -b $(git rev-parse --verify HEAD)
.venv.erplibre/bin/repo sync -v -j $(nproc --all)
.venv.erplibre/bin/repo sync -v -j "$JOBS"