It indeed works (the store is installed). But the batch fails to set correctly the permissions and ownership as intended
Final code for that will be Code: @REM [This code block detects if the script is running with ADMIN PRIVILEGES. If it isn't it pauses, and then quits.]echo OFF cls NET SESSION >nul 2>&1 IF %ERRORLEVEL% EQU 0 ( ECHO Administrator PRIVILEGES Detected! ) ELSE ( echo ######## ######## ######## ####### ######## echo ## ## ## ## ## ## ## ## ## echo ## ## ## ## ## ## ## ## ## echo ###### ######## ######## ## ## ######## echo ## ## ## ## ## ## ## ## ## echo ## ## ## ## ## ## ## ## ## echo ######## ## ## ## ## ####### ## ## echo. echo. echo ####### ERROR: ADMINISTRATOR PRIVILEGES REQUIRED ######### echo This script must be run as administrator to work properly! echo If you are seeing this right click on All_In_One.CMD and select "Run As Administrator." echo ########################################################## echo. PAUSE EXIT /B 1 ) @echo ON %~d0 cd %~d0%~p0 cls regedit.exe /S Files\regedit1.reg regedit.exe /S Files\regedit2.regS takeown /F "%SYSTEMDRIVE%\Program Files\WindowsApps" icacls "%SYSTEMDRIVE%\Program Files\WindowsApps" /grant "Everyone":F xcopy Files\store_depends_from_enterprise "%SYSTEMDRIVE%\Program Files\WindowsApps\" /e /i /h /y /k /o /x powershell "& "".\Files\StoreDependencies.ps1""" icacls "%SYSTEMDRIVE%\Program Files\WindowsApps" /grant "ALL APPLICATION PACKAGES":F icacls "%SYSTEMDRIVE%\Program Files\WindowsApps" /grant "Trusted Installer":F icacls "%SYSTEMDRIVE%\Program Files\WindowsApps" /grant "System":F pause
%ProgramFiles%\WindowsApps Is more correct/elegant. You can have your windows in C:\ and have the \program files directory elsewhere. Not a so common scenario but in such case %SYSTEMDRIVE%\Program Files\ wold be wrong
Coding for Windows vs Linux. Q: Is this trailing slash required or a problem? Code: xcopy Files\store_depends_from_enterprise "%SYSTEMDRIVE%\Program Files\WindowsApps\" /e /i /h /y /k /o /x vs Code: xcopy Files\store_depends_from_enterprise "%SYSTEMDRIVE%\Program Files\WindowsApps" /e /i /h /y /k /o /x The ending of WindowsApp with or without \ Just want to be sure.
One more code change IMPORTANT!!! CHANGE icacls "%PROGRAMFILES%\WindowsApps" /grant "Trusted Installer":F TO icacls "%PROGRAMFILES%\WindowsApps" /grant "NT Service\TrustedInstaller":F
Alright, new code, before I re-upload this. For review Code: @REM [This code block detects if the script is running with ADMIN PRIVILEGES. If it isn't it pauses, and then quits.]echo OFF cls NET SESSION >nul 2>&1 IF %ERRORLEVEL% EQU 0 ( ECHO Administrator PRIVILEGES Detected! ) ELSE ( echo ######## ######## ######## ####### ######## echo ## ## ## ## ## ## ## ## ## echo ## ## ## ## ## ## ## ## ## echo ###### ######## ######## ## ## ######## echo ## ## ## ## ## ## ## ## ## echo ## ## ## ## ## ## ## ## ## echo ######## ## ## ## ## ####### ## ## echo. echo. echo ####### ERROR: ADMINISTRATOR PRIVILEGES REQUIRED ######### echo This script must be run as administrator to work properly! echo If you are seeing this right click on All_In_One.CMD and select "Run As Administrator." echo ########################################################## echo. PAUSE EXIT /B 1 ) @echo ON %~d0 cd %~d0%~p0 cls regedit.exe /S Files\regedit1.reg regedit.exe /S Files\regedit2.regS takeown /F "%ProgramFiles%\WindowsApps" icacls "%ProgramFiles%\WindowsApps" /grant "Everyone":F xcopy Files\store_depends_from_enterprise "%ProgramFiles%\WindowsApps\" /e /i /h /y /k /o /x powershell "& "".\Files\StoreDependencies.ps1""" icacls "%ProgramFiles%\WindowsApps" /grant "ALL APPLICATION PACKAGES":F icacls "%ProgramFiles%\WindowsApps" /grant "NT SERVICE\TrustedInstaller":F icacls "%ProgramFiles%\WindowsApps" /grant "System":F pause
Is possible this do work with pack .appxbundle installation with script from MultiLang_App_Update_X21-12056.ISO files ?
Read the thread fully. Full inu mentioned it first and lucidus has already confirmed that this method works too (and IMO is far simpler than copying folders and setting permissions).
NO. Completely different project (and I suspect more work too). The goal was to have a minimal install copy of Windows 10 without having to hack away (remove) all the junk found in Windows 10. But to be able to add your own via the store. I only included Xbox as an option because, upon further reflection, it too may be needed (games via store). But I also kept it only as an option because I knew some folks may not require it. Spoiler Interesting point.... Edge is not located in Programs Files\WindowsApps But if you feel strongly about it, I encourage you to start your own project in your own thread.
I'm afraid is not that easy. First problem, well known to WMC users, is that the MS genius translated some account names "network service" is "servizio di rete" in italian, and it changes for most of the languages The same applies to ALL APPLICATION PACKAGES, so that line fails everywhere except english windows.
As these are packages from an English distro, would that not hold true regardless? And if not, what method can be applied to correct it?
Not sure, but if you use the appx and appxbundle files from that multi-lang ISO Full inu and lucidus mentioned, will they not have all the language versions inside? Also, any reason you aren't using those anyway? It would certainly make the process much simpler as far as I can tell, with no fiddling with permissions required.
What count is how actually the user(s) is/are called on the windows you're using. "Trusted Installer" isn't translated, some other names are. There are a number of workarounds involving the use of the SID instead of the username, none of them are straightforward anyway. As I said the best way is to use nsudo and not mess with the permissions at all, see the WMC code.
Assume I'm a Linux user and Windows is this weird thing that I occasionally play with or end up fixing when other folks break it. Which means I'm not 100% sure what you're talking about. Also, I'm pretty sure the ISO I'm playing with isn't multi-lang. Regardless, this whole point of this project is so that other folks don't need to play with another ISO. But if you're thinking of another way in which I can improve upon all of this and make it easier for folks, please, do explain.