Browse Source

Update syno_hdd_db.sh

pull/164/head
Dave Russell 2 years ago
committed by GitHub
parent
commit
74c465e1a9
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      syno_hdd_db.sh

4
syno_hdd_db.sh

@ -728,12 +728,12 @@ fi
fixdrivemodel(){ fixdrivemodel(){
# Remove " 00Y" from end of Samsung/Lenovo SSDs # Github issue #13 # Remove " 00Y" from end of Samsung/Lenovo SSDs # Github issue #13
if [[ $1 =~ MZ.*" 00Y" ]]; then if [[ $1 ]]; then
hdmodel=$(printf "%s" "$1" | sed 's/ 00Y.*//') hdmodel=$(printf "%s" "$1" | sed 's/ 00Y.*//')
fi fi
# Brands that return "BRAND <model>" and need "BRAND " removed. # Brands that return "BRAND <model>" and need "BRAND " removed.
if [[ $1 ]]; then if [[ $1 =~ ^[A-Za-z]{1,7}" ".* ]]; then
# See Smartmontools database in /var/lib/smartmontools/drivedb.db # See Smartmontools database in /var/lib/smartmontools/drivedb.db
hdmodel=${hdmodel#"WDC "} # Remove "WDC " from start of model name hdmodel=${hdmodel#"WDC "} # Remove "WDC " from start of model name
hdmodel=${hdmodel#"HGST "} # Remove "HGST " from start of model name hdmodel=${hdmodel#"HGST "} # Remove "HGST " from start of model name

Loading…
Cancel
Save