Commit Graph
10634 Commits
Author SHA1 Message Date
Grzybek 14b881fd05 Merge pull request #2159 from JetBrains/VIM-4350/prompt_injection
Fix(VIM-4350): Harden Claude and YouTrack GitHub workflows
2026-10-27 12:06:30 +01:00
1grzyb1andClaude Opus 5.5 ac56c4b379 Fix(VIM-4350): Limit the YouTrack Area Claude run to its YouTrack scripts
The run reads untrusted ticket text, and `Bash(npx tsx:*)` allowed
`npx tsx -e` with YOUTRACK_TOKEN and the Anthropic key in the environment.

- Allow only the youtrack-cli scripts the prompt uses.
- Force every comment from this run to be private, so it can't publish
  anything it read.
- Pass the dispatch input via env instead of interpolating it into `run:`.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 11:49:17 +01:00
1grzyb1andClaude Opus 5.5 a594a245c8 Fix(VIM-4350): Take GitHub write access away from the changelog Claude run
Claude reads untrusted text (PR comments, YouTrack tickets) while updating
the changelog, and its PRs were auto-merged, so a prompt injection could
reach master or leak secrets through `gh`.

- Claude can only edit CHANGES.md and use read-only git/gh commands; the
  push token is not persisted in .git/config.
- A separate step opens the PR with GITHUB_TOKEN only if CHANGES.md is the
  only changed file, dispatches PR verification for it and enables
  auto-merge.
- Remove mergeClaudeChangelogPR.yml, Claude no longer opens these PRs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 11:49:17 +01:00
1grzyb1andClaude Opus 5.5 186c2bf7f5 Fix(VIM-4350): Prevent shell injection and unchecked changelog auto-merge
- youtrackAutoAnalysis: pass step outputs (ticket summary, Claude-generated
  statuses and attention reasons) to run scripts via env instead of
  interpolating them into the script, so a crafted ticket summary can't
  execute shell commands on the runner.
- mergeClaudeChangelogPR: auto-merge only PRs that change CHANGES.md alone,
  and disable auto-merge if a later push touches other files.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 11:49:16 +01:00
1grzyb1andClaude Opus 5.5 3580099c61 Fix(VIM-4350): Restrict What's New Claude workflow to maintainers and allowed files
Anyone could open a fork PR with the What's New title and inject a prompt
via a comment into a Claude run with repository write access.

- Run only for OWNER/MEMBER/COLLABORATOR comments, and verify the PR head is
  JetBrains/ideavim:whatsnew-tbr and the commenter has write access.
- Claude can only edit whatsnew-tbr.html and CHANGES.md and has no
  commit/push access; the push token is not persisted in .git/config.
- A separate step pushes the edits only if no other files changed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 11:49:16 +01:00
1grzyb1 27aabf8301 VIM-4329 Fix k movement scrolling with so=9999
The sticky lines panel's height depends on the scroll position, so an exact middle doesn't always exist, and the old tolerance range let the previous position count as centred after every other k; instead, try the middle for each panel height we find and keep the closest position, staying put on a tie unless the caret moved to another line, so moves always scroll but typing never scrolls back and forth.
2026-10-27 11:40:44 +01:00
1grzyb1 e90c7779cc VIM-4346 Read Surround command asynchronously 2026-10-27 09:21:04 +01:00
1grzyb1 029be52277 Fix(VIM-2796): Finish the surround tag prompt with Enter
ModalEntry now reads keys before the keymap, because pressed Enter used to run the IdeaVim shortcut first and the tag regex required a closing `>`.
2026-10-27 09:21:04 +01:00
1grzyb1 d3a8a00223 VIM-4346 CommandLinePreview: Update preview logic
Extract command line preview logic
2026-10-27 09:21:04 +01:00
1grzyb1 87bd828e2d VIM-4346 new API to open ex entry panel
Now entry panel knows what type of action opened it and can perofrm opartions according to it's type
2026-10-27 09:21:04 +01:00
1grzyb1 0d4ca1d6f0 VIM-4346 don't trigger incsearch from input entry panel
When entry panel was exectued as inputStrin to receive user input it performed incsearch
2026-10-27 09:21:04 +01:00
claude[bot]andClaude Opus 5.5 3e0d977177 Add tests for blockwise shift left
ShiftLeftVisualAction had no coverage for the blockwise branch of
indentRange, while ShiftRight already tests it. Cover a block starting
at column 0 with a whitespace-only line shorter than the indent, and a
block starting mid-line where some lines are shorter than the block
column and must be left untouched.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 08:32:50 +01:00
claude[bot]andClaude Opus 5.5 4ca9f6f428 Update changelog: Fix modified ' and ` mappings
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-27 05:19:37 +00:00
1grzyb1 ea8e3bd1ae VIM-4349 parse ' and ` keycodes in mappings 2026-10-26 12:57:36 +01:00
1grzyb1 37cac8d930 VIM-2342 Don't open Ggrep matches twice in symlinked repositories
git rev-parse --show-toplevel resolves symlinks, so in /tmp on macOS matches pointed to /private/tmp and opened a second tab for files that were already open
2026-10-26 09:41:18 +01:00
1grzyb1 238a696594 VIM-2342 Document fugitive extension and quickfix commands 2026-10-26 09:41:18 +01:00
1grzyb1 94dc275719 VIM-2342 Allow cancelling a slow Ggrep
Ggrep shows a titled progress dialog, and cancelling it kills the git process instead of leaving it running
2026-10-26 09:41:18 +01:00
1grzyb1 8d9a16d995 VIM-2342 Add cclose command 2026-10-26 09:41:18 +01:00
1grzyb1 97ae43ee55 VIM-2342 Add copen command
Shows the quickfix list in a read-only window that follows the current item. Enter on a line jumps to that item in the window copen was run from
2026-10-26 09:41:18 +01:00
1grzyb1 712adc3093 VIM-2342 Implement cfirst and clast commands 2026-10-26 09:41:18 +01:00
1grzyb1 96d5ca8388 VIM-2342 Implement cpfile command 2026-10-26 09:41:18 +01:00
1grzyb1 3906c8f38f VIM-2342 Implement cnfile command 2026-10-26 09:41:18 +01:00
1grzyb1 57a6952543 VIM-2342 Keep quickfix list per project 2026-10-26 09:41:18 +01:00
1grzyb1 38926e7a3f VIM-2342 Remove unnecessary git version process call 2026-10-26 09:41:18 +01:00
1grzyb1 f1a8ae4789 VIM-2342 Add cprev command 2026-10-26 09:41:18 +01:00
1grzyb1 0f2d81233d VIM-2342 Add cnext to jump to next item in quickfix list
Ggrep works based on quickfix list and we didn't have implementation of that so we need to support it first
2026-10-26 09:41:18 +01:00
1grzyb1 78b82c395f VIM-2342 Add fugitive extension with grep command 2026-10-26 09:41:18 +01:00
1grzyb1andClaude Opus 5.5 27befce788 Drop dependencies on the removed Rhizome kernel modules
IJPL-257728 removed intellij.platform.kernel, kernel.impl and kernel.backend
from the platform. On builds from master, IdeaVIM.ideavim-backend and both
bookmark backend modules declared a dependency on intellij.platform.kernel.backend,
so the platform skipped them silently. None of the remoteApiProvider extensions
got registered, and Commentary, Format and the other RPC calls failed with
"No remote API found".

IdeaVim doesn't use any class from these modules. The backend-only loading in
split mode is still provided by the dependency on intellij.platform.backend.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 11:11:46 +02:00
claude[bot]andClaude Opus 5.5 10b7c94e68 Update changelog: Add <C-F> to open the command-line window
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 05:18:58 +00:00
IdeaVim Bot 5c6eca9034 Update help file 2026-10-21 10:04:26 +00:00
1grzyb1 0473fe0479 fix(VIM-2200): Keep the output of a command run from the command-line window
The platform reports the editor switch from closing the cmdwin only after the command has run, so redrawing for it closed the output the command had just shown.
2026-10-21 12:01:59 +02:00
1grzyb1 8a183c5159 VIM-2200 Open the command-line window with <C-F> from the command line
Editing a long command or search pattern is easier with Normal mode motions than in the one-line command line.
2026-10-21 12:01:59 +02:00
claude[bot]andClaude Opus 5.5 36ff0df8e4 Update changelog: Add clipboard autoselect, fix X11 middle-click paste and NERDTree speed search
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-21 05:22:04 +00:00
1grzyb1 516d384836 VIM-4269 speed search on popups with nerdtree
`/` action was running intelij SpeedSearch which didin;t work on popups. to make it work there also we find speedsearch component and activate this one directly
2026-10-20 09:56:52 +00:00
claude[bot]andClaude Opus 5.5 3c5cf41531 Unregister ToolWindowNav shortcut on dispose and hidden tool windows
ToolWindowNavEverywhere registered the <C-W> dispatcher on the focused tool
window component but never removed it from that component on dispose. After
disposing, the focus listener was gone too, so <C-W> stayed captured there.

The old focus owner was also unregistered only if it was still inside a
visible tool window. A tool window hidden while focused kept the shortcut.

Track the registered component, as EscEverywhere does, and unregister it on
every focus change and on dispose.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-20 08:53:30 +00:00
grzybek 1be3fc7af0 VIM-3113 support autoselect option
Add possibility to disable pushing to primary register on selction change. Needed to disable platform primary publishing so mouse selection won't publish too.
2026-10-20 08:25:04 +00:00
grzybek f03d41e2fc VIM-1309 Don't move caret on middle paste in x11 2026-10-20 07:32:23 +00:00
claude[bot]andClaude Opus 5.5 731e6173dd Update changelog: Fix multiple-cursors I/A and langmap replay
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-20 05:21:14 +00:00
1grzyb1 d22e60e129 VIM-2374 I and A move to begginig/end of multi selection 2026-10-19 10:15:46 +00:00
Matt Ellis 50229dcc3b Fix incorrect langmap when replaying failed map 2026-10-19 07:39:55 +00:00
claude[bot]andClaude Opus 5.5 991dc57ad3 Update changelog: Fix scrolloff=999 and sticky lines issues
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 05:21:31 +00:00
1grzyb1 ee84325048 VIM-4329 restructure scrolling the caret into view
Decide between centring, scrolling up and scrolling down in one place, and keep how we measure the window, in lines or in pixels when block inlays take up most of it, in WindowLines
2026-10-16 11:58:14 +02:00
1grzyb1 1d78f779b2 VIM-4329 convert EditorHelper to Kotlin
Move the existing EditorHelper.kt top level functions to EditorHelperRt.kt, matching its JVM name, and group the scrolling code that adjusts for the sticky lines panel
2026-10-16 11:58:14 +02:00
1grzyb1 dbcb2187e6 VIM-3301 don't hide caret under sticky lines when scrolling up
Scrolling a line to the top of the screen can make the sticky lines panel taller, which hides the line. Scroll again for the new panel
2026-10-16 11:58:14 +02:00
1grzyb1 6a8d26d6b5 VIM-4329 keep scrolloff at top of screen with block inlays
When block inlays made the line count unreliable, scrolloff was only applied at the bottom of the screen, so the caret could reach the top line
2026-10-16 11:58:14 +02:00
1grzyb1 0784623421 VIM-4329 test scrolling with block inlays taking most of the screen
Cover scrolling up, down and below the screen when block inlays make the visible line count unreliable
2026-10-16 11:58:14 +02:00
1grzyb1 99ff550695 VIM-4329 fix scrolloff=999 behavior with cc
Don't scroll when moving cursor on cc
2026-10-16 11:58:14 +02:00
1grzyb1 44e38b0c5f VIM-4329 fix scrolloff=999 behavior with sticky lines 2026-10-16 11:58:14 +02:00
1grzyb1 c259d64079 VIM-4329 fix scrolloff=999 behavior with doc comments 2026-10-16 11:58:14 +02:00
claude[bot]andClaude Opus 5.5 b7e748803e Update changelog: Fix Enter and Esc in popups with no open file
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 05:16:55 +00:00