rufio 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG.md +188 -0
  3. data/CHANGELOG_v0.4.0.md +146 -0
  4. data/CHANGELOG_v0.5.0.md +26 -0
  5. data/CHANGELOG_v0.6.0.md +182 -0
  6. data/CHANGELOG_v0.7.0.md +280 -0
  7. data/CHANGELOG_v0.8.0.md +267 -0
  8. data/CHANGELOG_v0.9.0.md +279 -0
  9. data/README.md +631 -0
  10. data/README_EN.md +561 -0
  11. data/Rakefile +156 -0
  12. data/bin/rufio +34 -0
  13. data/config_example.rb +88 -0
  14. data/docs/PLUGIN_GUIDE.md +431 -0
  15. data/docs/plugin_example.rb +119 -0
  16. data/lib/rufio/application.rb +32 -0
  17. data/lib/rufio/bookmark.rb +115 -0
  18. data/lib/rufio/bookmark_manager.rb +173 -0
  19. data/lib/rufio/color_helper.rb +150 -0
  20. data/lib/rufio/command_mode.rb +72 -0
  21. data/lib/rufio/command_mode_ui.rb +168 -0
  22. data/lib/rufio/config.rb +199 -0
  23. data/lib/rufio/config_loader.rb +110 -0
  24. data/lib/rufio/dialog_renderer.rb +127 -0
  25. data/lib/rufio/directory_listing.rb +113 -0
  26. data/lib/rufio/file_opener.rb +140 -0
  27. data/lib/rufio/file_operations.rb +231 -0
  28. data/lib/rufio/file_preview.rb +200 -0
  29. data/lib/rufio/filter_manager.rb +114 -0
  30. data/lib/rufio/health_checker.rb +246 -0
  31. data/lib/rufio/keybind_handler.rb +828 -0
  32. data/lib/rufio/logger.rb +103 -0
  33. data/lib/rufio/plugin.rb +89 -0
  34. data/lib/rufio/plugin_config.rb +59 -0
  35. data/lib/rufio/plugin_manager.rb +84 -0
  36. data/lib/rufio/plugins/file_operations.rb +44 -0
  37. data/lib/rufio/selection_manager.rb +79 -0
  38. data/lib/rufio/terminal_ui.rb +630 -0
  39. data/lib/rufio/text_utils.rb +108 -0
  40. data/lib/rufio/version.rb +5 -0
  41. data/lib/rufio/zoxide_integration.rb +188 -0
  42. data/lib/rufio.rb +33 -0
  43. data/publish_gem.zsh +131 -0
  44. data/rufio.gemspec +40 -0
  45. data/test_delete/test1.txt +1 -0
  46. data/test_delete/test2.txt +1 -0
  47. metadata +189 -0
@@ -0,0 +1,279 @@
1
+ # CHANGELOG - rufio v0.9.0
2
+
3
+ **Release Date**: 2024-12-13
4
+
5
+ ## ๐Ÿš€ New Features
6
+
7
+ ### Command Mode Input Floating Window
8
+
9
+ - **Floating Window for Command Input**: Command mode input now displays in a modern floating window
10
+ - Moved from bottom line to centered floating window
11
+ - Consistent with other UI elements (bookmarks, results)
12
+ - Blue border for clear visual identification
13
+ - Always-visible keyboard shortcuts help text
14
+
15
+ - **Integrated Completion Suggestions**: Tab completion suggestions display directly in the input window
16
+ - Real-time suggestion list updates as you type
17
+ - Clear visual separation between input and suggestions
18
+ - No need to guess available commands
19
+
20
+ - **Enhanced Visual Feedback**:
21
+ - Input prompt with cursor indicator
22
+ - Automatic window sizing based on content
23
+ - Clean, uncluttered interface
24
+ - Professional appearance matching rufio's design language
25
+
26
+ ### CommandModeUI Enhancements
27
+
28
+ - **New Method** (`show_input_prompt`): Displays command input in floating window
29
+ - `show_input_prompt(input, suggestions)`: Shows input prompt with optional completion suggestions
30
+ - Automatic integration with TerminalUI
31
+ - Consistent color scheme (blue border, white content)
32
+
33
+ ## ๐ŸŽจ UI/UX Improvements
34
+
35
+ ### Modern Command Input Experience
36
+
37
+ Before (v0.8.0):
38
+ ```
39
+ [File listing...]
40
+ [Footer...]
41
+ :helloโ–ˆ โ† Input at bottom of screen
42
+ ```
43
+
44
+ After (v0.9.0):
45
+ ```
46
+ [File listing centered behind floating window...]
47
+
48
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
49
+ โ”‚ ใ‚ณใƒžใƒณใƒ‰ใƒขใƒผใƒ‰ โ”‚ (Blue)
50
+ โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
51
+ โ”‚ โ”‚
52
+ โ”‚ hello_ โ”‚
53
+ โ”‚ โ”‚
54
+ โ”‚ ่ฃœๅฎŒๅ€™่ฃœ: โ”‚
55
+ โ”‚ hello โ”‚
56
+ โ”‚ help โ”‚
57
+ โ”‚ health โ”‚
58
+ โ”‚ โ”‚
59
+ โ”‚ Tab: ่ฃœๅฎŒ | Enter: ๅฎŸ่กŒ | ESC: ใ‚ญใƒฃใƒณใ‚ปใƒซ โ”‚
60
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
61
+ ```
62
+
63
+ ### Key Improvements
64
+
65
+ - **Centered Display**: Input window appears in screen center for better focus
66
+ - **Contextual Help**: Keyboard shortcuts always visible
67
+ - **Live Suggestions**: Completion suggestions update in real-time
68
+ - **Consistent Design**: Matches bookmark and result windows
69
+ - **No Screen Clutter**: Floating window doesn't interfere with file listing
70
+
71
+ ## ๐Ÿ”ง Technical Improvements
72
+
73
+ ### Architecture
74
+
75
+ - **Removed Legacy Methods**:
76
+ - Removed `draw_command_input`: Bottom-line input rendering (obsolete)
77
+ - Removed `draw_command_result`: Bottom-line result display (obsolete)
78
+ - Cleaner codebase with focused responsibilities
79
+
80
+ - **TextUtils Enhancement**:
81
+ - Added Unicode ranges for box drawing characters (\u2500-\u257F)
82
+ - Added Unicode ranges for block elements (\u2580-\u259F)
83
+ - Improved width calculation for special characters
84
+
85
+ ### Integration
86
+
87
+ - **Automatic Display**: Command mode floating window shows automatically when activated
88
+ - **Suggestion Integration**: Autocomplete suggestions fetched and displayed seamlessly
89
+ - **Screen Refresh**: Proper screen redraw after command execution
90
+
91
+ ## ๐Ÿ› Bug Fixes
92
+
93
+ ### Display Width Issues
94
+
95
+ - **Fixed Cursor Symbol Display**: Changed from โ–ˆ (full-width block) to _ (half-width underscore)
96
+ - Resolved right border misalignment in command input window
97
+ - Full-width block characters (โ–ˆ) have ambiguous width in different terminals
98
+ - Underscore (_) ensures consistent width across all terminal emulators
99
+
100
+ - **Improved Character Width Detection**:
101
+ - Added support for box drawing characters in TextUtils
102
+ - Added support for block elements in TextUtils
103
+ - More accurate display width calculation
104
+
105
+ - **Removed Colon Prefix**: Removed redundant `:` from input display
106
+ - Window title already indicates "ใ‚ณใƒžใƒณใƒ‰ใƒขใƒผใƒ‰"
107
+ - Cleaner, less cluttered appearance
108
+
109
+ ## ๐Ÿงช Testing
110
+
111
+ ### Test-Driven Development
112
+
113
+ - **TDD Approach**: All features developed following strict TDD methodology
114
+ 1. Wrote comprehensive tests first (4 new tests)
115
+ 2. Verified tests failed as expected
116
+ 3. Implemented features to pass tests
117
+ 4. Committed tests before implementation
118
+
119
+ ### New Tests Added
120
+
121
+ - **Command Input Floating Window Tests** (`test/test_command_mode_ui.rb`):
122
+ - `test_show_input_prompt_basic`: Basic input prompt display
123
+ - `test_show_input_prompt_empty_input`: Empty input handling
124
+ - `test_show_input_prompt_with_suggestions`: Suggestions display
125
+ - `test_show_input_prompt_color`: Border color verification
126
+
127
+ ### Test Coverage
128
+
129
+ - **20 tests, 60 assertions**: Comprehensive coverage of CommandModeUI
130
+ - **261 total tests, 1137 assertions**: Full test suite
131
+ - **All tests passing**: 100% success rate
132
+
133
+ ## ๐Ÿ“ฆ Dependencies
134
+
135
+ ### No New Dependencies
136
+
137
+ - Uses existing Ruby standard library
138
+ - Leverages existing rufio components:
139
+ - `DialogRenderer`: For floating window rendering
140
+ - `CommandMode`: For command execution
141
+ - `TextUtils`: For text width calculations
142
+
143
+ ## ๐Ÿ”„ Compatibility
144
+
145
+ ### Backward Compatibility
146
+
147
+ - **No Breaking Changes**: All existing features work as before
148
+ - **Enhanced UI**: Command mode now has better UX without changing functionality
149
+ - **Existing Keybindings Preserved**: `:` still activates command mode
150
+
151
+ ### Platform Support
152
+
153
+ - **macOS**: Full support โœ…
154
+ - **Linux**: Full support โœ…
155
+ - **Windows**: Full support โœ…
156
+
157
+ ## โšก Performance
158
+
159
+ ### Optimizations
160
+
161
+ - **No Performance Impact**: Floating window rendering is fast and efficient
162
+ - **Cached Calculations**: Window dimensions calculated once per render
163
+ - **Minimal Overhead**: Features only active when command mode is engaged
164
+
165
+ ## ๐Ÿ“ Usage Examples
166
+
167
+ ### Using the New Command Input
168
+
169
+ ```bash
170
+ # Launch rufio
171
+ rufio
172
+
173
+ # Activate command mode
174
+ Press ':'
175
+
176
+ # Floating window appears in center:
177
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
178
+ โ”‚ ใ‚ณใƒžใƒณใƒ‰ใƒขใƒผใƒ‰ โ”‚
179
+ โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
180
+ โ”‚ โ”‚
181
+ โ”‚ _ โ”‚
182
+ โ”‚ โ”‚
183
+ โ”‚ Tab: ่ฃœๅฎŒ | Enter: ๅฎŸ่กŒ | ESC: ใ‚ญใƒฃใƒณใ‚ปใƒซ โ”‚
184
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
185
+
186
+ # Type partial command
187
+ Type "he"
188
+
189
+ # Window updates with suggestions:
190
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
191
+ โ”‚ ใ‚ณใƒžใƒณใƒ‰ใƒขใƒผใƒ‰ โ”‚
192
+ โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
193
+ โ”‚ โ”‚
194
+ โ”‚ he_ โ”‚
195
+ โ”‚ โ”‚
196
+ โ”‚ ่ฃœๅฎŒๅ€™่ฃœ: โ”‚
197
+ โ”‚ hello โ”‚
198
+ โ”‚ help โ”‚
199
+ โ”‚ health โ”‚
200
+ โ”‚ โ”‚
201
+ โ”‚ Tab: ่ฃœๅฎŒ | Enter: ๅฎŸ่กŒ | ESC: ใ‚ญใƒฃใƒณใ‚ปใƒซ โ”‚
202
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
203
+
204
+ # Press Tab to complete
205
+ # Press Enter to execute
206
+ # Press ESC to cancel
207
+ ```
208
+
209
+ ### Visual Improvements
210
+
211
+ **Before (v0.8.0)**: Input at bottom of screen, suggestions not visible
212
+ **After (v0.9.0)**: Input in centered floating window, suggestions always visible
213
+
214
+ ## ๐Ÿ”ฎ Future Plans
215
+
216
+ ### Planned Enhancements
217
+
218
+ - **Command History**: Navigate through previously executed commands with โ†‘/โ†“ arrows
219
+ - **Command Arguments**: Support for commands with parameters
220
+ - **Auto-complete Menu**: Visual menu showing all available completions
221
+ - **Command Aliases**: User-defined shortcuts for frequently used commands
222
+ - **Inline Help**: Show command descriptions during completion
223
+
224
+ ## ๐Ÿ™ Acknowledgments
225
+
226
+ Main contributions in this version:
227
+
228
+ - **Test-Driven Development**: Strict TDD methodology ensuring code quality
229
+ - **Consistent UI/UX**: Unified floating window design across all features
230
+ - **User Experience Focus**: Improved command discoverability and feedback
231
+ - **Cross-platform Compatibility**: Cursor symbol fix for all terminal emulators
232
+
233
+ ## ๐Ÿ“‹ Detailed Changes
234
+
235
+ ### Files Modified
236
+
237
+ - `lib/rufio/command_mode_ui.rb`:
238
+ - Added `show_input_prompt` method
239
+ - Removed obsolete display code
240
+ - `lib/rufio/terminal_ui.rb`:
241
+ - Integrated floating window for command input
242
+ - Removed `draw_command_input` method
243
+ - Removed `draw_command_result` method
244
+ - `lib/rufio/text_utils.rb`:
245
+ - Enhanced character width detection
246
+ - Added box drawing and block element ranges
247
+ - `test/test_command_mode_ui.rb`:
248
+ - Added 4 new tests for input prompt display
249
+
250
+ ### Files Created
251
+
252
+ - None (all changes to existing files)
253
+
254
+ ### Lines of Code
255
+
256
+ - **Added**: ~50 lines (implementation)
257
+ - **Modified**: ~10 lines
258
+ - **Removed**: ~30 lines (obsolete methods)
259
+ - **Net Change**: ~30 lines added
260
+
261
+ ### Commit History
262
+
263
+ ```
264
+ 478971b fix: ใ‚ซใƒผใ‚ฝใƒซ่จ˜ๅทใ‚’โ–ˆใ‹ใ‚‰_ใซๅค‰ๆ›ดใ—ใฆ่กจ็คบๅดฉใ‚Œใ‚’ไฟฎๆญฃ
265
+ d09831f fix: ็ฝซ็ทšๆ–‡ๅญ—ใจใƒ–ใƒญใƒƒใ‚ฏ่ฆ็ด ใฎ่กจ็คบๅน…ใ‚’ไฟฎๆญฃ
266
+ 2ba2785 refactor: ใ‚ณใƒžใƒณใƒ‰ใƒขใƒผใƒ‰ๅ…ฅๅŠ›ใ‹ใ‚‰ใ‚ณใƒญใƒณใ‚’ๅ‰Š้™ค
267
+ f89693a feat: ใ‚ณใƒžใƒณใƒ‰ๅ…ฅๅŠ›ใ‚’ใƒ•ใƒญใƒผใƒ†ใ‚ฃใƒณใ‚ฐใ‚ฆใ‚ฃใƒณใƒ‰ใ‚ฆใซๅค‰ๆ›ด
268
+ 3ab01af test: ใ‚ณใƒžใƒณใƒ‰ๅ…ฅๅŠ›ใƒ•ใƒญใƒผใƒ†ใ‚ฃใƒณใ‚ฐใ‚ฆใ‚ฃใƒณใƒ‰ใ‚ฆใฎใƒ†ใ‚นใƒˆใ‚’่ฟฝๅŠ 
269
+ ```
270
+
271
+ ## ๐ŸŽฏ Summary
272
+
273
+ Version 0.9.0 brings a significant UI/UX improvement to command mode by introducing a modern floating window interface for command input. This change provides better visual feedback, integrates completion suggestions directly into the input window, and maintains consistency with other rufio features. All changes were developed using TDD methodology and are fully tested with 100% test pass rate.
274
+
275
+ ---
276
+
277
+ **Note**: This version focuses on UI/UX polish and consistency. The command mode functionality remains the same, but the user experience is significantly enhanced with the new floating window interface.
278
+
279
+ **GitHub Issues**: [https://github.com/masisz/rufio/issues](https://github.com/masisz/rufio/issues)