Delphi-RAG-Lint

drag-lint help

ghost-check

Since: 1.8.0-alpha

Compiles a project with one or more units' content temporarily replaced by their unsaved editor buffers, then restores the original files unchanged.

Read this when you want compiler diagnostics for edits you have not saved. ghost-check compiles the project with chosen units temporarily replaced by their buffers, then restores the original files unchanged.

How to run it

Full flag list: ghost-check in the CLI reference.

Flags

FlagArgumentMeaningDefault
--unit<real.pas>
--buffer<buf>
--overlays<manifest>
--platform
--in-place
--format

Where to click

  • RAD Studio main menu: drag-lint > Compile Buffer (unsaved)
    1. Edit a unit without saving it
    2. drag-lint > Compile Buffer (unsaved)
    3. Compiler errors from the unsaved buffer are shown; the original files are restored unchanged

Pitfalls

  • compiles each UNSAVED buffer from a shadow dir; your real files are NEVER written. --in-place restores the old behaviour (overwrites the real files for the compile, then restores them) -- it can lose live edits if the IDE reloads inside that window. compile the UNSAVED editor buffer by overlaying it on the real unit. Backs the IDE's "Compile Buffer (unsaved)". Restores the original on exit.

Details

Compiles a project with one or more units' content temporarily replaced by their unsaved editor buffers, then restores the original files unchanged. Reach for it to get compiler diagnostics against unsaved edits without saving them to disk.

Running it from the CLI

drag-lint ghost-check <dproj> ( --unit <real.pas> --buffer <buf> | --overlays <manifest> ) [--platform win32|win64] [--in-place] [--format json|text]

<dproj> is the project to compile. Give either a single --unit <real.pas> --buffer <buf> pair, or an --overlays <manifest> file listing multiple real-path/buffer-path pairs. --platform selects win32 or win64. --format selects json or text.

What it needs

Not needed, per the feature map's Index column.

Example

Illustrative only:

drag-lint ghost-check C:\Projects\MyApp\MyApp.dproj --unit C:\Projects\MyApp\frmOrders.pas --buffer C:\Projects\MyApp\_D-RAG\frmOrders.buf --platform win32 --format json

This would compile MyApp.dproj with frmOrders.pas's content replaced by the buffer file, report diagnostics as JSON, then restore frmOrders.pas unchanged.


All features | CLI reference | IDE menus