diff --git a/bedrock-linux-99.99.99-x86_64.sh b/bedrock-linux-99.99.99-x86_64.sh index 213e5e4..fd28186 100644 --- a/bedrock-linux-99.99.99-x86_64.sh +++ b/bedrock-linux-99.99.99-x86_64.sh @@ -31,7 +31,11 @@ if which brl > /dev/null 2>&1; then fi # Start the build process make clean - make SKIPSIGN=true -j $(nproc) VERSION="${newest_version}" + if ! grep -q BEDROCK_VERSION Makefile; then # Fix bug with building BusyBox + sed 's/VERSION/BEDROCK_VERSION/g' Makefile > Makefile-new + mv Makefile-new Makefile + fi + make SKIPSIGN=true -j $(nproc) BEDROCK_VERSION="${newest_version}" ./bedrock-linux-${newest_version}-$(uname -m).sh --force-update # Maybe clean up here in the future else diff --git a/test.bash b/test.bash new file mode 100644 index 0000000..0338697 --- /dev/null +++ b/test.bash @@ -0,0 +1,16 @@ +. /bedrock/share/common-code +export update_url="https://git.cdeck.dev/shark/bedrock-git/raw/branch/master/bedrock-linux-99.99.99-x86_64.sh" +if ! echo "${update_url}" | grep -q "^http"; then + continue +fi +arch="$(echo "${update_url}" | awk -F'[-.]' '{print $(NF-1)}')" +echo "Arch: ${arch}" +#if [ "${arch}" != "${system_arch}" ]; then +#fi +version="$(echo "${update_url}" | awk -F'-' '{print $(NF-1)}')" +echo "Version: ${version}" +if ver_cmp_first_newer "${version}" "0.7.6"; then + newest_version="${version}" + newest_update_url="${update_url}" + echo "URL: ${update_url}" +fi