Browse Source

Merge pull request #31 from 007revad/develop

Develop
pull/91/head v1.2.23
007revad 3 years ago
committed by GitHub
parent
commit
429204e687
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      CHANGES.txt
  2. 13
      syno_hdd_db.sh

3
CHANGES.txt

@ -1,3 +1,6 @@
v1.2.23
- Changed to show if no M.2 cards were found, if M.2 drives were found.
v1.2.22 v1.2.22
- Changed 'latest version check' to download to /tmp and extract files to the script's location to fix issue #27. - Changed 'latest version check' to download to /tmp and extract files to the script's location to fix issue #27.

13
syno_hdd_db.sh

@ -29,6 +29,8 @@
# It's also parsed and checked and probably in some cases it could be more critical to patch that one instead. # It's also parsed and checked and probably in some cases it could be more critical to patch that one instead.
# DONE # DONE
# Changed to show if no M.2 cards were found, if M.2 drives were found.
#
# Changed latest version check to download to /tmp and extract files to the script's location. # Changed latest version check to download to /tmp and extract files to the script's location.
# #
# Added a timeouts when checking for newer script version in case github is down or slow. # Added a timeouts when checking for newer script version in case github is down or slow.
@ -57,7 +59,6 @@
# #
# Fixed bug where "M.2 volume support already enabled" message appeared when NAS had no M.2 drives. # Fixed bug where "M.2 volume support already enabled" message appeared when NAS had no M.2 drives.
# #
#
# Added check that M.2 volume support is enabled (on supported models). # Added check that M.2 volume support is enabled (on supported models).
# #
# Added support for M.2 SATA drives. # Added support for M.2 SATA drives.
@ -88,7 +89,7 @@
# Optionally disable "support_disk_compatibility". # Optionally disable "support_disk_compatibility".
scriptver="v1.2.22" scriptver="v1.2.23"
script=Synology_HDD_db script=Synology_HDD_db
repo="007revad/Synology_HDD_db" repo="007revad/Synology_HDD_db"
@ -114,7 +115,7 @@ $script $scriptver - by 007revad
Usage: $(basename "$0") [options] Usage: $(basename "$0") [options]
Options: Options:
-s, --showedits Show the edits made to host db file(s) -s, --showedits Show edits made to <model>_host db and db.new file(s)
-n, --noupdate Prevent DSM updating the compatible drive databases -n, --noupdate Prevent DSM updating the compatible drive databases
-m, --m2 Don't process M.2 drives -m, --m2 Don't process M.2 drives
-f, --force Force DSM to not check drive compatibility -f, --force Force DSM to not check drive compatibility
@ -474,7 +475,10 @@ if [[ ${#m2cardlist[@]} -gt "0" ]]; then
fi fi
# Check m2cards array isn't empty # Check m2cards array isn't empty
if [[ ${#m2cards[@]} -gt "0" ]]; then if [[ $m2 != "no" ]]; then
if [[ ${#m2cards[@]} -eq "0" ]]; then
echo -e "No M.2 cards found\n"
else
echo "M.2 card models found: ${#m2cards[@]}" echo "M.2 card models found: ${#m2cards[@]}"
num="0" num="0"
while [[ $num -lt "${#m2cards[@]}" ]]; do while [[ $num -lt "${#m2cards[@]}" ]]; do
@ -482,6 +486,7 @@ if [[ ${#m2cards[@]} -gt "0" ]]; then
num=$((num +1)) num=$((num +1))
done done
echo echo
fi
fi fi

Loading…
Cancel
Save