Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,14 @@

All notable changes to this project will be documented in this file.

## [Unreleased]
## [0.0.3]

### Fixed
- Fix line number reporting when narrowing is in effect

## [0.0.2]

### Added
- Option to disable diff tools entirely by setting `monet-diff-tool` to `nil`
- Option to disable diff tools entirely by setting `monet-diff-tool` to `nil`
- When disabled, Claude uses its built-in diff display instead of creating diff views in Emacs
- Diff-related MCP tools (`openDiff` and `closeAllDiffTabs`) are conditionally excluded from the tools list
- Diff-related MCP tools (`openDiff` and `closeAllDiffTabs`) are conditionally excluded from the tools list
16 changes: 9 additions & 7 deletions monet.el
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
;;; monet.el --- Claude Code MCP over websockets -*- lexical-binding:t -*-

;; Author: Stephen Molitor <stevemolitor@gmail.com>
;; Version: 0.0.2
;; Version: 0.0.3
;; Package-Requires: ((emacs "30.0") (websocket "1.15"))
;; Keywords: tools, ai
;; URL: https://github.com/stevemolitor/monet
Expand Down Expand Up @@ -1202,8 +1202,8 @@ This is called from `post-command-hook'."
(text (if (or (use-region-p) in-evil-visual-line)
(buffer-substring-no-properties adjusted-start-pos adjusted-end-pos)
""))
(start-line (1- (line-number-at-pos adjusted-start-pos)))
(end-line (1- (line-number-at-pos adjusted-end-pos)))
(start-line (1- (line-number-at-pos adjusted-start-pos t)))
(end-line (1- (line-number-at-pos adjusted-end-pos t)))
(start-col (save-excursion
(goto-char adjusted-start-pos)
(current-column)))
Expand Down Expand Up @@ -1325,7 +1325,8 @@ Returns the window displaying the diff buffer."
(when tab
(alist-get 'name tab)))))
(current-frame (selected-frame))
(display-action '((display-buffer-pop-up-window))))
(display-action '((display-buffer-pop-up-window)
(inhibit-same-window . t))))

;; Check if we should skip display due to do-not-disturb mode
(cond
Expand All @@ -1341,7 +1342,8 @@ Returns the window displaying the diff buffer."
;; If we have an originating tab, try to display in that tab
(originating-tab
(display-buffer diff-buffer `((display-buffer-in-tab display-buffer-pop-up-window)
(tab-name . ,originating-tab))))
(tab-name . ,originating-tab)
(inhibit-same-window . t))))
;; No tab context, use default behavior
(t
(display-buffer diff-buffer display-action)))))
Expand Down Expand Up @@ -1798,8 +1800,8 @@ If URI is nil, gets diagnostics for all open files."
(end (flymake-diagnostic-end diag))
(type (flymake-diagnostic-type diag))
(text (flymake-diagnostic-text diag))
(start-line (1- (line-number-at-pos beg)))
(end-line (1- (line-number-at-pos end)))
(start-line (1- (line-number-at-pos beg t)))
(end-line (1- (line-number-at-pos end t)))
(start-char (save-excursion
(goto-char beg)
(current-column)))
Expand Down