Skip to content

Commit 90adbcf

Browse files
committed
feat: add buffer resize without affecting window size
1 parent 5397d54 commit 90adbcf

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

wputility.bat

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
1-
@ECHO OFF
2-
TITLE WPU (Windows Personalization Utility)
3-
MODE con:cols=125 lines=40
4-
MODE 125,40
5-
GOTO comment_end
1+
@echo off
2+
title WPU (Windows Personalization Utility)
3+
goto comment_end
64

75
This script automatically modifies the registry to disable or enable Windows updates.
86
It will also check the standard windows folder where updates are stored, and deletes any
@@ -24,6 +22,18 @@ if %errorlevel% neq 0 (
2422
goto :sessError
2523
)
2624

25+
:: # #
26+
:: @desc resize the batch window and adjust the buffer so that text does not get cut off.
27+
:: # #
28+
29+
set cols=125
30+
set lines=40
31+
set colsbuff=125
32+
set linesbuff=500
33+
34+
mode con: cols=%cols% lines=%lines%
35+
powershell -command "&{$H=get-host;$W=$H.ui.rawui;$B=$W.buffersize;$B.width=%colsbuff%;$B.height=%linesbuff%;$W.buffersize=$B;}"
36+
2737
:: # #
2838
:: @desc define vars
2939
:: # #
@@ -302,7 +312,7 @@ for /f "UseBackQ Tokens=1-4" %%A In ( `powershell "$OS=GWmi Win32_OperatingSyste
302312
cls
303313
echo:
304314
echo:
305-
echo %goldm%v%repo_version%%u% %grayd%Windows Personalization Utility%u%
315+
echo %goldm%v%repo_version%%u% %grayd%Windows Personalization Utility%u%
306316
echo:
307317
echo %fuchsia2% ██╗ ██╗██████╗ ██╗ ██╗████████╗██╗██╗ ██╗████████╗██╗ ██╗
308318
echo ██║ ██║██╔══██╗██║ ██║╚══██╔══╝██║██║ ██║╚══██╔══╝╚██╗ ██╔╝

0 commit comments

Comments
 (0)