From 6b7c4dba7b8fbbedf70454d08a5c31380ccb0084 Mon Sep 17 00:00:00 2001 From: Raphire <9938813+Raphire@users.noreply.github.com> Date: Wed, 4 Sep 2024 17:46:41 +0200 Subject: [PATCH] Added option to hide the 'Home' section from the File Explorer navigation pane Fixed certain options not working in Sysprep mode, see #106 --- Get.ps1 | 1 + README.md | 15 ++++++----- ...Disable_Show_More_Options_Context_Menu.reg | Bin 294 -> 290 bytes Regfiles/Hide_Gallery_from_Explorer.reg | Bin 342 -> 1458 bytes Regfiles/Hide_Home_from_Explorer.reg | Bin 0 -> 1492 bytes ...Disable_Show_More_Options_Context_Menu.reg | Bin 296 -> 488 bytes .../Sysprep/Hide_Gallery_from_Explorer.reg | Bin 1216 -> 1622 bytes Regfiles/Sysprep/Hide_Home_from_Explorer.reg | Bin 0 -> 1866 bytes Regfiles/Sysprep/Hide_Search_Taskbar.reg | Bin 302 -> 500 bytes Regfiles/Sysprep/Show_Search_Box.reg | Bin 302 -> 500 bytes Regfiles/Sysprep/Show_Search_Icon.reg | Bin 302 -> 500 bytes .../Sysprep/Show_Search_Icon_And_Label.reg | Bin 302 -> 500 bytes Regfiles/Undo/Show_Gallery_in_Explorer.reg | Bin 342 -> 1456 bytes Regfiles/Undo/Show_Home_from_Explorer.reg | Bin 0 -> 1490 bytes Win11Debloat.ps1 | 25 +++++++++++++----- 15 files changed, 27 insertions(+), 14 deletions(-) create mode 100644 Regfiles/Hide_Home_from_Explorer.reg create mode 100644 Regfiles/Sysprep/Hide_Home_from_Explorer.reg create mode 100644 Regfiles/Undo/Show_Home_from_Explorer.reg diff --git a/Get.ps1 b/Get.ps1 index bc13b26..d6f2550 100644 --- a/Get.ps1 +++ b/Get.ps1 @@ -31,6 +31,7 @@ param ( [switch]$ClearStart, [switch]$ClearStartAllUsers, [switch]$RevertContextMenu, + [switch]$HideHome, [switch]$HideGallery, [switch]$DisableOnedrive, [switch]$HideOnedrive, [switch]$Disable3dObjects, [switch]$Hide3dObjects, diff --git a/README.md b/README.md index 66795ce..feb1239 100644 --- a/README.md +++ b/README.md @@ -35,9 +35,9 @@ You can pick and choose exactly which modifications you want the script to make, - Show hidden files, folders and drives. - Show file extensions for known file types. -- Hide the gallery section from the File Explorer sidepanel. (Windows 11 only) -- Hide the 3D objects, music or onedrive folder from the File Explorer sidepanel. (Windows 10 only) -- Hide duplicate removable drive entries from the File Explorer sidepanel, so only the entry under 'This PC' remains. +- Hide the Home or Gallery section from the File Explorer navigation pane. (Windows 11 only) +- Hide the 3D objects, music or OneDrive folder from the File Explorer navigation pane. (Windows 10 only) +- Hide duplicate removable drive entries from the File Explorer navigation pane, so only the entry under 'This PC' remains. #### Taskbar @@ -317,7 +317,7 @@ The quick and advanced method support parameters to tailor the behaviour of the | -RevertContextMenu | Restore the old Windows 10 style context menu. (Windows 11 only) | | -ShowHiddenFolders | Show hidden files, folders and drives. | | -ShowKnownFileExt | Show file extensions for known file types. | -| -HideDupliDrive | Hide duplicate removable drive entries from the File Explorer sidepanel, so only the entry under 'This PC' remains. | +| -HideDupliDrive | Hide duplicate removable drive entries from the File Explorer navigation pane, so only the entry under 'This PC' remains. | | -TaskbarAlignLeft | Align taskbar icons to the left. (Windows 11 only) | | -HideSearchTb | Hide search icon from the taskbar. (Windows 11 only) | | -ShowSearchIconTb | Show search icon on the taskbar. (Windows 11 only) | @@ -326,10 +326,11 @@ The quick and advanced method support parameters to tailor the behaviour of the | -HideTaskview | Hide the taskview button from the taskbar. (Windows 11 only) | | -HideChat | Hide the chat (meet now) icon from the taskbar. | | -DisableWidgets | Disable the widget service & hide the widget (news and interests) icon from the taskbar. | -| -DisableCopilot | Disable Windows copilot. (Windows 11 only) | +| -DisableCopilot | Disable and remove Windows Copilot. (Windows 11 only) | | -DisableRecall | Disable Windows Recall snapshots. (Windows 11 only) | -| -HideGallery | Hide the gallery section from the File Explorer sidepanel. (Windows 11 only) | -| -HideOnedrive | Hide the onedrive folder from the File Explorer sidepanel. (Windows 10 only) | +| -HideHome | Hide the home section from the File Explorer navigation pane and adds a toggle in the File Explorer folder options. (Windows 11 only) | +| -HideGallery | Hide the gallery section from the File Explorer navigation pane and adds a toggle in the File Explorer folder options. (Windows 11 only) | +| -HideOnedrive | Hide the OneDrive folder from the File Explorer navigation pane. (Windows 10 only) | | -Hide3dObjects | Hide the 3D objects folder under 'This pc' in File Explorer. (Windows 10 only) | | -HideMusic | Hide the music folder under 'This pc' in File Explorer. (Windows 10 only) | | -HideIncludeInLibrary | Hide the 'Include in library' option in the context menu. (Windows 10 only) | diff --git a/Regfiles/Disable_Show_More_Options_Context_Menu.reg b/Regfiles/Disable_Show_More_Options_Context_Menu.reg index 0507468972296f544037b176b9b30ed7a6d2d8fc..eb00dc9e40435798a10bb6cb32644dbafa005d48 100644 GIT binary patch delta 7 OcmZ3+w1{bg5+eW#Bmy7+ delta 12 TcmZ3)w2Wzk5+e&Q0~Z4T6&M0L diff --git a/Regfiles/Hide_Gallery_from_Explorer.reg b/Regfiles/Hide_Gallery_from_Explorer.reg index cc5b2d055c15ae13d0c47f08c9f86dcdb46dde0e..235760a29535f1d691107d5c3f92867fb63f2e2e 100644 GIT binary patch literal 1458 zcmb`HUu)A~6vm%x!S4`q?ZzrPr{cxvrWWfqYPTUqT$iM?Sd-CownhBv)89F1Y|;uU zN=S3gd;Xv2dHenLTq9*llxwC!fqF`H#aW@LCR%WEh;@XPqX#;}KEXOd&(I%gTRS{= zb;sYQoV~=F;1}qH1{(8NjO8k0jyU~-&lTV4&rBz1nMVzmwPM{6H{mS9FF-3ilht}h zl~?rkRv*;XDSh|Qj?_m#)f?oVBEGqX#LmcVc_Mtr$c1MrT<_x5(E;*TJofzAWv&#z zEhbCVQjGKf=|1|F9%C737b#`Vn0E(Di#I0v5x?K`-nS8wdqJ%!o}bxN2l<4FGoLh} z+nk;U*it;Nkz%C2_nIoyGjh*-8;PD!rTNr%zK>_ZjxNaak%-yG_Ah+@*R_osrh%T* zk0E48&*@?8^$f9q-R0)@>I>|53_1{GK@y;9=4 zsUz6cG05zz3wp2lwn4YUW)2<0V|wiCoO8oC!ehjqCiGMA8om+MI*$$KI(M3^jW#BY z$eqARW1u0Bkg;TG#Y*E+xz{GAE1cU{Q(`}P^ck7PbnrV2TT7N4;JMn~pGKFrF7%s_ z!m}RR$l1m^Z}u9zscLqZa^17ZuM($_y!M}9n=q^`#(2Gcvo`ORovd!x|Gi(~a&vup zn=fa!u71t^mG=S;m#BoGRbh6?G;^l18x`{ZVJxU@#)iK|WaVGo?rLlQ@^4_>{Q$5! B?wbGr delta 10 RcmdnQeT`{C(8gUXi~txE1Lyz% diff --git a/Regfiles/Hide_Home_from_Explorer.reg b/Regfiles/Hide_Home_from_Explorer.reg new file mode 100644 index 0000000000000000000000000000000000000000..ffb3a91bed35871d749aacf9fb40f1277a62ac78 GIT binary patch literal 1492 zcmb`HZ*S626vm&|CVq#euhqDKZqqE0IOm9yEey68Yc`-|5E(Tsvk>D~SAXZ0OBuXS zqiIUdz32aPp2N={ml|uTSg8u-3e;Aj8}4$=lxe}u8?<9iDd#{J=rgoq&Qs3M^h8g2 z9_oR6UvhVhHpb4RRJTqlty}8pE7}{rvsH{UPE%(!TxJ>Qjw~5>Q|tmxIdbMQd?e~S zs`{WSy;hfs+nieJaPI0HxvhwAsv*7wu`N!7?F2b@k#cuF!K$f4hCyt_zseq#;X-2l6~llHMPiyAjWaM;JMrtkXXs(hsbh2-=(uJoR4Z>goHFB+|o zIik*qLo37HPz z=XXJj3Aukax1A+34za9o`%~|7J43fO3EXOfLkbR?T-jT(#Mt6ILn>Bu{fgyzyZ+}TL#F{B z5;=^A;3p0f*)-*azJ~&}J1|NoC22Tc;$*GKilXo!6h{ZDSGH@|C NFxWCE0U?MD!T=M<3|RmG diff --git a/Regfiles/Sysprep/Hide_Gallery_from_Explorer.reg b/Regfiles/Sysprep/Hide_Gallery_from_Explorer.reg index c589de7370ddcf94f47d26a61488a97e24283e86..8e7c725d690ba839c67cb019b855f542aaab737a 100644 GIT binary patch literal 1622 zcmc(fZEw<06vzLsP5cf`UyB2yb839CFmwdwmTgLmn2piGh>jXs#u~G)KK-40DWzzP zniz9);oS55@IU=_*V9B(MM|_#szAqzHHMce(@Z&>7Sai?gm<8K$Y)3=yr;aM=%MPI z`?}}u3wZlTBlH5j)uE}6IB9N=$Av;?a}Bd1lZv9BifGfqsrY@?z+e&+BGxkEHQx_rV_ zP1TB8y3rSMvEEpYp3%j^y`>^lUT)dM~&#kIxcpR zne-f=mqb`VSNnMmCm~*m3d3E%j3*97hQ?~g17@5cGrSo-*R4}MfV03hBVOQiO7sM- z-&Ti@VJJ_j^uk4omN?v3hnVlFvP+FkaMp!B;J*nb+H}cK_b+g`S!th`5wo)`v1vra z^_x^|j^*L|TJ36q;U>};TidJ%+}m!>p$)YWeKHhBdd~FLPh+_OduW#3`(11QWw8C} zV4s7Mgp>UcbLXcq+vM}>?EIWU{Myc0Cv4V!5C8YBdGv?uO$=&%&EaZBo7gY4b2h+F oC1hH~%r5BL4VBqOg?vp61%>QS=2=XnoM5r(Mc4lR%iy#74hgjlQUCw| delta 296 zcmcb{bAWR~(8L*9lS>!{B%K*@7!nzZfiM+_V;Gznd>DcmJQ-Xj^RxQ1#xn3Sa7`9u zbDZqPqNE9AGgvbyFt{<~GZX>oM4;XrAYBU9T?8aSDxw*5Co3}dD!PD8%w{M7sxAPU z><3hz3ls|m@)8-68B#$u@PchX)@MvmA45EYF@qTpn=+UHp#_5_1tys=7%~_DO)&tP NXT)F*GKmf1CIIx6H01yQ diff --git a/Regfiles/Sysprep/Hide_Home_from_Explorer.reg b/Regfiles/Sysprep/Hide_Home_from_Explorer.reg new file mode 100644 index 0000000000000000000000000000000000000000..6da5cfdd9fb77c73d5da028232e7aa0b2c234396 GIT binary patch literal 1866 zcmdUvYikox5Qg8+g8w1xXKhmxdr|yQwy6zGZE2!GjHF36H>_F7J&1o@ede5;Y>gmQ z5Rqkf=bSTh=ACyg-@ev0)JTa^Ei_S1*XpXz-b7Q4wPL5l>5x^*I;S_Bk2xK(9VbQovv(&pjnJ|?-f5r@$SXB9!;kmYaQF4l zo9PzIhN`;MscNe07|bPhF1W7)wiK&WJ*V|!bPdJWk9oTIn{LI@;GP-#m%JS`-a9DgY)9WAh0jFa_F1#^F}=RH6w@=d^LdmZ$OPC7!%Gz#qW$juRU1$_a{uEP{7cxb{` zRWCu)BAUS_Q>P%kMb{!TtDgJLSx5Ke)*$DGKj)R|R!mnz+X`H8Nmq7hFQ4r*{= z6>Ak-g{79Oi<--zRrfBI)-fe`Y?8G)wR6osu$^~OZ_S)lw{^!cH(Pz&aOVII3*=B+ zH^?cTvfi-1%Teh=vSL2Bt1m}}?q=++^+b=bSYSKFQ_f{I>!F;hJd42lur8kvW7~O3 z*4=ofb9}xfz6#OBpsyfb@Q*=Vh9B#_ztN4`kv1H2a}fIeOz`XHNthpo!!sKA3_TpP z-z9rCSrYobMT|3K>)Zr}td|o#bCb-bnSb`y6@P+e#@l_Z{YsIIQyMUhFoO13w<5<`tv#9(R~NgjWLw~ literal 0 HcmV?d00001 diff --git a/Regfiles/Sysprep/Hide_Search_Taskbar.reg b/Regfiles/Sysprep/Hide_Search_Taskbar.reg index 9c12d311f63738186321f92df41b700bd3a549ad..94208f0faf4fd22efd092847b1f0979744fbfbc2 100644 GIT binary patch delta 237 zcmXYsISRr+7==Hy6HwP!&V1kpc=#-@ delta 88 zcmeyuypCx?4R1a}8bb*~IYS~t5ku-^TSoDT3-pA88B)Ol$qX3`u?)NnTntK+XESQ5 XC^6VFqyQD?0~Mz*STPu&L6AxSn&S}5 diff --git a/Regfiles/Sysprep/Show_Search_Box.reg b/Regfiles/Sysprep/Show_Search_Box.reg index 84499ee369d2d9ac4cecdf0daf655e62e2319016..c91b93795485396d295620f057591c5ef7bce297 100644 GIT binary patch delta 237 zcmXYsI|{-;7=%Bx6HSg9mUn$j`E~ z^Z1#47rw>k-SX%$VMZIDZuaOpJ{Lkfoq!!nEK1ZE3#T%!NjS679cQ2Nyhcl6Eb)LX za;vc!Fr>qjg=S2|UeTM0$Y;0_CoPYqB!AVgGqIuak-Q0u>{YFp_%06y9JRR46+8Pl b4FgjV>P(*%uF{@fZf-IinmO95o%z5Ic@!+M delta 88 zcmeyuypCx?4R1a}8bb*~IYS~t5ku-^TSoDT3-pA88B)Ol$qX3`u?)NnTntK+XESQ5 YC^6VFqyQD?0~Mz*STPu&KqIh90GjU*%>V!Z diff --git a/Regfiles/Sysprep/Show_Search_Icon.reg b/Regfiles/Sysprep/Show_Search_Icon.reg index 31f7f379e3de0156fc7d81c009627c815dc0ec21..60a3465d42be606629fd6d468749fbcbf6b7309f 100644 GIT binary patch delta 237 zcmXYsI|{-;7=%Bx6H+UpVo{>TSU8n&O~RRt?l}9D=QUaqV~GcB zkz0+;fFT{GEHq;x_KMz2L_WifIB9t-CHbp{orw*VkK|2QWUp$)#CLfx;HbrQuGrbf bX&9J_P-ptAaFzD-a&wdE(9F?Z?aT*$c?K-7 delta 88 zcmeyuypCx?4R1a}8bb*~IYS~t5ku-^TSoDT3-pA88B)Ol$qX3`u?)NnTntK+XESQ5 YC^6VFqyQD?0~Mz*STPu&Ktr%f0GjC#%m4rY diff --git a/Regfiles/Sysprep/Show_Search_Icon_And_Label.reg b/Regfiles/Sysprep/Show_Search_Icon_And_Label.reg index eccca00965539bf138442b012144df2a24234e97..d97d0770b3d0bcc9b9703181092d9d3b4f2b173a 100644 GIT binary patch delta 237 zcmXYsI|{-;7=%Bx6Hp487Md{;dqr<1BA?+#oU}ZalKfS}&cuewNAe~tvRAcY;=4Q;aMa>DSM2QL bGz?5ds55<5xJr9^xw*-7Xy$0IcIE>=c_J*b delta 88 zcmeyuypCx?4R1a}8bb*~IYS~t5ku-^TSoDT3-pA88B)Ol$qX3`u?)NnTntK+XESQ5 YC^6VFqyQD?0~Mz*STPu&Kx42<0Gjm>&Hw-a diff --git a/Regfiles/Undo/Show_Gallery_in_Explorer.reg b/Regfiles/Undo/Show_Gallery_in_Explorer.reg index 6363387f7ac76703da2c76c71f66f39b4d33ba3c..2b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T3n=M%eHTlsq6cg88 z4#U7Ww&zqEO^keT& d%qwHehci>aQ@QZ(WL&ckH#y+-FE`(+`vY$<@xA~6 literal 0 HcmV?d00001 diff --git a/Win11Debloat.ps1 b/Win11Debloat.ps1 index 769d4ca..b0c6da9 100644 --- a/Win11Debloat.ps1 +++ b/Win11Debloat.ps1 @@ -33,6 +33,7 @@ param ( [switch]$ClearStart, [switch]$ClearStartAllUsers, [switch]$RevertContextMenu, + [switch]$HideHome, [switch]$HideGallery, [switch]$DisableOnedrive, [switch]$HideOnedrive, [switch]$Disable3dObjects, [switch]$Hide3dObjects, @@ -927,8 +928,8 @@ if ((-not $global:Params.Count) -or $RunDefaults -or $RunWin11Defaults -or ($SPP if ($WinVersion -ge 22621){ Write-Output "" - if ($( Read-Host -Prompt "Disable Windows Copilot? This applies to all users (y/n)" ) -eq 'y') { - AddParameter 'DisableCopilot' 'Disable Windows Copilot' + if ($( Read-Host -Prompt "Disable and remove Windows Copilot? This applies to all users (y/n)" ) -eq 'y') { + AddParameter 'DisableCopilot' 'Disable and remove Windows Copilot' } Write-Output "" @@ -1029,8 +1030,14 @@ if ((-not $global:Params.Count) -or $RunDefaults -or $RunWin11Defaults -or ($SPP if ($WinVersion -ge 22000){ Write-Output "" - if ($( Read-Host -Prompt " Hide the gallery section from the File Explorer sidepanel? (y/n)" ) -eq 'y') { - AddParameter 'HideGallery' 'Hide the gallery section from the File Explorer sidepanel' + if ($( Read-Host -Prompt " Hide the Home section from the File Explorer sidepanel? (y/n)" ) -eq 'y') { + AddParameter 'HideHome' 'Hide the Home section from the File Explorer sidepanel' + } + + Write-Output "" + + if ($( Read-Host -Prompt " Hide the Gallery section from the File Explorer sidepanel? (y/n)" ) -eq 'y') { + AddParameter 'HideGallery' 'Hide the Gallery section from the File Explorer sidepanel' } } @@ -1047,8 +1054,8 @@ if ((-not $global:Params.Count) -or $RunDefaults -or $RunWin11Defaults -or ($SPP if ($( Read-Host -Prompt "Do you want to hide any folders from the File Explorer sidepanel? (y/n)" ) -eq 'y') { Write-Output "" - if ($( Read-Host -Prompt " Hide the onedrive folder from the File Explorer sidepanel? (y/n)" ) -eq 'y') { - AddParameter 'HideOnedrive' 'Hide the onedrive folder in the File Explorer sidepanel' + if ($( Read-Host -Prompt " Hide the OneDrive folder from the File Explorer sidepanel? (y/n)" ) -eq 'y') { + AddParameter 'HideOnedrive' 'Hide the OneDrive folder in the File Explorer sidepanel' } Write-Output "" @@ -1326,6 +1333,10 @@ else { RegImport "> Enabling file extensions for known file types..." "Show_Extensions_For_Known_File_Types.reg" continue } + 'HideHome' { + RegImport "> Hiding the home section from the File Explorer navigation pane..." "Hide_Home_from_Explorer.reg" + continue + } 'HideGallery' { RegImport "> Hiding the gallery section from the File Explorer navigation pane..." "Hide_Gallery_from_Explorer.reg" continue @@ -1335,7 +1346,7 @@ else { continue } {$_ -in "HideOnedrive", "DisableOnedrive"} { - RegImport "> Hiding the onedrive folder from the File Explorer navigation pane..." "Hide_Onedrive_Folder.reg" + RegImport "> Hiding the OneDrive folder from the File Explorer navigation pane..." "Hide_Onedrive_Folder.reg" continue } {$_ -in "Hide3dObjects", "Disable3dObjects"} {