# Anti-Cursor

A Python CLI utility to generate a Markdown prompt describing a project's source code structure and contents. The generated prompt includes an introductory explanation, a detailed projection of the file structure, and code listings from each source file (with file names).

## Features

- Accepts either a local directory path or a GitHub repository URL.
- Generates a Markdown prompt with:
  - A brief introduction to assist language models in understanding the context.
  - A detailed project structure tree.
  - Code listings from individual source files.
- Clean architecture with clear separation between CLI, core logic, and file parsing.
- Unit tests to ensure proper functionality.

## Project Structure

─ README.md
├── src/
│ └── prompt_generator/
│ ├── init.py
│ ├── cli.py
│ ├── prompt_generator.py
│ └── project_parser.py
└── tests/
└── test_prompt_generator.py


## Installation

1. **Clone the repository:**
```bash
git clone https://github.com/Alexander-Ploskin/anti-cursor.git
```

2. **Install the dependencies:**
```bash
pip install poetry
poetry install
sudo apt-get install xclip
```

## Usage

Run the CLI tool using:
```bash
anti-cursor <source>
```
Where `<source>` is either a local directory path or a GitHub repository URL.

**Examples:**
1. Generate prompt from local directory:
```bash
anti-cursor .
```
2. Generate prompt from GitHub repository:
```bash
anti-cursor https://github.com/Alexander-Ploskin/anti-cursor
```
