Version
codebase-memory-mcp 0.8.1
Platform
Windows 10 x64
Install channel
GitHub release archive / install.sh / install.ps1
Binary variant
standard
What happened, and what did you expect?
Summary
On Windows, installing codebase-memory-mcp creates extensionless hook files under:
%USERPROFILE%\.claude\hooks
Example:
cbm-code-discovery-gate
cbm-session-reminder
These files are Bash scripts (#!/bin/bash) without any executable extension.
When Cursor starts a new Agent, it scans the Claude hooks directory.
When Cursor starts a new Agent, the Windows "How do you want to open this file?" dialog appears.
Selecting Cursor opens one of the hook files (for example cbm-session-reminder) in the editor.
Removing or renaming %USERPROFILE%\.claude\hooks immediately eliminates the issue.
Environment
- OS: Windows 10 x64
- Cursor: 3.10.17
- codebase-memory-mcp: 0.8.1
- Claude Code: Not installed / Not used
Steps to reproduce
- Install
codebase-memory-mcp on Windows using the installer.
- Verify that the installer creates:
%USERPROFILE%\.claude\hooks\
containing extensionless Bash scripts.
- Open Cursor.
- Create a new Agent.
Expected behavior
If Claude Code is not installed or the platform is Windows:
- do not install Bash hook files
- or install Windows-compatible hooks (
.cmd / .ps1)
- or skip Claude hook installation entirely.
No OpenWith dialog should appear.
Actual behavior
Windows opens:
How do you want to open this file?
If Cursor is selected, the hook source file itself is opened in the editor.
For example:
- cbm-code-discovery-gate
- cbm-session-reminder
Suspected cause
The installer creates extensionless Bash hook files under %USERPROFILE%\.claude\hooks.
These files appear to trigger the OpenWith dialog during Cursor Agent startup on Windows.
I cannot say whether the underlying bug is in Cursor or in the installer, but the problem disappears as soon as the hook directory is removed or renamed.
Workaround
Renaming either of these fixes the issue immediately:
or
%USERPROFILE%\.claude\hooks
Since I do not use Claude Code, disabling the directory completely resolves the problem.
Suggestion
The Windows installer should detect the platform and either:
- skip Claude hook installation,
- generate Windows-native hook files,
- or only install Claude hooks if Claude Code is actually installed.
Reproduction
-
Install codebase-memory-mcp on Windows using the official installer.
-
Ensure the installer creates hook files under:
%USERPROFILE%.claude\hooks
such as:
- cbm-code-discovery-gate
- cbm-session-reminder
-
Open Cursor.
-
Open any project.
-
Click New Agent (or start a new Agent session).
-
Windows immediately displays the "How do you want to open this file?" dialog.
-
If "Cursor" is selected in the dialog, Cursor opens the hook file itself (for example cbm-session-reminder) instead of continuing normally.
-
Rename either:
%USERPROFILE%.claude
or
%USERPROFILE%.claude\hooks
-
Restart Cursor.
-
Create another new Agent.
-
The OpenWith dialog no longer appears.
Logs
Diagnostics trajectory (memory / performance / leak issues)
Project scale (if relevant)
No response
Confirmations
Version
codebase-memory-mcp 0.8.1
Platform
Windows 10 x64
Install channel
GitHub release archive / install.sh / install.ps1
Binary variant
standard
What happened, and what did you expect?
Summary
On Windows, installing
codebase-memory-mcpcreates extensionless hook files under:Example:
These files are Bash scripts (
#!/bin/bash) without any executable extension.When Cursor starts a new Agent, it scans the Claude hooks directory.
When Cursor starts a new Agent, the Windows "How do you want to open this file?" dialog appears.
Selecting Cursor opens one of the hook files (for example
cbm-session-reminder) in the editor.Removing or renaming
%USERPROFILE%\.claude\hooksimmediately eliminates the issue.Environment
Steps to reproduce
codebase-memory-mcpon Windows using the installer.containing extensionless Bash scripts.
Expected behavior
If Claude Code is not installed or the platform is Windows:
.cmd/.ps1)No OpenWith dialog should appear.
Actual behavior
Windows opens:
If Cursor is selected, the hook source file itself is opened in the editor.
For example:
Suspected cause
The installer creates extensionless Bash hook files under
%USERPROFILE%\.claude\hooks.These files appear to trigger the OpenWith dialog during Cursor Agent startup on Windows.
I cannot say whether the underlying bug is in Cursor or in the installer, but the problem disappears as soon as the hook directory is removed or renamed.
Workaround
Renaming either of these fixes the issue immediately:
or
Since I do not use Claude Code, disabling the directory completely resolves the problem.
Suggestion
The Windows installer should detect the platform and either:
Reproduction
Install
codebase-memory-mcpon Windows using the official installer.Ensure the installer creates hook files under:
%USERPROFILE%.claude\hooks
such as:
Open Cursor.
Open any project.
Click New Agent (or start a new Agent session).
Windows immediately displays the "How do you want to open this file?" dialog.
If "Cursor" is selected in the dialog, Cursor opens the hook file itself (for example
cbm-session-reminder) instead of continuing normally.Rename either:
%USERPROFILE%.claude
or
%USERPROFILE%.claude\hooks
Restart Cursor.
Create another new Agent.
The OpenWith dialog no longer appears.
Logs
Diagnostics trajectory (memory / performance / leak issues)
Project scale (if relevant)
No response
Confirmations