Enhanced Batch is a solution to improve the functionality of your classic Windows batch files.
Applying a technique called Windows API Hooking, we have added capabilities never seen before.
You can store variables internally in the heap, instead of the environment block, saving the overhead of this last.
These heap variables begin with the
Also, there are extensions identified with the
Additionally, some bugs of
cmd.exe are fixed.
Example of heap variable:
Set $myPrivateVar=Okay Rem Looking in the environment block, it will say not defined. Set $myPrivateVar Rem Looking in the heap also If Defined $myPrivateVar ( Echo Yep, it is defined in the heap Echo $myPrivateVar = %$myPrivateVar% )
The extensions can have getters and setters.
Example of an extension, in this case
Echo Working with unicode: %@unicode% If "%@unicode%"=="0" ( Echo Enabling unicode Set "@unicode=1" )
Just download the DLLs from the release.
Load the library and verify the result with the following command at the start of your batch script:
Rundll32 "%~dp0enhancedbatch_%processor_architecture%" Load If Not Defined @enhancedbatch ( Echo Load Failed Pause Exit )
Alternatively, you can use this brief method:
Regsvr32 /e "%~dp0enhancedbatch_%processor_architecture%" || ( Echo Load Failed Pause Exit )
If DLL could not be loaded a messagebox dialog will appear indicating the cause.
Enhanced Batch requires the command interpreter for Windows (
About the project
Enhanced Batch is:
© 2019 by Carlos Montiers A.
© 2019 by Jason Hood
Enhanced Batch is distributed by an zlib license.
When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the owners of this repository before making a change.