series="$LATEST_SERIES"
fi
- latest="`wget -O- -q https://updates.drupal.org/release-history/drupal/${series}.x | grep -oPm1 "(?<=<download_link>)[^<]+" | grep -v -- '-dev' | grep -v -- '-alpha' | grep -v -- '-beta' | grep -v -- '-rc' | head -1`"
- latest="`basename $latest`"
-
- echo $latest | sed -e 's/^drupal-//' -e 's/.tar.gz$//'
+ if [ "$series" == "9" ]; then
+ latest="`wget -O- -q https://www.drupal.org/node/3060/release/feed | grep "<link>" ~/load/feed | grep "releases/9." | cut -d "/" -f 7 | cut -d '<' -f 1 | sort -r | head -1`"
+ echo $latest
+ else
+ latest="`wget -O- -q https://updates.drupal.org/release-history/drupal/${series}.x | grep -oPm1 "(?<=<download_link>)[^<]+" | grep -v -- '-dev' | grep -v -- '-alpha' | grep -v -- '-beta' | grep -v -- '-rc' | head -1`"
+ latest="`basename $latest`"
+ echo $latest | sed -e 's/^drupal-//' -e 's/.tar.gz$//'
+ fi
}
# Deploy a fresh drupal tree