SGrottel.FindExecutable 0.4.0.5

Requires NuGet 3.3 or higher.

dotnet add package SGrottel.FindExecutable --version 0.4.0.5                
NuGet\Install-Package SGrottel.FindExecutable -Version 0.4.0.5                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SGrottel.FindExecutable" Version="0.4.0.5" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add SGrottel.FindExecutable --version 0.4.0.5                
#r "nuget: SGrottel.FindExecutable, 0.4.0.5"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install SGrottel.FindExecutable as a Cake Addin
#addin nuget:?package=SGrottel.FindExecutable&version=0.4.0.5

// Install SGrottel.FindExecutable as a Cake Tool
#tool nuget:?package=SGrottel.FindExecutable&version=0.4.0.5                

SGrottel.FindExecutable

C# code to find the full path of an executable file by searching the system's search paths.

https://github.com/sgrottel/FindExecutable

Example

FindExecutable is a static class with one public static method:

public static string? FullPath(
	string executable,
	bool includeCurrentDirectory = false,
	bool includeBaseDirectory = false,
	IEnumerable<string>? additionalPaths = null);
  • executable -- The name of the executable to find.
  • includeCurrentDirectory -- If set to true, the current execution directory is included in the list of search paths
  • includeBaseDirectory -- If set to true, the application domain base directory is included in the list of search paths
  • additionalPaths -- If set to something other then null, the paths iterated within are included in the list of search paths

The function will return the full file system path to the executable file requested, or null if the file is not found.

License

This project is freely available under the terms of the MIT License

Copyright (c) 2023-2024 Sebastian Grottel

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
There are no supported framework assets in this package.

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.

Version Downloads Last updated
0.4.0.5 519 5/20/2024