Shim Execuable generates an executable 'shim' that will in turn execute another file relative to its location. This is an attempt at a drop in replacement for the RealDimensions Softwarem LLC's (RDS) shimgen.exe
that comes with Chocolatey, however has various other possible uses. The shims and generator have evolved from kiennq's c++ shim implementation for Scoop (see the history section for more info)
- ❗ Executes GUI applications without the brief console window display
- Free and Open Source
- Able to be freely used outside of "official" Chocolatey builds without a paid license.
- Faster shim creation
- Better support for
crtl+c
, as shim passes signal to child process - Tries to terminate child processes if parent process is killed
- Consistent checksum for all shims
- No use of
csc.exe
byshimgen.exe
- Supports icons for the shims
- Compatible replacement of
shimgen.exe
(i.e., all documented command arguments are available)
- More testing
- Impliment changing of icon
- More testing
- Add support to embedding working directory into shim
- Add option to create Scoop-style shims (
.shim
file next to each shim.exe
)
- Download a release or build it yourself
- Run
shim_exec.exe <source>
This will create an executable in the current directory named the same as <source>
that will in turn execute it. More options can be viewed via shim_exec.exe -h
. The shim itself has additional options and can be viewed using --shim-help
.
You should be able to replace shimgen.exe
in your Chocolately source code tree, however it hasn't been thoroughly tested and will probably void your warranty. The PowerShell script, ./tools/replace_shimgen.ps1, can be used to toggle this replacement.
- Get a copy of Visual Studio. Installing just the "Desktop Development w/ C++" should suffice however the minimum I installed was:
- Microsoft Visual Studio Workload - Core Editor
- Microsoft Visual Studio Component - Core Editor
- Microsoft Visual Studio Workload - Native Desktop
- Microsoft Visual Studio Component Group - Native Desktop Core
- Microsoft Visual Studio Component - Roslyn Compiler
- Microsoft Visual Studio Component - Text Templating
- Microsoft Visual Studio Component - VC Core IDE
- Microsoft Visual Studio Component - VC Tools x86 x64
- Microsoft Visual Studio Component - VC Redist 14 Latest
- Microsoft Visual Studio Component - Windows 11 SDK 22000
- Microsoft Component - MSBuild
- Build using
nmake
. Visual Studio should have installednmake
however other flavors should be able to process the included makefile.
SPDX-License-Identifier: MIT OR Unlicense