Skip to content

Commit

Permalink
randomize updates
Browse files Browse the repository at this point in the history
  • Loading branch information
Steveorevo committed Sep 18, 2023
1 parent 09f5e71 commit 1e3ac5f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions hooks/pluginable.php
Original file line number Diff line number Diff line change
Expand Up @@ -572,6 +572,7 @@ function update_plugins() {

// Do a force reset on the repo to avoid merge conflicts, and obtain found latest version
$cmd = 'cd ' . $subfolder . ' && git reset --hard';
$cmd .= ' && sleep ' . mt_rand(1, 60); // Random sleep to avoid git rate limiting
$cmd .= ' && git clean -f -d';
$cmd .= ' && git fetch --all';
$cmd .= ' && git clone --depth 1 --branch "' . $latest_version . '" ' . $url . ' 2>/dev/null';
Expand Down

0 comments on commit 1e3ac5f

Please sign in to comment.