Skip to main content
Module

x/johnny_decimal/commands/index.ts

Utilities for interacting with a Johnny Decimal filing system.
Go to Latest
File
import { Command } from "../models/command.ts";import { Directory } from "../models/directory.ts";import { logLocationFilenames } from "../utilities/log_utilities.ts";
/** * @name IndexCommand * * @description * Logs all the directories in our JD Filesystem */const indexCommand: Command = { name: "index", usage: "jd index", description: "Show all directories in your JD filesystem",
async fn(this: Directory) { const locations = await this.listAllLocations(); const names = locations.map(({ name }) => name); logLocationFilenames(names); },};
export default indexCommand;