https://github.com/losttech/whichpython
Cross-platform .NET library, that helps to list available Python installations
https://github.com/losttech/whichpython
hacktoberfest
Last synced: 5 months ago
JSON representation
Cross-platform .NET library, that helps to list available Python installations
- Host: GitHub
- URL: https://github.com/losttech/whichpython
- Owner: losttech
- License: mit
- Created: 2018-12-07T04:28:12.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2024-06-08T18:09:00.000Z (over 1 year ago)
- Last Synced: 2025-09-20T21:54:15.752Z (5 months ago)
- Topics: hacktoberfest
- Language: C#
- Homepage:
- Size: 74.2 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# WhichPython
Cross-platform library, that lists available Python environments
[](https://www.nuget.org/packages/WhichPython/)
## Sample (see app folder)
```csharp
foreach (var environment in PythonEnvironment.EnumerateEnvironments()
.Concat(CondaEnvironment.EnumerateCondaEnvironments())) {
Console.WriteLine(this.HomeOnly
? environment.Home?.FullName
: $"{environment.LanguageVersion?.ToString(2) ?? "??"}-{environment.Architecture?.ToString() ?? "???"} @ {environment.Home}");
}
```