Sunday, August 3, 2025

JSON Editing and Notepad++

Inserting Lines Below the Selection
1. Select a line or lines
2. Ctrl + D
3. The lines will be inserted below the selection. If lines already exist, the duplicated lines will be inserted.

Edit a Block
Alt + Click Drag will select a block of text. (Trackpad will need double tap)
Typing will now change the entire block

Moving a Block or Group of Lines
Crtl + Shift + up/down arrow moves selected lines

Wednesday, July 30, 2025

User Profile Backup

 I have a PC with a second standard user. The data size should remain small. Various users will have access, and corruption may occur. I'm looking for a way to back up and restore the user profile.

Here are the scripts to try.
Change the hard drive letters and user name to fit the situation.

Backup
@echo off
:: CONFIGURATION SECTION
set "SourceProfile=C:\Users\JohnDoe"
set "BackupLocation=C:\Backups\JohnDoe_Backup"
set "LogFile=C:\Backups\Logs\BackupLog_%DATE:/=-%_%TIME::=-%.txt"

:: Create backup folder if it doesn't exist
if not exist "%BackupLocation%" (
    echo Creating backup directory: %BackupLocation%
    mkdir "%BackupLocation%"
)

if not exist "%~dp0Logs" (
    mkdir "%~dp0Logs"
)

echo Starting backup from %SourceProfile% to %BackupLocation%
echo Logging to %LogFile%

:: Perform the backup using Robocopy
robocopy "%SourceProfile%" "%BackupLocation%" /MIR /XJ /Z /R:2 /W:2 /COPYALL /DCOPY:T /NFL /NDL /NP /LOG+:"%LogFile%"

echo Backup completed.
pause


Restore
@echo off
:: CONFIGURATION SECTION
set "BackupSource=C:\Backups\JohnDoe_Backup"
set "TargetProfile=C:\Users\JohnDoe"
set "LogFile=C:\Backups\Logs\RestoreLog_%DATE:/=-%_%TIME::=-%.txt"

:: Confirm operation
echo --------------------------------------------------
echo You are about to restore a user profile:
echo FROM: %BackupSource%
echo TO:   %TargetProfile%
echo --------------------------------------------------
pause

:: Create target directory if it doesn't exist
if not exist "%TargetProfile%" (
    echo Creating target directory: %TargetProfile%
    mkdir "%TargetProfile%"
)

if not exist "%~dp0Logs" (
    mkdir "%~dp0Logs"
)

:: Use Robocopy to restore backup
robocopy "%BackupSource%" "%TargetProfile%" /MIR /XJ /Z /R:2 /W:2 /COPYALL /DCOPY:T /NFL /NDL /NP /LOG+:"%LogFile%"

echo Restore complete.
pause

If something doesn't work check the path to the profile in registry.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList


Friday, July 18, 2025

Calibre How To Add Audio Voices

 

Quick Guide to Installing Piper TTS with Python

Want to add text-to-speech to your projects? Here's how to set up Piper TTS with Python in a few simple steps:

You don't need to do 1 & 2. Go directly to #3 in Calibre. (AI sources told me I needed it)

  1. Install the Latest Python
    Ensure you have the latest version of Python installed on your system.

  2. Install Piper TTS
    Open your command prompt and run:

    pip install piper-tts
    
  3. Manage Voices

    • Right-click or press Ctrl + S on an open book to launch the audio interface.
    • Click the cog wheel in the upper right to access text-to-speech settings.
    • Select The Piper Neural Engine from the dropdown menu.
    • Expand the English option to view a list of available voices.
    • To download a voice, click the Download button (the lower left tab will switch from Delete to Download).

Be advised: Calibre already has one default voice installed. This is only if you want more.

This is the settings section. The highlighted voice is the currently active voice. If you select a voice that is not downloaded a download option will appear.


 

Monday, July 14, 2025

AI Help and Blogger Posting

Making HTML Editing Easier in Blogger: A Simple Solution

Blogger is great for quick posting. However, if you ever need to edit the HTML when Blogger has done something that requires alteration, it's a real hassle to find anything. Everything is in one long continuous string.

The Simple Solution

A simple solution is to ask Grok to convert the plain text of the post into HTML. Grok does not change the phrasing or add personality to the post unless you request it. It formats the original text into HTML traditionally, not in one continuous stream.

Now you can edit the HTML more easily and find what you are looking for.

Different AI Tools, Different Approaches

Claude will default to adding personality, attitude, and rearranging everything. This is fun if that is what you are seeking. I love interacting with Claude.

A Real-World Example

For the Gimp post below, I asked Claude to create a blog post. I downloaded as an HTML file, opened in Brave, viewed source, copied and pasted it into Blogger's HTML edit section. It didn't show on the Compose section. I told Claude what happened and he fixed it.

Claude told what was done. When I try again, I will add this to Claude's instructions:

"I am using Blogger so keep the HTML simple and use inline styles instead of CSS blocks. Do not included the full HTML document structure with <!DOCTYPE html>, <html>, <head>, and <body> tags. Blogger's HTML editor expects only the content that goes inside the post body, not a complete HTML document." Please create a Blogger post from the following text. ""
ChatGPT suggested this prompt to create a post for Blogger.

Convert the following content into a Blogger-compatible HTML post.

Please avoid full HTML structure like <html>, <head>, and <body>. Only output content suitable for pasting directly into the Blogger editor in HTML mode.

Use only simple inline styling if needed (no <style> or <script> tags), and stick to basic tags like <h1><h6>, <p>, <a>, <img>, <ul>/<ol>, <blockquote>, and <div>.

Format the content clearly with subheadings and paragraph spacing, and include line breaks where appropriate.

Key Takeaway

The key is choosing the right tool for your needs and providing clear instructions about your platform's requirements. Whether you want straightforward formatting or creative enhancement, there's an AI assistant that can help make your blogging workflow smoother.

Tuesday, July 8, 2025

Make Your Own Ninite Installer

Ha, Ok - not quite. You have to download the installers first.
I could add curl, extract and delete requests but it's too much work for something I don't intend using.
I asked Claude-3.5 to create a batch (cmd) to silently install all the files residing in the same folder as the cmd.

After several revisions when Claude's script failed, we hit a home run. Working with Claude on script development is outstanding. I can't think of enough things to try.

This will install 7zip, Notepad++, and Winaero in a flash with no input. I didn't believe it worked until I checked.

Yes, I used Windows Sandbox (my favorite scripting playground)

Easier methods to install Windows programs exist today, and I will never use this method. But it was fun.

I would simplify the installer names like "notpad++.exe".

@echo off
setlocal enabledelayedexpansion

echo Starting silent installation of programs...
echo.

set "SOURCE_DIR=%~dp0"

:: 7-Zip
echo Installing 7-Zip...
"%SOURCE_DIR%7z2500-x64.exe" /S
if errorlevel 1 (
    echo Error installing 7-Zip
) else (
    echo 7-Zip installation complete.
)
echo.

:: Notepad++
echo Installing Notepad++...
"%SOURCE_DIR%npp.8.8.2.Installer.x64.exe" /S
if errorlevel 1 (
    echo Error installing Notepad++
) else (
    echo Notepad++ installation complete.
)
echo.

:: Winaero Tweaker
echo Installing Winaero Tweaker...
"%SOURCE_DIR%WinaeroTweaker-1.63.0.0-setup.exe" /VERYSILENT /SUPPRESSMSGBOXES /NORESTART
if errorlevel 1 (
    echo Error installing Winaero Tweaker
) else (
    echo Winaero Tweaker installation complete.
)
echo.

echo All installations complete!
pause

:: Remember, different installers require different silent switches
:: /S (common for NSIS installers like 7-Zip)
:: /VERYSILENT (Inno Setup installers)
:: /quiet (MSI installers)

Monday, July 7, 2025

Windows Update Registry Tweaks

Windows Update Registry Tweaks

Extend Pause Duration

Extends Windows Update pause options from default to max of ~7,300 days.

Copy to Notepad, save as ExtendWait.reg file, run as administrator:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WindowsUpdate\UX\Settings]
"FlightSettingsMaxPauseDays"=dword:00001c84

Pin to Specific Version

Prevents automatic upgrades to newer Windows versions while allowing security updates.

Copy to Notepad, save as LimitUpgrade.reg file, run as administrator:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate]
"TargetReleaseVersion"=dword:00000001
"TargetReleaseVersionInfo"="24H2"
Replace "24H2" with your desired version if necessary.

This one is interesting. I had a PC with 23H2 that would not see 24H2 when checking updates.
After adding the above reg, check updates found and started downloading 24H2.
Maybe not a good thing 😂 Wish me luck.

Keep Edge from requesting to be the default browser. EdgeNoDefault.reg
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge]
"DefaultBrowserSettingsEnabled"=dword:00000000

Sunday, July 6, 2025

Gimp 3 - I Finally Gave In

GIMP 3 - I Finally Gave In

I switched to GIMP 3 primarily for its improved high-resolution screen scaling on my XPS 13.

Why I Switched

GIMP 3 handles high-resolution screen scaling much better than version 2.10. I've been using 2.10 on my XPS 13 for years with poor scaling results.

Installation Issues

The official GIMP 3 installation loads very slowly, which isn't practical for regular use. I removed it and tried Samj's portable version instead.

Samj's Portable GIMP 3

This version loads faster but slower than 2.10. It is usable. It's a significant improvement over the official installer.

Download Link

Samj's Portable GIMP 3

Key Points

  • Proper high-resolution scaling support
  • Normal loading speeds (unlike the official version)
  • Includes useful plug-ins
  • No installation required
  • Still working on adding the old Layer Effects plug-in

Conclusion

If you need better scaling support on high-resolution displays, Samj's portable GIMP 3 is worth trying. The performance improvement over the official installer makes it more practical for regular use.

Saturday, July 5, 2025

Windows Sandbox Testing Winget

 

Testing Software Installation with Windows Sandbox

What This Guide Is About

This guide shows you how to safely test software installations using Windows Sandbox - a feature that creates a temporary, isolated copy of Windows on your computer. Think of it as a practice area where you can install programs without affecting your main system.

We'll be using a tool called Winget (Windows Package Manager) to automatically install multiple programs simultaneously, which is significantly faster than downloading and installing each program individually.

Important Notes Before Starting

Different versions of Windows behave differently with Sandbox. If something doesn't work as described, it might be due to your Windows version.

Windows 11 24H2 users: You'll need to add --source winget to the commands because the Microsoft Store isn't accessible in Sandbox. This means you can't install apps that are only available through the Store.

Step 1: Enable Windows Sandbox

  1. Press the Windows key
  2. Type "features"
  3. Click "Turn Windows features on or off"
  4. Check the box next to "Windows Sandbox"
  5. Restart your computer when prompted

Helpful tip: You can copy and paste text between Sandbox and your main computer, but you can't drag and drop files.

Step 2: Create the Necessary Folders

Open Command Prompt and create these folders on your main computer:

mkdir C:\Sandbox
mkdir C:\Sandbox\winget_install

The C:\Sandbox folder will be shared with your Sandbox environment, and winget_install will contain the installation files.

Step 3: Download Required Files

You'll need to download three files from the Microsoft Winget GitHub page:

* 1 & 2 are a single zip file. Open the x64 folder and extract the two files.

  1. Microsoft.VCLibs file (a dependency)
  2. Microsoft.UI.Xaml file (a dependency)
  3. Microsoft.DesktopAppInstaller file (the main Winget installer)

Place all three files in your C:\Sandbox\winget_install folder.

Here is a cmd file to automate the process. Manually extract x64 dependencies.

mkdir C:\Sandbox\winget_install

curl -L https://github.com/microsoft/winget-cli/releases/download/v1.11.400/DesktopAppInstaller_Dependencies.zip -o C:\Sandbox\winget_install\DesktopAppInstaller_Dependencies.zip

curl -L https://github.com/microsoft/winget-cli/releases/download/v1.11.400/Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.msixbundle -o C:\Sandbox\winget_install\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.msixbundle

Step 4: Create Configuration Files

Basic Sandbox Configuration

Create a file called Sandbox.wsb with this content:

<Configuration>
  <MappedFolders>
    <MappedFolder>
      <HostFolder>C:\Sandbox</HostFolder>
      <ReadOnly>false</ReadOnly>
    </MappedFolder>
  </MappedFolders>
</Configuration>

This tells Sandbox to share your C:\Sandbox folder.

Advanced Configuration (Auto-Install)

For automatic installation when Sandbox starts, use this version instead:
(The powershell.exe extends beyond the right margin to preserve copy, paste, run viability)
<Configuration>
    <MappedFolders>
        <MappedFolder>
            <HostFolder>C:\Sandbox</HostFolder>
            <SandboxFolder>C:\Users\WDAGUtilityAccount\Desktop\Sandbox</SandboxFolder>
            <ReadOnly>false</ReadOnly>
        </MappedFolder>
    </MappedFolders>
    <LogonCommand>
        <Command>powershell.exe -ExecutionPolicy Bypass -NoExit -File "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\install.ps1"</Command>
    </LogonCommand>
</Configuration>

This automatically runs the installation script when Sandbox starts.

Step 5: Create Installation Scripts

install.cmd (Simple Launcher)

Create install.cmd in your C:\Sandbox\winget_install folder:

powershell.exe -ExecutionPolicy Bypass -File install.ps1

install.ps1 (Main Installation Script)

Create install.ps1 in your C:\Sandbox\winget_install folder:
(You could use $HOME\ which is the same as %USERPROFILE% in CMD)
# Install required dependencies
Add-AppxPackage "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\Microsoft.VCLibs.140.00.UWPDesktop_14.0.33728.0_x64.appx"
Add-AppxPackage "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\Microsoft.UI.Xaml.2.8_8.2310.30001.0_x64.appx"
Add-AppxPackage "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.msixbundle"
# Wait for winget to be ready Start-Sleep -Seconds 10 # Remove Microsoft Store source to avoid errors winget source remove msstore # Install programs
winget install -e --id Notepad++.Notepad++ --accept-source-agreements --accept-package-agreements --force
winget install -e --id 7zip.7zip --accept-source-agreements --accept-package-agreements --force

This guide shows you how to safely test software installations using Windows Sandbox - a feature that creates a temporary, isolated copy of Windows on your computer. Think of it as a practice area where you can install programs without affecting your main system.

We'll be using a tool called Winget (Windows Package Manager) to automatically install multiple programs simultaneously, which is significantly faster than downloading and installing each program individually.

Important Notes Before Starting

Different versions of Windows behave differently with Sandbox. If something doesn't work as described, it might be due to your Windows version.

Windows 11 24H2 users: You'll need to add --source winget to the commands because the Microsoft Store isn't accessible in Sandbox. This means you can't install apps that are only available through the Store.

Step 1: Enable Windows Sandbox

  1. Press the Windows key
  2. Type "features"
  3. Click "Turn Windows features on or off"
  4. Check the box next to "Windows Sandbox"
  5. Restart your computer when prompted

Helpful tip: You can copy and paste text and files between Sandbox and your main computer, but you can't drag and drop.

Step 2: Create the Necessary Folders

Open Command Prompt and create these folders on your main computer:

mkdir C:\Sandbox
mkdir C:\Sandbox\winget_install

The C:\Sandbox folder will be shared with your Sandbox environment, and winget_install will contain the installation files.

Step 3: Download Required Files

You'll need to download three files from the Microsoft Winget GitHub page:

* 1 & 2 are a single zip file. Open the 64 folder and extract the two files.

  1. Microsoft.VCLibs file (a dependency)
  2. Microsoft.UI.Xaml file (a dependency)
  3. Microsoft.DesktopAppInstaller file (the main Winget installer)

Place all three files in your C:\Sandbox\winget_install folder.

Step 4: Create Configuration Files

Basic Sandbox Configuration

Create a file called Sandbox.wsb with this content:

<Configuration>
  <MappedFolders>
    <MappedFolder>
      <HostFolder>C:\Sandbox</HostFolder>
      <ReadOnly>false</ReadOnly>
    </MappedFolder>
  </MappedFolders>
</Configuration>

This tells Sandbox to share your C:\Sandbox folder.

Advanced Configuration (Auto-Install)

For automatic installation when Sandbox starts, use this version instead:

<Configuration>
    <MappedFolders>
        <MappedFolder>
            <HostFolder>C:\Sandbox</HostFolder>
            <SandboxFolder>C:\Users\WDAGUtilityAccount\Desktop\Sandbox</SandboxFolder>
            <ReadOnly>false</ReadOnly>
        </MappedFolder>
    </MappedFolders>
    <LogonCommand>
        <Command>powershell.exe -ExecutionPolicy Bypass -NoExit -File "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\install.ps1"</Command>
    </LogonCommand>
</Configuration>

This automatically runs the installation script when Sandbox starts.

Step 5: Create Installation Scripts

install.cmd (Simple Launcher)

Create install.cmd in your C:\Sandbox\winget_install folder:

powershell.exe -ExecutionPolicy Bypass -File install.ps1

install.ps1 (Main Installation Script)

Create install.ps1 in your C:\Sandbox\winget_install folder:

# Install required dependencies
Add-AppxPackage "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\Microsoft.VCLibs.140.00.UWPDesktop_14.0.33728.0_x64.appx"
Add-AppxPackage "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\Microsoft.UI.Xaml.2.8_8.2310.30001.0_x64.appx"
Add-AppxPackage "C:\Users\WDAGUtilityAccount\Desktop\Sandbox\winget_install\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe.msixbundle"
# Wait for winget to be ready Start-Sleep -Seconds 10 # Remove Microsoft Store source to avoid errors winget source remove msstore # Install programs

What This Does

When you run the Sandbox with these configurations:

  1. Creates a safe testing environment - Nothing you do in Sandbox affects your main computer
  2. Automatically installs Winget - Sets up the package manager in the isolated environment
  3. Tests software installation - Installs Notepad++ and 7-Zip as examples
  4. Validates your setup - If programs install successfully in Sandbox, they should work on your real computer

Why This Is Useful

  • Safety first - Test potentially problematic software without risk
  • Batch testing - Try installing multiple programs at once
  • Clean environment - Start fresh each time without leftover files
  • Time saving - Automate repetitive installation tasks

Getting Started

  1. Enable Windows Sandbox
  2. Create the folder structure
  3. Download the required files
  4. Create the configuration and script files
  5. Double-click your Sandbox.wsb file to start

Your Sandbox will open and automatically begin installing the test programs. If everything works, you should be able to continue testing and manipulating other software and scripts.


Here are a couple of scripts I use on new PC setups. They should test successfully on your new Sandbox.

my_install.cmd for further reference (Place this in C:\Sandbox)
I use it on all new system setups, Sandbox was only an experiment. 🤣
If it installs on Sandbox, it will install on hardware.
    Remove the : for non-Sandbox installs.

cd %userprofile%\Desktop
mkdir C:\Portable\Excluded
mkdir C:\Drivers\Benchmarks
mkdir C:\Desk
mkdir %userprofile%\Pictures\Wallpaper
mkdir %userprofile%\\Program Archives
:winget install -e --id=Microsoft.VCRedist.2015+.x64
winget install -e --id=Microsoft.VCRedist.2015+.x86
:winget install -e --id=Chocolatey.Chocolatey
winget install -e --id 7zip.7zip
:winget install -e --id=Notepad++.Notepad++
::UnigetUI
winget install -e --id=MartiCliment.UniGetUI
winget install -e --id=winaero.tweaker
::Wintoys
winget install -e  --accept-source-agreements --accept-package-agreements --id=9P8LTPGCBZXD
winget install -e --id=RevoUninstaller.RevoUninstaller
winget install -e --id=CodeJelly.Launchy
winget install -e --silent --id=IObit.IObitUnlocker
::TranslucentTB
winget install -e --accept-source-agreements --accept-package-agreements --id=9PF4KZ2VN4W9
winget install -e --silent --id=2BrightSparks.SyncBackFree

winget install -e --silent --id=AOMEI.Backupper.Standard
winget install -e --id=AutoHotkey.AutoHotkey
winget install -e --id=voidtools.Everything
:winget install -e --id=AdrienAllard.FileConverter
winget install -e --id=Brave.Brave
winget install -e --id=HexChat.HexChat
winget install -e --id=IrfanSkiljan.IrfanView
winget install -e --id=IrfanSkiljan.IrfanView.PlugIns
winget install -e --id=Microsoft.PowerToys
winget install -e --id=qBittorrent.qBittorrent
winget install -e --id=ShareX.ShareX
:winget install -e --id=Oracle.VirtualBox
winget install -e --id=VideoLAN.VLC

curl.exe -L https://eternallybored.org/misc/wget/1.21.4/64/wget.exe -o C:\Windows\System32\wget.exe
curl.exe -L https://www.ugmfree.it/Download/SyMenu/SyMenu.zip -o C:\Portable\symenu.zip
curl.exe -L https://www.carifred.com/uvk/UVKPortable.exe -o C:\Portable\UVK.exe
curl.exe -L https://www.sordum.org/files/download/defender-exclusion-tool/ExcTool.zip -o C:\Portable\Excluded\ExcTool.zip
curl.exe -L https://downloads.wisecleaner.com/soft/WDCFree_11.1.6.832.zip -o C:\Portable\WDCFree.zip
curl.exe -L https://windows-repair-toolbox.com/files/Windows_Repair_Toolbox.zip -o C:\Portable\Windows_Repair_Toolbox.zip

msg * "irm christitus.com/win | iex"
pause

Separate Extract_Delete.cmd
    No big deal. I just wanted to do it. Manual extract is fast and easy.
    Answer "A" to the first request and all will continue without interruption.

"C:\Program Files\7-Zip\7z.exe" e "C:\Portable\Excluded\ExcTool.zip" -o"C:\Portable\Excluded\ExcTool" && del C:\Portable\Excluded\ExcTool.zip"

"C:\Program Files\7-Zip\7z.exe" e "C:\Portable\Windows_Repair_Toolbox.zip" -o"C:\Portable\Windows_Repair_Toolbox" && del "C:\Portable\Windows_Repair_Toolbox.zip"

"C:\Program Files\7-Zip\7z.exe" e "C:\Portable\symenu.zip" -o"C:\Portable\Symenu" && del "C:\Portable\symenu.zip"

"C:\Program Files\7-Zip\7z.exe" e "C:\Portable\WDCFree.zip" -o"C:\Portable\WDCFree" && del "C:\Portable\WDCFree.zip"

Friday, June 20, 2025

NovaBenchmark


 On my old Predator 17
                               


My Ryzen 5 at the office








JSON Editing and Notepad++

Inserting Lines Below the Selection 1. Select a line or lines 2. Ctrl + D 3. The lines will be inserted below the selection. If lines alread...