Skip to the content

Tane種

Reproduce numbers from a seed, shuffle or pick items, share a daily puzzle and resume a saved stream.

Tane means seed in Japanese. About the name

Contents

Reference · Streams, draws and seeds

CliResulttype

What the command line came to.

Import it

import type { CliResult } from "@johnmorrisdotca/tane";

Definition

type CliResult = {
    code: 0 | 1 | 2;
    out: string;
    err: string;
};

Members

NameTypeDescription
code0 | 1 | 2

0 when all went well, 1 when what was asked for could not be done, 2 when the command itself was wrong.

outstring

For standard output.

errstring

For standard error.

Examples

import type { CliResult } from "@johnmorrisdotca/tane";
import { runCli } from "@johnmorrisdotca/tane";

const value: CliResult = runCli(["--help"]);
console.log(value.code);
0

What it prints (run when this page was built)

View sourceEdit on GitHubMade from the source of @johnmorrisdotca/tane 1.3.0.