<feed xmlns='http://www.w3.org/2005/Atom'>
<title>dotemacs/modules/custom-buffer-file.el, branch lkg</title>
<subtitle>My Emacs configuration
</subtitle>
<id>https://git.cjennings.net/dotemacs/atom?h=lkg</id>
<link rel='self' href='https://git.cjennings.net/dotemacs/atom?h=lkg'/>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/'/>
<updated>2025-11-09T21:31:41+00:00</updated>
<entry>
<title>feat:buffer-diff: Add syntax-aware buffer diffing with difftastic</title>
<updated>2025-11-09T21:31:41+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-09T21:31:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=8b39650aca87cd619b09deb683cb58f5a420f623'/>
<id>urn:sha1:8b39650aca87cd619b09deb683cb58f5a420f623</id>
<content type='text'>
Introduce enhanced buffer comparison with saved file using difftastic
for syntax-aware diffing, with a fallback to regular unified diff if
difftastic is unavailable. Output is displayed in separate buffers,
leveraging ansi-color for improved readability. Also includes
comprehensive integration tests covering the diff workflow, handling
cases like added, removed, and modified lines, and ensuring graceful
handling of special cases and errors.
</content>
</entry>
<entry>
<title>feat: Upgrade diff-buffer-with-file to ediff and add difftastic for git</title>
<updated>2025-11-03T22:10:13+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-03T22:10:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=622f36660eabd850f9953b24b25ae4df04e9d38f'/>
<id>urn:sha1:622f36660eabd850f9953b24b25ae4df04e9d38f</id>
<content type='text'>
Two improvements for better diff experience:

1. **Upgraded cj/diff-buffer-with-file to use ediff** (custom-buffer-file.el)
   - Replaced basic unified diff with ediff-current-file
   - Now uses existing ediff config (horizontal split, j/k navigation)
   - C-; b D now launches interactive ediff instead of text diff
   - Simplified from 17 lines to 5 lines
   - Removed TODO comment about difftastic integration

2. **Added difftastic for git diffs** (vc-config.el)
   - Installed binary: difftastic 0.64.0 via pacman
   - Added difftastic.el package integrated with magit
   - Keybindings in magit-diff:
     - D → difftastic-magit-diff (dwim)
     - S → difftastic-magit-show
   - Provides structural, language-aware diffs for git changes
   - Better visualization of code structure changes

**Result:**
- Buffer vs file: Interactive ediff (can navigate, merge, revert)
- Git history: Structural difftastic (language-aware visualization)
- Right tool for each job

Serves Method 3: "Make Fixing Emacs Frictionless"
- Better diffs = easier debugging and code review

Updated todo.org: Method 1 progress 7/13 (was 5/13)
</content>
</entry>
<entry>
<title>fix: Swap print keybinding and add confirmation prompt</title>
<updated>2025-11-03T19:29:56+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-03T19:29:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=a1025d5d5c2a76f47eedb38f519b915ffcc49e4d'/>
<id>urn:sha1:a1025d5d5c2a76f47eedb38f519b915ffcc49e4d</id>
<content type='text'>
Print operations are now safer and more intuitive:

Keybinding changes:
- C-; b p → copy file path (safe, common action)
- C-; b P → print to PostScript (dramatic, requires shift)

Print function improvements:
- Add y-or-n-p confirmation before printing
- C-u prefix skips confirmation and enables color printing
- Prevents accidental waste of paper/toner

Serves V2MOM Values:
- Intuitive: Dramatic actions require shift key
- Intuitive: Prevents muscle memory mistakes
- Simple: Reliability through confirmation

Also updated docs/NOTES.org with Makefile availability note.

Closes inbox items from emacs-inbox-zero session (2025-11-03).
</content>
</entry>
<entry>
<title>feat: Add copy-to-top and copy-to-bottom buffer methods with tests</title>
<updated>2025-11-03T18:58:50+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-03T18:58:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=4ef5c963b243926ca62226632b2eb02b18274ae0'/>
<id>urn:sha1:4ef5c963b243926ca62226632b2eb02b18274ae0</id>
<content type='text'>
Add two new methods to copy buffer content regions:
- cj/copy-to-bottom-of-buffer: copies from point to end of buffer
- cj/copy-to-top-of-buffer: copies from beginning of buffer to point

Reorganize copy operations under C-; b c submenu:
- C-; b c w: copy whole buffer
- C-; b c t: copy to top (beginning to point)
- C-; b c b: copy to bottom (point to end)

Other copy operations (buffer name, file path, file link) remain at
C-; b base level for quick access.

Add comprehensive ERT tests (22 tests total):
- test-custom-buffer-file-copy-to-bottom-of-buffer.el (11 tests)
- test-custom-buffer-file-copy-to-top-of-buffer.el (11 tests)
- Tests cover normal, boundary, and error cases including unicode,
  narrowing, whitespace, and read-only buffers

All tests pass.
</content>
</entry>
<entry>
<title>feat:buffer: Add diffing buffer contents with saved file</title>
<updated>2025-11-01T17:56:12+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-11-01T17:56:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=d60a3d3ff2d481d00369b6bb3a0cbd6e2a95c542'/>
<id>urn:sha1:d60a3d3ff2d481d00369b6bb3a0cbd6e2a95c542</id>
<content type='text'>
Introduce a new function `cj/diff-buffer-with-file` to compare
current buffer with saved file version using unified diff format.
Bind it to "C-; b D" for easy access. This enhances buffer
management capabilities by allowing users to view changes before
saving.
</content>
</entry>
<entry>
<title>feat:custom-buffer-file: add mark, revert buffer keybindings</title>
<updated>2025-10-31T10:55:28+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-10-31T10:54:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=908c4e45c20e3f16832dfa1252f5f01741406858'/>
<id>urn:sha1:908c4e45c20e3f16832dfa1252f5f01741406858</id>
<content type='text'>
Added new keybindings for marking the whole buffer and reverting the
buffer. Updated the descriptions to reflect these additions.
</content>
</entry>
<entry>
<title>refactor: Rename custom-file-buffer to custom-buffer-file</title>
<updated>2025-10-28T02:05:06+00:00</updated>
<author>
<name>Craig Jennings</name>
<email>c@cjennings.net</email>
</author>
<published>2025-10-28T02:05:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.cjennings.net/dotemacs/commit/?id=d77ca19cf7106a0eecbff1588c13b8b52b98b85f'/>
<id>urn:sha1:d77ca19cf7106a0eecbff1588c13b8b52b98b85f</id>
<content type='text'>
Renamed the module 'custom-file-buffer' to 'custom-buffer-file' to
ensure consistency across the codebase. This change affects module
imports and test files. Additionally, new module
'system-commands.el' has been created to handle system power and
session management commands, removing these functionalities from
'wip.el'.
</content>
</entry>
</feed>
