repository-inspector
v1.0.0
Published
A CLI tool for recursively consolidating repository source files with detailed metadata.
Readme
Repository Inspector
Repository Inspector is a CLI tool that recursively consolidates source files (with extensions .ts, .js, .json, and .env) from a specified repository into a single output file. Each file's content is preceded by a marker comment showing its relative path. The output also includes metadata such as the source directory, timestamp, tool name, and configuration details.
Installation
From Source
Clone the repository and install dependencies:
git clone <repository_url>
cd repository-inspector
npm installGlobal Installation via npm
If the package is published on npm, install it globally:
npm install -g repository-inspectorUsage
You have several options to run the tool:
Development Mode (using ts-node)
Run the tool directly from the source without building:
npm run dev -- <command> [path] [file_prefix]For example:
npm run dev -- consolidate-sources src/ userProduction Mode (after building)
First, build the project:
npm run buildThen, run the compiled code:
npm start -- <command> [path] [file_prefix]For example:
npm start -- consolidate-sources src/ userGlobal Installation
If installed globally, you can run the tool using its binary name:
repo-inspector <command> [path] [file_prefix]Available Commands
- consolidate-sources: Consolidates code into one file (
consolidated_sources.ts). Optionally, you can provide a file prefix to filter the files. - help: Displays the help message with usage instructions.
License
ISC
