ShAssocCheck 0.2.0
See the version list below for details.
dotnet add package ShAssocCheck --version 0.2.0
NuGet\Install-Package ShAssocCheck -Version 0.2.0
<PackageReference Include="ShAssocCheck" Version="0.2.0" />
paket add ShAssocCheck --version 0.2.0
#r "nuget: ShAssocCheck, 0.2.0"
// Install ShAssocCheck as a Cake Addin
#addin nuget:?package=ShAssocCheck&version=0.2.0
// Install ShAssocCheck as a Cake Tool
#tool nuget:?package=ShAssocCheck&version=0.2.0
If you would like your Visual Studio projects to be robust against developers encountering mysterious build failures due to pipe redirection failures or missing .sh
file associations, then add this NuGet dependency. Keep in mind that this NuGet package normally doesn't do anything, except verify that .sh
scripts are in fact working. If you have a controlled development envitonment where you can ensure everyone has Bash/CoreUtils properly installed, then there's really no need to use the ShAssocCheck
NuGet Package.
If you have a solution with many projects then it is a good idea to attach ShAssocCheck
NuGet package to a special startup project in your solution that runs before anything else. Often times solutions will have such a project for the purpose of collecting git repository version information and this NuGet package is best added as a dependency there. If the solution doesn't have such a project, then probably it probably should have one.
How it Works
The script tests for operational .sh
file associations by running a short .sh
script and getting the result via pipe redirection. If it works, then the script does nothing else. If that check fails, the script proceeds to check sh_auto_file
and see if it matches git-bash.exe. If so, it applies the Git for Windows association patch fix via a NSIS installer. The installer is used because it provides
the Admin Elevated Rights profile required to modify file types and associations, and will be invoked only once after any Git for Windows install/update (due to GitWin overwritting our association with it's broken one).
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Initial package release.