From fcb9a7d36547dc71c9f5d712163b5ac13d82a724 Mon Sep 17 00:00:00 2001 From: Roman Kharitonov Date: Thu, 13 Nov 2025 22:47:12 +1000 Subject: [PATCH] Update config and Claude docs --- .idea/copilot.data.migration.agent.xml | 6 ++++ .idea/modules.xml | 8 +++++ CLAUDE.md | 43 ++++++++++---------------- 3 files changed, 31 insertions(+), 26 deletions(-) create mode 100644 .idea/copilot.data.migration.agent.xml create mode 100644 .idea/modules.xml diff --git a/.idea/copilot.data.migration.agent.xml b/.idea/copilot.data.migration.agent.xml new file mode 100644 index 0000000..4ea72a9 --- /dev/null +++ b/.idea/copilot.data.migration.agent.xml @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..348b976 --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/CLAUDE.md b/CLAUDE.md index b84547e..b4e1c08 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -2,52 +2,42 @@ This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. -## Build Commands +## Build -**IMPORTANT: This project ONLY builds on Windows with MSVC toolchain. Do not attempt to build on Linux.** +This project uses CMake with vcpkg for dependency management, builds only on Windows and requires Visual Studio 2017+. -This project uses CMake with vcpkg for dependency management and requires Visual Studio 2017+ on Windows: - -```bash -# Configure build (requires VCPKG_ROOT environment variable) -cmake --preset x64-release # or x86-release - -# Build all modules -cmake --build build/x64-release - -# Run tests -cd build/x64-release && ctest - -# Package for distribution -cd build/x64-release && cpack --config CPackConfig.cmake -C RelWithDebInfo -``` - -Build presets available: `x64-release`, `x64-debug`, `x86-release`, `x86-debug` +Do not attempt to build the code or run tests, as the environment is not set up for it. ## Development Guidelines This project uses **C++23** and follows KISS (Keep It Simple, Stupid) and DRY (Don't Repeat Yourself) principles. -**Avoid magic numbers** - use named constants instead. +Avoid magic numbers. ## Architecture Overview -This project implements Observer plugin modules for FAR Manager that handle exotic archive formats. The codebase follows a plugin architecture where each module implements the Observer API to support different archive formats. +This project implements Observer plugin modules for FAR Manager that handle exotic archive formats. The codebase follows +a plugin architecture where each module implements the Observer API to support different archive formats. ### Core Components -- **API Layer** (`src/api.h`, `src/dll.cpp`): Implements the Observer plugin API with standard functions like `OpenStorage`, `CloseStorage`, `GetItem`, `ExtractItem` -- **Archive Wrapper** (`src/archive.h`, `src/archive.cpp`): Provides a unified interface that wraps format-specific extractors -- **Extractor Interface** (`src/modules/extractor.h`): Defines the abstract interface that all format extractors must implement +- **API Layer** (`src/api.h`, `src/dll.cpp`): Implements the Observer plugin API with standard functions like + `OpenStorage`, `CloseStorage`, `GetItem`, `ExtractItem` +- **Archive Wrapper** (`src/archive.h`, `src/archive.cpp`): Provides a unified interface that wraps format-specific + extractors +- **Extractor Interface** (`src/modules/extractor.h`): Defines the abstract interface that all format extractors must + implement ### Module Structure Each supported format has its own module under `src/modules/`: + - `renpy/`: RenPy visual novel archives (.rpa files) with pickle support -- `zanzarah/`: Zanzarah game archives (.pak files) +- `zanzarah/`: Zanzarah game archives (.pak files) - `rpgmaker/`: RPG Maker archives (in development) Each module contains: + - Format-specific implementation (e.g., `renpy.cpp`) - Module definition file (`.def`) for DLL exports - Configuration file (`observer_user.ini`) @@ -62,4 +52,5 @@ Each module contains: ### Testing Framework -Located in `src/tests/` with a custom framework (`framework/observer.h`) that simulates the Observer API for testing archive operations without requiring FAR Manager. \ No newline at end of file +Located in `src/tests/` with a custom framework (`framework/observer.h`) that simulates the Observer API for testing +archive operations without requiring FAR Manager. \ No newline at end of file