WslLaunch function wslapi

int WslLaunch(
  1. Pointer<Utf16> distributionName,
  2. Pointer<Utf16> command,
  3. int useCurrentWorkingDirectory,
  4. int stdIn,
  5. int stdOut,
  6. int stdErr,
  7. Pointer<IntPtr> process,
)

Launches a Windows Subsystem for Linux (WSL) process in the context of a particular distribution.

HRESULT WslLaunch(
  _In_ PCWSTR distributionName,
  _In_opt_ PCWSTR command,
  _In_ BOOL useCurrentWorkingDirectory,
  _In_ HANDLE stdIn,
  _In_ HANDLE stdOut,
  _In_      HANDLE  stdErr,
  _Out_     HANDLE  *process
);

Implementation

int WslLaunch(
  Pointer<Utf16> distributionName,
  Pointer<Utf16> command,
  int useCurrentWorkingDirectory,
  int stdIn,
  int stdOut,
  int stdErr,
  Pointer<IntPtr> process,
) => _WslLaunch(
  distributionName,
  command,
  useCurrentWorkingDirectory,
  stdIn,
  stdOut,
  stdErr,
  process,
);