Loading src/build.sh +6 −2 Original line number Original line Diff line number Diff line Loading @@ -20,6 +20,10 @@ # cd to working directory # cd to working directory cd "$SRC_DIR" || return 1 cd "$SRC_DIR" || return 1 # Determine the number of parallel jobs to use for repo sync nproc_value=$(nproc --all) JOBS=$(( nproc_value > 10 ? 10 : nproc_value )) if [ -f /root/userscripts/begin.sh ]; then if [ -f /root/userscripts/begin.sh ]; then echo ">> [$(date)] Running begin.sh" echo ">> [$(date)] Running begin.sh" /root/userscripts/begin.sh /root/userscripts/begin.sh Loading Loading @@ -186,7 +190,7 @@ if [ -n "${BRANCH_NAME}" ] && [ -n "${DEVICE}" ]; then echo ">> [$(date)] Syncing branch repository" echo ">> [$(date)] Syncing branch repository" builddate=$(date +%Y%m%d) builddate=$(date +%Y%m%d) repo_out=$(repo sync -c -j$(nproc --all) --force-sync 2>&1 >/dev/null) repo_out=$(repo sync -c -j"$JOBS" --force-sync 2>&1 >/dev/null) repo_status=$? repo_status=$? echo -e $repo_out echo -e $repo_out Loading Loading @@ -267,7 +271,7 @@ if [ -n "${BRANCH_NAME}" ] && [ -n "${DEVICE}" ]; then echo ">> [$(date)] Syncing branch repository" echo ">> [$(date)] Syncing branch repository" cd "$SRC_DIR/$branch_dir" || return 1 cd "$SRC_DIR/$branch_dir" || return 1 if ! repo sync -c -j$(nproc --all) --force-sync; then if ! repo sync -c -j"$JOBS" --force-sync; then sync_successful=false sync_successful=false build_device=false build_device=false fi fi Loading Loading
src/build.sh +6 −2 Original line number Original line Diff line number Diff line Loading @@ -20,6 +20,10 @@ # cd to working directory # cd to working directory cd "$SRC_DIR" || return 1 cd "$SRC_DIR" || return 1 # Determine the number of parallel jobs to use for repo sync nproc_value=$(nproc --all) JOBS=$(( nproc_value > 10 ? 10 : nproc_value )) if [ -f /root/userscripts/begin.sh ]; then if [ -f /root/userscripts/begin.sh ]; then echo ">> [$(date)] Running begin.sh" echo ">> [$(date)] Running begin.sh" /root/userscripts/begin.sh /root/userscripts/begin.sh Loading Loading @@ -186,7 +190,7 @@ if [ -n "${BRANCH_NAME}" ] && [ -n "${DEVICE}" ]; then echo ">> [$(date)] Syncing branch repository" echo ">> [$(date)] Syncing branch repository" builddate=$(date +%Y%m%d) builddate=$(date +%Y%m%d) repo_out=$(repo sync -c -j$(nproc --all) --force-sync 2>&1 >/dev/null) repo_out=$(repo sync -c -j"$JOBS" --force-sync 2>&1 >/dev/null) repo_status=$? repo_status=$? echo -e $repo_out echo -e $repo_out Loading Loading @@ -267,7 +271,7 @@ if [ -n "${BRANCH_NAME}" ] && [ -n "${DEVICE}" ]; then echo ">> [$(date)] Syncing branch repository" echo ">> [$(date)] Syncing branch repository" cd "$SRC_DIR/$branch_dir" || return 1 cd "$SRC_DIR/$branch_dir" || return 1 if ! repo sync -c -j$(nproc --all) --force-sync; then if ! repo sync -c -j"$JOBS" --force-sync; then sync_successful=false sync_successful=false build_device=false build_device=false fi fi Loading