35 Commits
v0.9 ... master

Author SHA1 Message Date
  Styris 8fb460ba4f Update 'README.md' 3 months ago
  Styris bc8cec4dab Update 'README.md' 3 months ago
  Styris 8b04e77b8f Update 'README.md' 3 months ago
  Styris d5778d8e47 Update 'README.md' 3 months ago
  Styris 8688290afd Update README 5 months ago
  Styris 6ed9ff89f6 Update README 5 months ago
  Styris 09cece9a2b Release v1.4 5 months ago
  Joe 1d8824361f Remove Usage note from README 6 months ago
  Joe fe6a69b0b9 Release v1.3 6 months ago
  Joe 261ffbfe3b Release v1.3 6 months ago
  Joe 132207db69 Update README 7 months ago
  Joe c77ddc8b92 Update README 8 months ago
  Joe e9826f2421 Update README 8 months ago
  Joe 7e25b9492e Update to v1.2 8 months ago
  Joe 8975759622 Update 'screenshot.png' 9 months ago
  Joe 2d94f7cc70 Update to v1.1 9 months ago
  Joe fae04020d1 Update to v1.0 10 months ago
  Joe 55b6c53585 Updated README title 10 months ago
  Joe 56c8d3b937 Added NVIDIA-Control-Panel item to links.txt 1 year ago
  Joe 6d14ed1d99 Removed prev links file 1 year ago
  Joe 11584899da Updated links.txt 1 year ago
  Joe 99b50ac64d Updated links.txt 1 year ago
  Joe 5680324da9 Updated links.txt 1 year ago
  Joe e0bec3c875 Updated links.txt 1 year ago
  Joe 05dee84a0d Updated links.txt 1 year ago
  Joe a7677b5d06 Updated links.txt file 1 year ago
  Joe 0a10369d11 Updated links.txt file 1 year ago
  Joe be32e645a2 Updated wsldistrolinks.txt 1 year ago
  Joe f6aef36456 Updated wsldistrolinks.txt 1 year ago
  Joe c7f57c9a2f Added wsl links file for testing purposes 1 year ago
  Joe 6ea6ce22bb Output and spacing improvements. Functional improvements. Bug fixes 1 year ago
  Joe 4fb29f5ae4 Bug fixes and improvements 1 year ago
  Joe adbd3edff9 Changed script version 1 year ago
  Joe b978930cb1 Added profile image function. Added hibernation function. Added beta new user function. Bug fixes and improvements 1 year ago
  Joe 844f0eefc2 Update 'README.md' 1 year ago
5 changed files with 4134 additions and 1140 deletions
Split View
  1. +0
    -1115
      CentralAMEScript.cmd
  2. +157
    -25
      README.md
  3. +3948
    -0
      amecs.cmd
  4. +29
    -0
      links.txt
  5. BIN
      screenshot.png

+ 0
- 1115
CentralAMEScript.cmd
File diff suppressed because it is too large
View File


+ 157
- 25
README.md View File

@ -1,22 +1,28 @@
# Central AME Script
# Central AME Script (amecs)
Script for automating a large assortment of AME related actions.
![Central-AME-Script Screenshot](screenshot.png)
![Central AME Script Screenshot](screenshot.png)
## Usage
You can download the script by going to the [latest release](https://git.ameliorated.info/Joe/Central-AME-Script/releases/latest) and downloading `Central-AME-Script.cmd` from the Downloads section.
You can download the script by going to the [latest release](https://git.ameliorated.info/Styris/amecs/releases/latest) and selecting `amecs.zip` from the **Downloads** section. Once downloaded, simply extract `amecs.zip` and run `amecs.cmd`.
Alternatively, you could clone the repository:
git clone https://git.ameliorated.info/Joe/Central-AME-Script.git
git clone https://git.ameliorated.info/Styris/amecs.git
Once downloaded, you can simply run the script.
Once cloned, simply run `amecs.cmd`.
## Summary
As part of the amelioration process, certain UI elements, such as the **Region and language** page in Windows Settings, have been removed, and require alternative ways to execute the tasks. This script fills in those gaps, and allows for automating a large variety of customization tasks.
If you prefer manually executing commands for some of these tasks without a script, you can go through the step-by-step guides on [AME Guides](https://t.me/AMEGuides).
## Primary Functions
There are many actions in AME that require commands, the following functions essentially work as an interactive user interface for those.
There are a variety of tasks you can easily perform with amecs. Below, we provide an explanation for each of them, as well as the commands underlying the features.
#### Username/Password
@ -24,36 +30,50 @@ This function allows for changing the user's username or password.
At its core, the following command is used for changing the username:
wmic useraccount where "name='<currentUsername>'" rename '<newUsername>'
wmic useraccount where "name='<User's Username>'" rename '<New Username>'
Similarly, the following command is used for changing the password:
net user "<currentUsername>" "<newPassword>"
net user "<User's Username>" "<New Password>"
#### Lockscreen Image
This function allows for changing the lockscreen image. This is a modified version of [LoganDark's lockscreen-img script](https://git.ameliorated.info/LoganDark/lockscreen-img).
This function allows for changing the lockscreen image.
It works by taking ownership of the existing profile image files, and replacing them with the new image supplied by the user.
This is a modified version of [LoganDark's lockscreen-img script](https://git.ameliorated.info/LoganDark/lockscreen-img).
It works by taking ownership of the existing lockscreen image files, and replacing them with the new image supplied by the user.
#### Profile Image
This function allows for changing the user's profile image (PFP).
It does this by taking ownership of the existing profile image files, and replacing them with the new image supplied by the user. Several necessary registry changes are made as well.
This is a modified version of [LoganDark's profile-img script](https://git.ameliorated.info/LoganDark/profile-img).
#### User Elevation
This function allows for elevating the user to administrator. Elevating the user disables the password requirement when trying to run an executable as administrator. However, this has large security implications, thus why it is not the default setting.
This function allows for elevating or de-elevating the user to or from administrator. Elevating the user disables the password requirement when trying to run an executable as administrator. However, this has large security implications, thus why it is not the default setting.
At its core, it uses the following command:
net localgroup administrators "<currentUsername>" /add
net localgroup administrators "<User's Username>" /add
Or the following for de-elevating the user:
net localgroup administrators "<User's Username>" /delete
#### Display Language
This function allows for changing the user's display language.
Firstly, it prompts the user to download a portion of a ~5.5GB language pack ISO file. Unfortunately, Microsoft no longer publicly distributes individual language pack files, so this is necessary.
Firstly, it prompts the user to download a portion of a \~5.5GB language pack ISO file. Unfortunately, Microsoft no longer publicly distributes individual language pack files, so this is necessary.
Once the ISO is downloaded, it extracts the ISO file, and installs the language pack for the selected display language using the following commands:
7z e -y -o"<Script Path>\LangPacks" "<Script Path>\LangPacks.ISO" x64\langpacks\*.cab
lpksetup /i <Language/region ID> /p "<Script Path>\LangPacks\Microsoft-Windows-Client-Language-Pack_x64_<Language/region ID>.cab"
7z e -y -o"<Script Path>\LangPacks" "<User's Desktop>\LangPacks.ISO" x64\langpacks\*.cab
lpksetup /i <Language/region ID> /p "<User's Desktop>\LangPacks\Microsoft-Windows-Client-Language-Pack_x64_<Language/region ID>.cab"
After the language pack is installed, the display language can finally be set. At its core, this is done by using the following commands:
@ -66,17 +86,19 @@ The script heavily enchances these simple commands. For instance, it keeps the e
#### Keyboard Language
This function allows for adding a keyboard language.
These functions allow for adding or removing a keyboard language.
At its core, this is done by using the following command:
PowerShell -NoP -C "$NewLangs=Get-WinUserLanguageList; $NewLangs[0].InputMethodTips.Add('<Language/region ID>:<Keyboard identifier>'); Set-WinUserLanguageList $NewLangs -Force"
PowerShell -NoP -C "$NewLangs=Get-WinUserLanguageList; $NewLangs[0].InputMethodTips.Add('<Language/region ID>:<Keyboard Identifier>'); Set-WinUserLanguageList $NewLangs -Force"
If the user chose to make their selection the new default input method, the following command will also be run:
PowerShell -NoP -C "Set-WinDefaultInputMethodOverride -InputTip "<Language/region ID>:<Keyboard identifier>""
PowerShell -NoP -C "Set-WinDefaultInputMethodOverride -InputTip "<Language/region ID>:<Keyboard Identifier>""
The Language/region ID and Keyboard identifier for a given language can be found [here](https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/available-language-packs-for-windows?view=windows-11#language-packs) and [here](https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/windows-language-pack-default-values?view=windows-11) respectively.
The Language/region ID and Keyboard identifier for a given language can be found [here](https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/available-language-packs-for-windows?view=windows-11#language-packs) amd [here](https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/windows-language-pack-default-values?view=windows-11) respecively.
To remove a keyboard language, it fetches the existing language list, filters out the selected language, and sets the modified language list.
#### Username Login Requirement
@ -90,25 +112,117 @@ Or the following for enabling the requirement:
reg add "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System" /v dontdisplaylastusername /t REG_DWORD /d 1 /f
#### AutoLogon
This function allows for enabling or disabling the automatic login of the current user.
It does this by extracting an `AutoLogon.exe` file embedded within the script, and subsequently using it to enable AutoLogon.
The mentioned `AutoLogon.exe` program is a modified version of [rzander's AutoLogon program](https://github.com/rzander/AutoLogon).
## Extra Functions
Currently this section only contains legacy functions, these are only useful for versions of AME predating the [REDACTED].
This section contains beta, legacy, or less used functions. Legacy functions are only useful for versions of AME predating the [REDACTED].
#### Windows Subsystem for Linux (WSL)
These functions allow for various WSL related actions.
##### Enable/Disable WSL
This function allows for enabling or disabling WSL functionality.
At its core, this is done by using the following command:
DISM /Online /Enable-Feature /FeatureName:Microsoft-Windows-Subsystem-Linux -NoRestart
Or the following for disabling the requirement:
DISM /Online /Disable-Feature /FeatureName:Microsoft-Windows-Subsystem-Linux -NoRestart
##### Install WSL Distro
This function allows for installing a WSL distribution.
Firstly, it fetches the distro download link from this git repository (`links.txt`), and downloads the distro from said link\*. Once the distro is downloaded, the script extracts and places the distro in `<User's Local AppData Folder>\AME-WSL`, and subsequently installs the distro by running the distro's `.exe` file contained within.
After the distro has been installed, the script sends several commands to the distro that apply the username and password(s) supplied by the user.
\*If the distro link includes apps.microsoft.com, [store.rg-adguard.net](https://store.rg-adguard.net/) is used to fetch the download link.
##### Remove WSL Distro
This function allows for removing a WSL distribution.
At its core, it does this by unregistering the distro using the following command:
WSL --unregister <WSL Distro>
And subsequently removing the distro's installation files located in `<User's Local AppData Folder>\AME-WSL`.
#### Hibernation
#### Windows Script Host
This function allows for enabling or disabling the hibernation option in Windows.
At its core, the following commands are used:
powercfg /HIBERNATE /TYPE FULL
Or the following for disabling hibernation:
powercfg /HIBERNATE OFF
#### Notification Center
This function allows for enabling or disabling the Notification Center in the bottom right of the taskbar.
At its core, it uses the following command:
reg add "HKU\<User's SID>\Software\Policies\Microsoft\Windows\Explorer" /v DisableNotificationCenter /t REG_DWORD /d 0 /f
Or the following for disabling the Notification Center:
reg add "HKU\<User's SID>\Software\Policies\Microsoft\Windows\Explorer" /v DisableNotificationCenter /t REG_DWORD /d 1 /f
#### Desktop Notifications
This function allows for enabling or disabling desktop toast notifications.
At its core, it uses the following command:
reg add "HKU\<User's SID>\SOFTWARE\Microsoft\Windows\CurrentVersion\PushNotifications" /v ToastEnabled /t REG_DWORD /d 1 /f
Or the following for disabling desktop notifications:
reg add "HKU\<User's SID>\SOFTWARE\Microsoft\Windows\CurrentVersion\PushNotifications" /v ToastEnabled /t REG_DWORD /d 0 /f
#### Windows Script Host (Legacy)
This function allows for enabling or disabling Windows Script Host (WSH). WSH is necessary for some programs.
At its core, the following commands are used:
reg add "HKEY_USERS\<userSID>\SOFTWARE\Microsoft\Windows Script Host\Settings" /v Enabled /t REG_DWORD /d 1 /f
reg add "HKU\<User's SID>\SOFTWARE\Microsoft\Windows Script Host\Settings" /v Enabled /t REG_DWORD /d 1 /f
reg add "HKLM\SOFTWARE\Microsoft\Windows Script Host\Settings" /v Enabled /t REG_DWORD /d 1 /f
Or the following for disabling WSH:
reg add "HKEY_USERS\<userSID>\SOFTWARE\Microsoft\Windows Script Host\Settings" /v Enabled /t REG_DWORD /d 0 /f
reg add "HKU\<User's SID>\SOFTWARE\Microsoft\Windows Script Host\Settings" /v Enabled /t REG_DWORD /d 0 /f
reg add "HKLM\SOFTWARE\Microsoft\Windows Script Host\Settings" /v Enabled /t REG_DWORD /d 0 /f
#### NCSI Active Probing
#### Visual Basic Script (Legacy)
This function allows for enabling or disabling Visual Basic Script (VBS). VBS is necessary for some programs.
At its core, the following command is used:
assoc .vbs=VBSFile
Or the following for disabling VBS:
assoc .vbs=
#### NCSI Active Probing (Legacy)
This function allows for enabling or disabling NCSI Active Probing. Some applications require this to be enabled.
@ -120,6 +234,24 @@ Or the following for disabling NCSI Active Probing:
reg add "HKLM\SYSTEM\CurrentControlSet\Services\NlaSvc\Parameters\Internet" /v EnableActiveProbing /t REG_DWORD /d 0 /f
#### New User (Beta)
This function allows for creating partially functional and pre-configured users in Windows AME.
To do this, it uses a standard user creation command, followed by many registry edits to make the new user usable.
#### NVIDIA Control Panel
This function allows for installing or uninstalling NVIDIA Control Panel. This is useful since NVIDIA Control Panel no longer properly installs during a driver installation* due to it using an APPX deployment (Not supported in AME).
Firstly, it fetches the store link from this git repository (`links.txt`), and fetches the download link from [store.rg-adguard.net](https://store.rg-adguard.net/). Afterwards, it downloads NVIDIA Control Panel from said link\*. Once NVIDIA Control Panel is downloaded, the script extracts and places it in `<System Drive>\Program Files\NVIDIA Control Panel`, and subsequently creates a start menu shortcut for it.
For removal, it simply removes the `<System Drive>\Program Files\NVIDIA Control Panel` directory, as well as the start menu shortcut.
Note: Even though NVIDIA Control Panel installation failes during a driver installation, it still creates the necessary NVIDIA Control Panel files in `<System Drive>\Program Files\WindowsApps`. If this is the case, the script will attempt to use those files instead of downloading them.
\*Standard drivers do not have this issue, however those have been discontinued by NVIDIA.
## Known Issues
Some keyboard languages may not work, and a few are improperly tagged. This will be fixed in a future release.
Some keyboard languages may not work, and a few are improperly tagged.

+ 3948
- 0
amecs.cmd
File diff suppressed because it is too large
View File


+ 29
- 0
links.txt View File

@ -0,0 +1,29 @@
[WSL DISTROS]
Ubuntu = |https://aka.ms/wslubuntu2004| -S |894.52 MB| -Alt |https://apps.microsoft.com/store/detail/ubuntu-2004/9N6SVWS3RX71| -AltF |Ubuntu20\.04.*_neutral_.*\.appxbundle| -AltDistro |Ubuntu-20.04|
Ubuntu-18.04 = |https://aka.ms/wsl-ubuntu-1804| -S |221.09 MB| -Alt |https://apps.microsoft.com/store/detail/ubuntu-1804-lts/9N9TNGVNDL3Q| -AltF |Ubuntu18\.04.*_neutral_.*\.appxbundle| -AltDistro |Ubuntu-18.04|
Ubuntu-16.04 = |https://aka.ms/wsl-ubuntu-1604| -S |199.08 MB|
Debian = |https://aka.ms/wsl-debian-gnulinux| -S |167.07 MB| -Alt |https://apps.microsoft.com/store/detail/9MSVKQC78PK6| -AltF |DebianGNULinux.*_neutral_.*76v4g.*\.appxbundle| -AltDistro |Debian|
kali-linux = |https://aka.ms/wsl-kali-linux-new| -S |189.1 MB| -Alt |https://apps.microsoft.com/store/detail/kali-linux/9PKR34TNCV07| -AltF |KaliLinux.*_neutral_.*ey8k8.*\.appxbundle| -AltDistro |kali-linux|
fedoraremix = |https://github.com/WhitewaterFoundry/Fedora-Remix-for-WSL/releases/download/35.12.3/Fedora-Remix-for-WSL-SL_35.12.3.0_x64_arm64.msixbundle| -S |640.22 MB| -Alt |https://apps.microsoft.com/store/detail/9N6GDM4K2HNC| -AltF |WhitewaterFoundryLtd.*FedoraRemixforWSL.*_neutral_.*\.msixbundle| -AltDistro |fedoraremix|
WLinux = |https://apps.microsoft.com/store/detail/pengwin/9NV1GV1PXZ6P| -F |WhitewaterFoundryLtd.*1657.*_neutral_.*\.msixbundle|
WLE = |https://apps.microsoft.com/store/detail/pengwin-enterprise-7/9N8LP0X93VCP| -F |WhitewaterFoundryLtd.*WLinuxEnterprise.*_neutral_.*\.appxbundle|
Alpine = |https://apps.microsoft.com/store/detail/alpine-wsl/9P804CRF0395| -F |AlpineWSL.*_neutral_.*my43b.*\.appxbundle|
openSUSE-42 = |https://aka.ms/wsl-opensuse-42| -S |199.3 MB|
openSUSE-Tumbleweed = |https://aka.ms/wsl-opensuse-tumbleweed| -S |183.03 MB|
openSUSE-Leap-15-1 = |https://apps.microsoft.com/store/detail/opensuseleap151/9NJFZK00FGKV| -F |openSUSE-Leap-15-1.*_x64_.*022rs.*\.appx|
openSUSE-Leap-15.2 = |https://aka.ms/wsl-opensuseleap15-2| -S |141.11 MB|
openSUSE-Leap-15.3 = |https://aka.ms/wsl-opensuseleap15-3| -S |174.81 MB|
OracleLinux_7_9 = |https://aka.ms/wsl-oraclelinux-7-9| -S |125.47 MB|
OracleLinux_8_5 = |https://aka.ms/wsl-oraclelinux-8-5| -S |109.42 MB|
SLES-12 = |https://aka.ms/wsl-sles-12| -S |198.61 MB|
SUSE-Linux-Enterprise-Server-12-SP5 = |https://apps.microsoft.com/store/detail/suse-linux-enterprise-server-12-sp5/9MZ3D1TRP8T1| -F |SUSELinux.*_x64_.*022rs.*\.appx|
SLES-15-SP1 = |https://apps.microsoft.com/store/detail/suse-linux-enterprise-server-15-sp1/9PN498VPMF3Z| -F |SUSELinux.*_x64_.*022rs.*\.appx|
SUSE-Linux-Enterprise-Server-15-SP2 = |https://aka.ms/wsl-SUSELinuxEnterpriseServer15SP2| -S |159.16 MB|
SUSE-Linux-Enterprise-Server-15-SP3 = |https://aka.ms/wsl-SUSELinuxEnterpriseServer15SP3| -S |194.2 MB|
[DRIVER GUIS]
NVIDIA-Control-Panel = |https://apps.microsoft.com/store/detail/nvidia-control-panel/9NF8H0H7WMLT| -F |NVIDIACorp.*_x64_.*56jyb.*\.appx|

BIN
screenshot.png View File

Before After
Width: 732  |  Height: 522  |  Size: 28 KiB Width: 732  |  Height: 590  |  Size: 30 KiB

Loading…
Cancel
Save