Skip to content

Commit

Permalink
Merge pull request #80 from 007revad/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
007revad authored Aug 1, 2024
2 parents aca2863 + c27e1e5 commit 25ee9c6
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGES.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v1.4.29
- Changed to show state of "Dedupe config menu for HDDs and 2.5 inch SSDs" even if --hdd option not used. Issue #79
- Now also shows "Run the script with the --hdd option if you want it enabled". Issue #79

v1.4.28
- Added support for DSM 7.0.1 to 7.2 (untested).
- Bug fix for when restoring storage_panel.js from backup.
Expand Down
14 changes: 11 additions & 3 deletions syno_enable_dedupe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

# Added support for DSM 7.0.1 to 7.2 (untested)

scriptver="v1.4.28"
scriptver="v1.4.29"
script=Synology_enable_Deduplication
repo="007revad/Synology_enable_Deduplication"
scriptname=syno_enable_dedupe
Expand Down Expand Up @@ -727,12 +727,13 @@ if [[ $check == "yes" ]]; then

# DSM 7.2.1 only and only if --hdd option used
# Dedupe config button for HDDs and 2.5 inch SSDs in DSM 7.2.1
if [[ -f "$strgmgr" ]] && [[ $hdd == "yes" ]]; then
if [[ -f "$strgmgr" ]]; then
# StorageManager package is installed and --hdd option used
if ! grep '&&e.dedup_info.show_config_btn' "$strgmgr" >/dev/null; then
echo -e "\nDedupe config menu for HDDs and 2.5\" SSDs already enabled."
echo -e "\nDedupe config menu for HDDs and 2.5\" SSDs is ${Cyan}enabled${Off}."
else
echo -e "\nDedupe config menu for HDDs and 2.5\" SSDs is ${Cyan}not${Off} enabled."
echo "Run the script with the --hdd option if you want it enabled."
fi
fi

Expand Down Expand Up @@ -976,6 +977,13 @@ if [[ -f "$strgmgr" ]] && [[ $hdd == "yes" ]]; then
else
echo -e "\nDedupe config menu for HDDs and 2.5\" SSDs already enabled."
fi
elif [[ -f "$strgmgr" ]]; then
if ! grep '&&e.dedup_info.show_config_btn' "$strgmgr" >/dev/null; then
echo -e "\nDedupe config menu for HDDs and 2.5\" SSDs is enabled."
else
echo -e "\nDedupe config menu for HDDs and 2.5\" SSDs not enabled."
echo "Run the script with the --hdd option if you want it enabled."
fi
fi


Expand Down

0 comments on commit 25ee9c6

Please sign in to comment.