Nuke.Cola
Loading...
Searching...
No Matches
PythonTasks.cs
1using System;
2using System.Collections.Generic;
3using System.Linq;
4using System.Threading.Tasks;
5using Nuke.Common;
6using Nuke.Common.Tooling;
7
8namespace Nuke.Cola.Tooling;
9
10public class PythonTasks
11{
12 public static ValueOrError<Tool> EnsurePython => ToolCola.Use("py");
13 public static Tool Python => EnsurePython.Get();
14
15 public static ValueOrError<Tool> EnsurePip => ToolCola.Use("pip");
16 public static Tool Pip => EnsurePip.Get();
17}
static ValueOrError< Tool > Use(string tool, Action? setup=null)
Get a tool which should be in PATH, and provide an optional way to set it up automatically if it wasn...