{"id":31101153,"url":"https://github.com/adriangalilea/printer","last_synced_at":"2026-05-17T00:38:38.992Z","repository":{"id":309438156,"uuid":"1036274327","full_name":"adriangalilea/printer","owner":"adriangalilea","description":"TUI print queue manager for macOS","archived":false,"fork":false,"pushed_at":"2025-08-11T23:29:22.000Z","size":42,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-08-11T23:31:07.360Z","etag":null,"topics":["bubbletea","cups","golang","macos","print-queue","printer","printer-management","terminal-ui","tui"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/adriangalilea.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-08-11T20:32:59.000Z","updated_at":"2025-08-11T23:29:23.000Z","dependencies_parsed_at":"2025-08-11T23:41:20.682Z","dependency_job_id":null,"html_url":"https://github.com/adriangalilea/printer","commit_stats":null,"previous_names":["adriangalilea/printer"],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/adriangalilea/printer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adriangalilea%2Fprinter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adriangalilea%2Fprinter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adriangalilea%2Fprinter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adriangalilea%2Fprinter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/adriangalilea","download_url":"https://codeload.github.com/adriangalilea/printer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adriangalilea%2Fprinter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":275506556,"owners_count":25477213,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-16T02:00:10.229Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bubbletea","cups","golang","macos","print-queue","printer","printer-management","terminal-ui","tui"],"created_at":"2025-09-16T23:55:11.185Z","updated_at":"2026-05-17T00:38:38.985Z","avatar_url":"https://github.com/adriangalilea.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Printer 🖨️\n\nA sophisticated TUI (Terminal User Interface) for managing print queues on macOS, built with Go and [Bubble Tea](https://github.com/charmbracelet/bubbletea).\n\n## Features\n\n### 📊 Queue Management\n- **Real-time monitoring** of system print queue with automatic refresh\n- **Batch operations** for canceling multiple jobs\n- **Job details** including file names, sizes, and status\n- **Quick actions** to open files or their containing folders\n\n### 📁 Advanced File Browser\n- **Dual-pane interface** with keyboard-driven navigation\n- **Smart file detection** automatically identifies printable formats (PDF, DOC, images)\n- **Glob pattern matching** for filtering files (e.g., `*.pdf`, `report-*.doc`)\n- **Directory navigation** with arrow keys or vim bindings\n- **Batch selection** with toggle-all functionality for printable files\n- **Visual indicators** distinguish directories 📁, printable files 📄, and regular files\n\n### 🎨 Responsive UI\n- **Adaptive layout** that scales to terminal size\n- **Focus indicators** with colored borders showing active pane\n- **Scroll support** for long file lists with position indicators\n- **Path display** showing current directory in file browser\n\n## Installation\n\n```bash\n# Clone and build\ngit clone https://github.com/adriangalilea/printer.git\ncd printer\nmake install  # Installs to ~/.local/bin\n```\n\nEnsure `~/.local/bin` is in your PATH.\n\n## Usage\n\n### Launch Modes\n\n```bash\n# Open queue manager\nprinter\n\n# Start in file picker with pattern\nprinter add ~/Documents/*.pdf\nprinter add \"~/reports/2024-*.pdf\"\n```\n\n### Keyboard Shortcuts\n\n#### Queue Mode\n| Key | Action |\n|-----|--------|\n| `a` | Add files (opens file browser) |\n| `o` | Open selected file |\n| `O` | Open file's folder |\n| `x` | Cancel selected job |\n| `X` | Cancel all marked jobs |\n| `Space` | Mark/unmark job |\n| `r` | Refresh queue |\n| `q` | Quit |\n\n#### File Browser Mode\n| Key | Action |\n|-----|--------|\n| `Tab` | Switch between input field and file list |\n| `↑/k` | Navigate up (moves to input when at top) |\n| `↓/j` | Navigate down (moves to files from input) |\n| `←/h/Backspace` | Go to parent directory |\n| `→/l` | Enter directory |\n| `Space` | Mark/unmark file (or toggle all) |\n| `Enter` | Add marked files / enter directory |\n| `Esc` | Return to queue |\n\n### File Pattern Matching\n\nThe input field supports glob patterns:\n- `*.pdf` - All PDFs in current directory\n- `report-*.doc` - All docs starting with \"report-\"\n- `**/*.pdf` - All PDFs recursively (if supported)\n\n## Architecture\n\n### Core Components\n\n- **main.go** - TUI application logic with Bubble Tea framework\n- **system.go** - System integration for print queue operations (`lp`, `lpq`, `cancel`)\n- **queue_render.go** - Print queue display with deduplication\n- **print_commands.go** - Async print job submission\n\n### How It Works\n\nCUPS is the single source of truth. When submitting jobs via `lp -t \"filename\"`, the filename is embedded as the job title. The app queries `lpq` which returns job IDs and filenames directly from CUPS - no local state needed.\n\n## Supported File Types\n\nAutomatically detected as printable:\n- Documents: `.pdf`, `.txt`, `.doc`, `.docx`\n- Images: `.jpg`, `.jpeg`, `.png`, `.gif`\n\n## Requirements\n\n- macOS (uses `lp`, `lpq`, `cancel` commands)\n- Go 1.19+ for building\n- CUPS printing system (standard on macOS)\n\n## Development\n\n```bash\n# Build\nmake build\n\n# Run without installing\nmake run\n\n# Clean build artifacts\nmake clean\n```\n\n## Technical Stack\n\n- **[Bubble Tea](https://github.com/charmbracelet/bubbletea)** - Terminal UI framework\n- **[Lip Gloss](https://github.com/charmbracelet/lipgloss)** - Style definitions for terminal layouts\n- **[Bubbles](https://github.com/charmbracelet/bubbles)** - TUI component library\n\n## License\n\nMIT\n\n## Author\n\nAdrian Galilea ([@adriangalilea](https://github.com/adriangalilea))","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadriangalilea%2Fprinter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadriangalilea%2Fprinter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadriangalilea%2Fprinter/lists"}