There are several settings I used to do with each new install, does there is any way to automate it

Discussion in 'Windows 10' started by jineso, Mar 23, 2024.

  1. jineso

    jineso MDL Member

    Oct 8, 2021
    199
    42
    10
    Hi,
    I am using Windows LTSC IoT.
    I am installing it using the WinNT tool.
    With each install, I do several tweaks to my preferences:
    1. set UAC to the highest level.
    2. set Windows Backup, Windows Update, and Windows Time services to automatically.
    3. Adjust many settings of the personalized theme like dark colors, items in the taskbar, items in the start menu ...etc.
    4. folder option settings ...etc
    5. some control panel settings.
    6. etc...
    So does there is any way to automate it?
    I would like to have something like a .reg file (or anything like that) that contains all settings I would like to add it to Winnt during installation or after post install.
    And if it is working in that way, how do we figure out the registry key or settings to be added for that particular setting? so I can export it and then save everything in one big registry file?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. tapangbedaru

    tapangbedaru MDL Junior Member

    Mar 6, 2022
    63
    30
    0
    I have an idea to make a simple .bat like this, which you can continue as you wish

    Code:
    @Echo Off
    Title Up to you & Color 0B
    cd %systemroot%\system32
    call :IsAdmin
    
    REM ; Darkmode
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "AppsUseLightTheme" /t REG_DWORD /d "0" /f
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "SystemUsesLightTheme" /t REG_DWORD /d "0" /f
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "ColorPrevalence" /t REG_DWORD /d "0" /f
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "EnableTransparency" /t REG_DWORD /d "1" /f
    Reg.exe add "HKCU\Control Panel\Desktop" /v "WallPaper" /t REG_SZ /d "C:\Windows\web\wallpaper\Windows\img19.jpg" /f
    Reg.exe add "HKCU\Software\Microsoft\Windows\CurrentVersion\Themes" /v "CurrentTheme" /t REG_SZ /d "C:\Windows\resources\Themes\dark.theme" /f
    Reg.exe add "HKCU\Software\Microsoft\Windows\CurrentVersion\Themes\HighContrast" /v "Pre-High Contrast Scheme" /t REG_SZ /d "C:\Windows\resources\Themes\dark.theme" /f
    Pause & Exit
    
    :IsAdmin
    Reg.exe query "HKU\S-1-5-19\Environment"
    If Not %ERRORLEVEL% EQU 0 (
     Cls & Echo You must have administrator rights to continue ...
     Pause & Exit
    )
    Cls
    goto:eof
     
  3. jineso

    jineso MDL Member

    Oct 8, 2021
    199
    42
    10
    Do you mean to goggle each setting I want to adjust and add its registry setting the way you showed in your post.
    Does there is any part in your example that is fixed? not to be changed?
    Does there is a guide for the registry to follow?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. raptorddd

    raptorddd MDL Addicted

    Aug 17, 2019
    615
    203
    30
    yes you can.. youll need uploaded files.
    example i use win optimizer i run program then you need to find out if program is x86 or x64.
    run as admin regfromapp and look for program there (winoptimizer) if its not listed then use the x64 if found select it. make changes to tweaks you want once you finish all tweaks youll see all the registry codes there in redfromapp. copy them then run Regcon and covert it that code will be the same as below.

    REM ; Darkmode
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "AppsUseLightTheme" /t REG_DWORD /d "0" /f
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "SystemUsesLightTheme" /t REG_DWORD /d "0" /f
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "ColorPrevalence" /t REG_DWORD /d "0" /f
    Reg.exe add "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize" /v "EnableTransparency" /t REG_DWORD /d "1" /f
    Reg.exe add "HKCU\Control Panel\Desktop" /v "WallPaper" /t REG_SZ /d "C:\Windows\web\wallpaper\Windows\img19.jpg" /f
    Reg.exe add "HKCU\Software\Microsoft\Windows\CurrentVersion\Themes" /v "CurrentTheme" /t REG_SZ /d "C:\Windows\resources\Themes\dark.theme" /f
    Reg.exe add "HKCU\Software\Microsoft\Windows\CurrentVersion\Themes\HighContrast" /v "Pre-High Contrast Scheme" /t REG_SZ /d "C:\Windows\resources\Themes\dark.theme" /f


    Pause & Exit

    do the same for settings.
     

    Attached Files:

  5. haris_mdlf69

    haris_mdlf69 MDL Senior Member

    Oct 23, 2018
    422
    660
    10
    Hey @raptorddd!

    I'm interested to know how this 'regfromapp' program works?

    Best Regards
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. Tito

    Tito Super Mod / Adviser
    Staff Member

    Nov 30, 2009
    18,680
    18,584
    340
  7. acer-5100

    acer-5100 MDL Guru

    Dec 8, 2018
    3,692
    2,658
    120
    WinNTsetup has (obviously) the option to import user tweaks.

    No need to use external batch files or whatever.