Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/johnny_decimal/models/directory_core.ts>DirectoryCore

Utilities for interacting with a Johnny Decimal filing system.
Latest
class DirectoryCore
import { DirectoryCore } from "https://deno.land/x/johnny_decimal@1.2.0/models/directory_core.ts";

Examples

class Directory extends DirectoryCore { constructor($JD_HOME){ this.$JD_HOME = $JD_HOME; } } const directory = new DirectoryCore() directory.registerCommand({ name: "log-home", fn: () => { console.log(this.$JD_HOME) } }); directory.runCommand("log-home");

Properties

commands: Record<string, any>

Methods

private
retrieveCommand(commandName: string)
hasCommand(name: string): boolean
registerAlias(commandName: string, aliasNames?: string[]): void
registerCommand(command: Command): void
runCommand(commandName: string, args: string[])