UNPKG

sesterce-cli

Version:

A powerful command-line interface tool for managing Sesterce Cloud services. Sesterce CLI provides easy access to GPU cloud instances, AI inference services, container registries, and SSH key management directly from your terminal.

42 lines (31 loc) 660 B
export class Left<L, A> { readonly value: L; constructor(value: L) { this.value = value; } isLeft(): this is Left<L, A> { return true; } isRight(): this is Right<L, A> { return false; } } export class Right<L, A> { readonly value: A; constructor(value: A) { this.value = value; } isLeft(): this is Left<L, A> { return false; } isRight(): this is Right<L, A> { return true; } } export type Either<L, A> = Left<L, A> | Right<L, A>; export const left = <L, A>(l: L): Either<L, A> => { return new Left<L, A>(l); }; export const right = <L, A>(a: A): Either<L, A> => { return new Right<L, A>(a); };