mirror of
https://github.com/lune-org/lune.git
synced 2024-12-12 13:00:37 +00:00
Make process.spawn result a global type
This commit is contained in:
parent
be39ecc00a
commit
f3cb4f2ce0
2 changed files with 9 additions and 6 deletions
|
@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
### Added
|
||||
|
||||
- Setting `cwd` in the options for `process.spawn` to a path starting with a tilde (`~`) will now use a path relative to the platform-specific home / user directory.
|
||||
- Added a global type `ProcessSpawnOptions` for the return type of `process.spawn`
|
||||
|
||||
### Changed
|
||||
|
||||
|
|
|
@ -213,6 +213,13 @@ export type ProcessSpawnOptions = {
|
|||
stdio: ProcessSpawnOptionsStdio?,
|
||||
}
|
||||
|
||||
export type ProcessSpawnResult = {
|
||||
ok: boolean,
|
||||
code: number,
|
||||
stdout: string,
|
||||
stderr: string,
|
||||
}
|
||||
|
||||
--[=[
|
||||
@class process
|
||||
|
||||
|
@ -274,12 +281,7 @@ declare process: {
|
|||
program: string,
|
||||
params: { string }?,
|
||||
options: ProcessSpawnOptions?
|
||||
) -> {
|
||||
ok: boolean,
|
||||
code: number,
|
||||
stdout: string,
|
||||
stderr: string,
|
||||
},
|
||||
) -> ProcessSpawnResult,
|
||||
}
|
||||
|
||||
--[=[
|
||||
|
|
Loading…
Reference in a new issue