Skip to content

Latest commit

 

History

8 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SmartTrim

macOS menu bar utility that fixes mangled clipboard text from AI coding assistants.

You know the problem: you're deep in Claude Code, Cursor, or Copilot, copy some text, paste it into Slack or Notion, and it's full of ghost indentation, hard line breaks mid-sentence, and weird formatting artifacts.

SmartTrim sits in your menu bar and fixes it automatically.

smarttrim smarttrim-settings

Features

  • Auto-Trim — Monitors clipboard, automatically cleans malformed text
  • Manual Trim — Global hotkey (⌘⇧.) or menu bar button
  • Smart Detection — Only processes text that looks broken
  • Preserves Structure — Keeps lists, paragraphs, and intentional formatting

What It Fixes

Problem Example
Ghost indentation text with invisible leading spaces
Hard-wrapped lines This sentence was\nbroken mid-flow
Mixed formatting Bullet points with broken continuations

Install

Download from Releases or build from source:

brew install xcodegen
git clone https://github.com/gmickel/SmartTrim.git
cd SmartTrim
xcodegen && xcodebuild -scheme SmartTrim -configuration Release

Requirements

  • macOS 14.0 (Sonoma) or later
  • Apple Silicon or Intel

Settings

  • Launch at Login — Start automatically
  • Auto-Trim — Enable/disable clipboard monitoring
  • Hotkey — Customize the manual trim shortcut

Tech

Swift 6, SwiftUI, strict concurrency. No Electron. No dependencies. ~500 lines.

Author

Gordon Mickelmickel.tech

Origin

Built as part of gmickel-bench, a project comparing AI coding assistants on real-world tasks.

License

MIT

About

macOS menu bar app that fixes mangled clipboard text from AI coding assistants. Removes ghost indentation, unwraps hard-wrapped lines, preserves lists.

Topics

Resources

Stars

4 stars

Watchers

0 watching

Forks

Releases

Sponsor this project

Packages

Contributors

Languages