|
1 | | -*simplegpt.txt* For NVIM v0.8.0 Last change: 2025 May 27 |
| 1 | +*simplegpt.txt* For NVIM v0.8.0 Last change: 2025 July 04 |
2 | 2 |
|
3 | 3 | ============================================================================== |
4 | 4 | Table of Contents *simplegpt-table-of-contents* |
@@ -288,8 +288,8 @@ I have attempted to summarize the key concepts and manual in one image. |
288 | 288 |
|
289 | 289 | The question is constructed by rendering a template. The 't' register serves as |
290 | 290 | the template, encompassing: - Special variables such as `{{content}}`, |
291 | | -`{{filetype}}`, and `{{visual}}`. - Standard registers like `{{a}}`, `{{b}}`, |
292 | | -and `{{c}}`. |
| 291 | +`{{filetype}}`, `{{visual}}`, and `{{context_line_num}}`. - Standard registers |
| 292 | +like `{{a}}`, `{{b}}`, and `{{c}}`. |
293 | 293 |
|
294 | 294 |
|
295 | 295 | CHAT *simplegpt-demos-chat* |
@@ -472,16 +472,17 @@ You can use these variables in your jinja template. | key | meaning | | - | - | |
472 | 472 | | content | Content around the cursor, limited by a configurable length | | |
473 | 473 | full_content | Entire content of the current file | | filetype | Filetype of |
474 | 474 | the current buffer | | visual | Lines selected in visual mode | | context | |
475 | | -Context around the cursor, configurable lines up/down | | all_buf | Content |
476 | | -from all loaded buffers with files on disk | | lsp_diag | LSP diagnostics |
477 | | -information for the selected lines | | md_context | Directly loading the |
478 | | -content in `.sgpt.md` as the register value. | | filename | The name of the |
479 | | -current file | | terminal | The content from the active (visiable) terminal |
480 | | -buffer, capturing recent terminal output (if available) | | full_terminal | |
481 | | -like terminal, but including all terminal output | | p | If register `p` |
482 | | -contains a list of file paths (one per line), its value becomes the |
483 | | -concatenation of the content from each of those files. Files that do not exist |
484 | | -will be skipped. | |
| 475 | +Context around the cursor, configurable lines up/down | | context_line_num | |
| 476 | +Like `context` but additionally shows absolute line numbers and marks the |
| 477 | +current line with `>>` for precise location | | all_buf | Content from all |
| 478 | +loaded buffers with files on disk | | lsp_diag | LSP diagnostics information |
| 479 | +for the selected lines | | md_context | Directly loading the content in |
| 480 | +`.sgpt.md` as the register value. | | filename | The name of the current file | |
| 481 | +| terminal | The content from the active (visiable) terminal buffer, capturing |
| 482 | +recent terminal output (if available) | | full_terminal | like terminal, but |
| 483 | +including all terminal output | | p | If register `p` contains a list of file |
| 484 | +paths (one per line), its value becomes the concatenation of the content from |
| 485 | +each of those files. Files that do not exist will be skipped. | |
485 | 486 |
|
486 | 487 |
|
487 | 488 | TEMPLATE ENGINE |
|
0 commit comments