rtfm-filemanager 7.3.6 → 7.4.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.
@@ -0,0 +1,280 @@
1
+ # RTFM Configuration File Example
2
+ # Location: ~/.rtfm/conf
3
+ #
4
+ # This is a well-commented example configuration file for RTFM.
5
+ # Copy sections you want to ~/.rtfm/conf and customize.
6
+ #
7
+ # RTFM automatically saves bookmarks, tagged items, and history.
8
+ # Manual settings (like these) are preserved across sessions.
9
+
10
+ # ============================================================
11
+ # DISPLAY SETTINGS
12
+ # ============================================================
13
+
14
+ # Enable/disable file preview in right pane
15
+ # Toggle in RTFM: Press '-'
16
+ # true = Show file content, false = Faster navigation
17
+ @preview = true
18
+
19
+ # Enable/disable image display in terminal
20
+ # Toggle in RTFM: Press '_'
21
+ # Requires: w3m-img or Sixel-capable terminal
22
+ @showimage = true
23
+
24
+ # Enable/disable syntax highlighting in previews
25
+ # Toggle in RTFM: Press 'b'
26
+ # Requires: bat or batcat
27
+ @batuse = true
28
+
29
+ # Pane width ratio (2-7)
30
+ # Toggle in RTFM: Press 'w'
31
+ # 2 = Narrow left (20%), 5 = Balanced (50%), 7 = Wide left (70%)
32
+ @width = 5
33
+
34
+ # Border style (0-3)
35
+ # Toggle in RTFM: Press 'B'
36
+ # 0 = No borders, 1 = Right only, 2 = Both, 3 = Left only
37
+ @border = 2
38
+
39
+ # ============================================================
40
+ # FILE LIST OPTIONS
41
+ # ============================================================
42
+
43
+ # Show hidden files (files starting with .)
44
+ # Toggle in RTFM: Press 'a'
45
+ # "-a" = Show hidden, "" = Hide hidden
46
+ @lsall = ""
47
+
48
+ # Show long file info (ls -l format)
49
+ # Toggle in RTFM: Press 'A'
50
+ # true = Show permissions/owner/size, false = Name only
51
+ @lslong = false
52
+
53
+ # Sort order
54
+ # Toggle in RTFM: Press 'o'
55
+ # "" = Name, "-S" = Size, "-t" = Time, "-X" = Extension
56
+ @lsorder = ""
57
+
58
+ # Reverse/invert sort order
59
+ # Toggle in RTFM: Press 'i'
60
+ # "-r" = Reverse, "" = Normal
61
+ @lsinvert = ""
62
+
63
+ # Additional ls options (advanced)
64
+ # Example filters:
65
+ # @lsuser = "--ignore=*.tmp" # Ignore temp files
66
+ # @lsuser = "--ignore=node_modules" # Ignore node_modules
67
+ # @lsuser = "--group-directories-first" # Dirs before files
68
+ @lsuser = ""
69
+
70
+ # Filter by file extensions
71
+ # In RTFM: Press 'f'
72
+ # Examples: "txt", "pdf,png,jpg", "rb,py,js"
73
+ @lsfiles = ""
74
+
75
+ # ============================================================
76
+ # FILE OPERATIONS
77
+ # ============================================================
78
+
79
+ # Enable trash bin (move deleted items to ~/.rtfm/trash)
80
+ # Toggle in RTFM: Press 'Ctrl-d'
81
+ # true = Safe deletion with undo, false = Permanent deletion
82
+ @trash = true
83
+
84
+ # Use run-mailcap instead of xdg-open for opening files
85
+ # false = Use xdg-open (most distros), true = Use run-mailcap (Debian-style)
86
+ @runmailcap = false
87
+
88
+ # ============================================================
89
+ # COLORS
90
+ # ============================================================
91
+
92
+ # Bottom pane background color (256-color)
93
+ # Default: 238 (dark gray)
94
+ # Try: 234 (darker), 240 (lighter gray), 24 (blue)
95
+ @bottomcolor = 238
96
+
97
+ # Command mode background (when you press ':')
98
+ @cmdcolor = 24
99
+
100
+ # Ruby debug mode background (when you press '@')
101
+ @rubycolor = 52
102
+
103
+ # OpenAI chat mode background (when you press 'Ctrl-a')
104
+ @aicolor = 17
105
+
106
+ # Top bar background colors based on path matching
107
+ # Format: [["pattern", color], ["pattern", color], ["", default]]
108
+ # First match wins!
109
+ @topmatch = [
110
+ ["work", 165], # Blue background when path contains "work"
111
+ ["personal", 156], # Green for personal directories
112
+ ["projects", 220], # Yellow for projects
113
+ ["downloads", 196], # Red for downloads (caution zone!)
114
+ ["", 238] # Default gray (empty pattern matches everything)
115
+ ]
116
+
117
+ # ============================================================
118
+ # BOOKMARKS
119
+ # ============================================================
120
+ # These are auto-managed but you can edit them manually
121
+ # Set in RTFM: Press 'm' then a letter
122
+ # Jump in RTFM: Press "'" then a letter
123
+
124
+ @marks = {
125
+ "h" => ENV['HOME'], # Home directory
126
+ "d" => "#{ENV['HOME']}/Documents", # Documents
127
+ "D" => "#{ENV['HOME']}/Downloads", # Downloads
128
+ "p" => "#{ENV['HOME']}/projects", # Projects
129
+ "c" => "#{ENV['HOME']}/.config", # Config files
130
+ "w" => "#{ENV['HOME']}/work", # Work directory
131
+ # Add your own bookmarks here
132
+ }
133
+
134
+ # ============================================================
135
+ # HISTORY
136
+ # ============================================================
137
+ # Auto-managed by RTFM, but you can prepopulate
138
+
139
+ # Command history (press ':' to use)
140
+ @history = [
141
+ "git status",
142
+ "git log --oneline -10",
143
+ "ls -la",
144
+ ]
145
+
146
+ # Ruby debug history (press '@' to use)
147
+ @rubyhistory = [
148
+ "puts @selected",
149
+ "puts @tagged.inspect",
150
+ "puts @marks",
151
+ ]
152
+
153
+ # OpenAI chat history (press 'Ctrl-a' to use)
154
+ # Requires @ai key set below
155
+ @aihistory = [
156
+ "What does this code do?",
157
+ "Explain this file",
158
+ "Suggest improvements",
159
+ ]
160
+
161
+ # SSH connection history (press 'Ctrl-e' to use)
162
+ @sshhistory = [
163
+ "user@production.com:/var/www # Production server",
164
+ "admin@staging.com:/var/www # Staging",
165
+ "backup@backup.server:/backups # Backup server",
166
+ ]
167
+
168
+ # ============================================================
169
+ # DIRECTORY HASHES
170
+ # ============================================================
171
+ # Auto-managed when you press 'H' on a directory
172
+ # Stores cryptographic hashes for change detection
173
+
174
+ @hash = {}
175
+
176
+ # ============================================================
177
+ # INTERACTIVE PROGRAMS
178
+ # ============================================================
179
+ # Programs that need full terminal control (TUI apps)
180
+ # Add in RTFM: Press '+' and type program name
181
+ # Or prefix command with '§': `:§htop`
182
+
183
+ @interactive = "htop,vim,nvim,nano,emacs,less,more,ranger,mc,tmux,screen,mutt,irssi,weechat,top,iftop,iotop,nethogs,glances,bashtop,bpytop,ncdu,cmus,mocp,alsamixer,lynx,w3m,elinks,links,newsboat,nnn,lf,vifm,midnight-commander,tig,lazygit"
184
+
185
+ # Add your frequently used TUI programs to this list
186
+
187
+ # ============================================================
188
+ # OPENAI INTEGRATION
189
+ # ============================================================
190
+ # Get API key from: https://platform.openai.com/api-keys
191
+ # Features: 'I' for file descriptions, 'Ctrl-a' for chat
192
+
193
+ @ai = "" # Add your key: "sk-your-api-key-here"
194
+
195
+ # Alternative: Use environment variable
196
+ # export OPENAI_API_KEY="sk-..."
197
+
198
+ # ============================================================
199
+ # ADVANCED SETTINGS
200
+ # ============================================================
201
+
202
+ # w3mimgdisplay path (if non-standard location)
203
+ # @w3mimgdisplay = "/usr/lib/w3m/w3mimgdisplay"
204
+
205
+ # Custom bat command (if using different name)
206
+ # @bat = "batcat" # Ubuntu uses batcat instead of bat
207
+
208
+ # ============================================================
209
+ # TIPS & EXAMPLES
210
+ # ============================================================
211
+
212
+ # Fast navigation setup (no preview overhead):
213
+ # @preview = false
214
+ # @showimage = false
215
+ # @lslong = false
216
+
217
+ # Maximum information setup:
218
+ # @preview = true
219
+ # @showimage = true
220
+ # @lslong = true
221
+ # @lsall = "-a"
222
+ # @batuse = true
223
+
224
+ # Photographer workflow:
225
+ # @lsorder = "-t" # Sort by time (newest first)
226
+ # @showimage = true
227
+ # @width = 3 # Wide preview pane for images
228
+
229
+ # Developer workflow:
230
+ # @batuse = true # Syntax highlighting
231
+ # @lsall = "-a" # Show hidden files (.git, etc.)
232
+ # @trash = true # Safe deletion
233
+ # @marks = {
234
+ # "p" => "#{ENV['HOME']}/projects",
235
+ # "c" => "#{ENV['HOME']}/.config",
236
+ # "d" => "#{ENV['HOME']}/dotfiles"
237
+ # }
238
+
239
+ # ============================================================
240
+ # PERFORMANCE NOTES
241
+ # ============================================================
242
+
243
+ # For large directories (1000+ files):
244
+ # - Turn off preview: @preview = false
245
+ # - Turn off long info: @lslong = false
246
+ # - Navigate faster!
247
+
248
+ # For slow terminals/SSH:
249
+ # - Reduce pane updates: @preview = false
250
+ # - Simpler borders: @border = 0
251
+ # - No images: @showimage = false
252
+
253
+ # For image-heavy directories:
254
+ # - Preview persists during operations now (v7.3+)
255
+ # - First pass caches auto-oriented images
256
+ # - Subsequent passes are fast
257
+
258
+ # ============================================================
259
+ # UPDATING CONFIGURATION
260
+ # ============================================================
261
+
262
+ # After editing this file:
263
+ # 1. Save the file
264
+ # 2. In RTFM, press 'R' to reload
265
+ # 3. Or restart RTFM
266
+
267
+ # To save current RTFM state to config:
268
+ # Press 'W' in RTFM
269
+
270
+ # To backup your config:
271
+ # cp ~/.rtfm/conf ~/.rtfm/conf.backup
272
+
273
+ # ============================================================
274
+ # MORE INFORMATION
275
+ # ============================================================
276
+
277
+ # Man page: man rtfm
278
+ # Full docs: https://github.com/isene/RTFM/tree/main/docs
279
+ # Help in RTFM: Press '?'
280
+ # Issues: https://github.com/isene/RTFM/issues
data/man/rtfm.1 ADDED
@@ -0,0 +1,361 @@
1
+ .TH RTFM 1 "2025-11-03" "7.3.6" "Ruby Terminal File Manager"
2
+ .SH NAME
3
+ rtfm \- Ruby Terminal File Manager with advanced features
4
+ .SH SYNOPSIS
5
+ .B rtfm
6
+ .RI [ directory ]
7
+ .SH DESCRIPTION
8
+ .B RTFM
9
+ is a feature-rich terminal file manager written in pure Ruby. It provides syntax-highlighted file previews, inline image display, remote SSH/SFTP browsing, comprehensive undo system, OpenAI integration, and much more.
10
+
11
+ RTFM parses LS_COLORS for consistent terminal color theming and supports multiple image display protocols (Sixel, w3m) via the termpix gem.
12
+ .SH KEY FEATURES
13
+ .TP
14
+ .B File Operations
15
+ Copy, move, rename, symlink, delete with comprehensive undo support. Optional trash bin for safe deletion with restore capability.
16
+ .TP
17
+ .B Remote Browsing
18
+ SSH/SFTP directory browsing with interactive shell sessions, file download/upload, and seamless navigation.
19
+ .TP
20
+ .B Image Display
21
+ Inline terminal image display using w3m or Sixel protocols. Supports EXIF orientation for correct display of phone photos.
22
+ .TP
23
+ .B Advanced Features
24
+ Git status, cryptographic hashing, bulk rename with patterns, file comparison, OpenAI integration for file descriptions and chat.
25
+ .SH KEYBOARD REFERENCE
26
+ .SS Basic Keys
27
+ .TP
28
+ .B ?
29
+ Show help text
30
+ .TP
31
+ .B q
32
+ Quit and save configuration
33
+ .TP
34
+ .B Q
35
+ Quit without saving
36
+ .TP
37
+ .B r
38
+ Refresh display (useful after terminal resize)
39
+ .TP
40
+ .B R
41
+ Reload configuration from ~/.rtfm/conf
42
+ .SS Motion
43
+ .TP
44
+ .BR j ", " DOWN
45
+ Move down one item
46
+ .TP
47
+ .BR k ", " UP
48
+ Move up one item
49
+ .TP
50
+ .BR h ", " LEFT
51
+ Go to parent directory
52
+ .TP
53
+ .BR l ", " RIGHT ", " ENTER
54
+ Enter directory or open file
55
+ .TP
56
+ .B HOME
57
+ Jump to first item
58
+ .TP
59
+ .B END
60
+ Jump to last item
61
+ .TP
62
+ .B PgDown
63
+ Page down
64
+ .TP
65
+ .B PgUp
66
+ Page up
67
+ .SS Marks and Jumping
68
+ .TP
69
+ .B m
70
+ Set mark (press letter a-z after)
71
+ .TP
72
+ .B '
73
+ Jump to mark (press letter after)
74
+ .TP
75
+ .B ~
76
+ Jump to home directory
77
+ .TP
78
+ .B >
79
+ Follow symlink to target directory
80
+ .TP
81
+ .B Ctrl-r
82
+ Show recently accessed files and directories
83
+ .TP
84
+ .B Ctrl-e
85
+ Toggle remote SSH/SFTP mode
86
+ .SS Tagging
87
+ .TP
88
+ .B t
89
+ Tag/untag current item
90
+ .TP
91
+ .B Ctrl-t
92
+ Tag items matching pattern
93
+ .TP
94
+ .B T
95
+ Show tagged items
96
+ .TP
97
+ .B u
98
+ Untag all items
99
+ .SS File Operations
100
+ .TP
101
+ .B p
102
+ Copy tagged items here
103
+ .TP
104
+ .B P
105
+ Move tagged items here
106
+ .TP
107
+ .B s
108
+ Create symlinks to tagged items
109
+ .TP
110
+ .B c
111
+ Rename selected item
112
+ .TP
113
+ .B E
114
+ Bulk rename tagged files with patterns
115
+ .TP
116
+ .B d
117
+ Delete items (moves to trash if enabled)
118
+ .TP
119
+ .B D
120
+ Empty trash directory
121
+ .TP
122
+ .B Ctrl-d
123
+ Toggle trash on/off
124
+ .TP
125
+ .B U
126
+ Undo last operation
127
+ .SS Permissions
128
+ .TP
129
+ .B Ctrl-o
130
+ Change ownership (user:group)
131
+ .TP
132
+ .B Ctrl-p
133
+ Change permissions (755, rwxr-xr-x, +x, -w, etc.)
134
+ .SS Search and Filter
135
+ .TP
136
+ .B f
137
+ Filter by file extension
138
+ .TP
139
+ .B F
140
+ Filter by regex pattern
141
+ .TP
142
+ .B /
143
+ Search and highlight matches
144
+ .TP
145
+ .B n
146
+ Next search match
147
+ .TP
148
+ .B N
149
+ Previous search match
150
+ .TP
151
+ .B g
152
+ Grep files for content
153
+ .TP
154
+ .B L
155
+ Locate files
156
+ .TP
157
+ .B Ctrl-l
158
+ Fuzzy file search (requires fzf)
159
+ .SS Display Options
160
+ .TP
161
+ .B w
162
+ Change pane width ratio
163
+ .TP
164
+ .B B
165
+ Cycle border styles
166
+ .TP
167
+ .B \-
168
+ Toggle preview on/off
169
+ .TP
170
+ .B _
171
+ Toggle image preview on/off
172
+ .TP
173
+ .B b
174
+ Toggle syntax highlighting
175
+ .TP
176
+ .B a
177
+ Show/hide hidden files
178
+ .TP
179
+ .B A
180
+ Toggle long file info (ls -l)
181
+ .TP
182
+ .B o
183
+ Change sort order
184
+ .TP
185
+ .B i
186
+ Invert sort order
187
+ .SS Clipboard
188
+ .TP
189
+ .B y
190
+ Copy path to primary selection (middle-click paste)
191
+ .TP
192
+ .B Y
193
+ Copy path to clipboard
194
+ .TP
195
+ .B Ctrl-y
196
+ Copy image to clipboard (when viewing image) or copy right pane text
197
+ .SS Git/Hash/AI
198
+ .TP
199
+ .B G
200
+ Show git status
201
+ .TP
202
+ .B H
203
+ Cryptographic hash of directory tree
204
+ .TP
205
+ .B I
206
+ Get OpenAI description of file
207
+ .TP
208
+ .B Ctrl-a
209
+ Start OpenAI chat session
210
+ .SS System
211
+ .TP
212
+ .B S
213
+ Show comprehensive system information
214
+ .TP
215
+ .B X
216
+ Compare two tagged files
217
+ .TP
218
+ .B e
219
+ Show detailed file properties
220
+ .SH CONFIGURATION
221
+ Configuration is stored in
222
+ .IR ~/.rtfm/conf .
223
+
224
+ Use
225
+ .B W
226
+ to write current settings or
227
+ .B C
228
+ to view configuration.
229
+
230
+ .SS Configurable Variables
231
+ .TP
232
+ .B @marks
233
+ Persistent directory bookmarks
234
+ .TP
235
+ .B @trash
236
+ Enable/disable trash directory (true/false)
237
+ .TP
238
+ .B @preview
239
+ Enable/disable file preview (true/false)
240
+ .TP
241
+ .B @showimage
242
+ Enable/disable image display (true/false)
243
+ .TP
244
+ .B @lslong
245
+ Show long file info (true/false)
246
+ .TP
247
+ .B @lsall
248
+ Show hidden files (true/false)
249
+ .TP
250
+ .B @width
251
+ Pane width ratio (2-7)
252
+ .TP
253
+ .B @border
254
+ Border style (0-3)
255
+ .TP
256
+ .B @ai
257
+ OpenAI API key for AI features
258
+ .SH PLUGINS
259
+ RTFM supports custom plugins in
260
+ .IR ~/.rtfm/plugins/ :
261
+
262
+ .TP
263
+ .B preview.rb
264
+ Custom preview handlers for file types
265
+ .TP
266
+ .B keys.rb
267
+ Custom key bindings and commands
268
+ .SH REMOTE MODE
269
+ Access remote directories via SSH/SFTP with
270
+ .BR Ctrl-e .
271
+
272
+ .SS Remote Operations
273
+ .TP
274
+ .B d
275
+ Download selected file
276
+ .TP
277
+ .B u
278
+ Upload local tagged files
279
+ .TP
280
+ .B s
281
+ Open SSH shell session
282
+ .TP
283
+ .B LEFT/h
284
+ Navigate to parent directory
285
+ .TP
286
+ .B RIGHT/ENTER
287
+ Show file info or enter directory
288
+ .SH DEPENDENCIES
289
+ .SS Required
290
+ .TP
291
+ Ruby 2.7+
292
+ .TP
293
+ rcurses gem (~> 6.0)
294
+ .TP
295
+ termpix gem (~> 0.2)
296
+ .SS Optional
297
+ .TP
298
+ .B ImageMagick
299
+ For image preview (identify, convert commands)
300
+ .TP
301
+ .B w3m-img
302
+ For w3m image protocol support
303
+ .TP
304
+ .B xdotool
305
+ For image redraw on workspace switching
306
+ .TP
307
+ .B bat/batcat
308
+ Syntax highlighting in previews
309
+ .TP
310
+ .B fzf
311
+ Fuzzy file finding
312
+ .TP
313
+ .B pandoc
314
+ Document conversion for previews
315
+ .TP
316
+ .B ffmpegthumbnailer
317
+ Video thumbnail generation
318
+ .TP
319
+ .B ruby-openai
320
+ OpenAI integration
321
+ .SH FILES
322
+ .TP
323
+ .I ~/.rtfm/conf
324
+ Main configuration file
325
+ .TP
326
+ .I ~/.rtfm/trash/
327
+ Trash directory for deleted items
328
+ .TP
329
+ .I ~/.rtfm/plugins/preview.rb
330
+ Custom preview handlers
331
+ .TP
332
+ .I ~/.rtfm/plugins/keys.rb
333
+ Custom key bindings
334
+ .SH EXAMPLES
335
+ .TP
336
+ Start RTFM in current directory:
337
+ .B rtfm
338
+ .TP
339
+ Start in specific directory:
340
+ .B rtfm ~/Documents
341
+ .TP
342
+ Use 'r' alias to cd into last directory on exit:
343
+ Add to ~/.bashrc:
344
+ .br
345
+ .B alias r='cd "$(rtfm --last-dir)"'
346
+ .SH COMPARISON WITH RANGER
347
+ RTFM offers more features than ranger including SSH/SFTP browsing, comprehensive undo, trash system, OpenAI integration, and permission/ownership management with undo. Written in pure Ruby vs ranger's Python. Smaller codebase (6K vs 22K lines) but more feature-dense.
348
+ .SH BUGS
349
+ Report bugs at: https://github.com/isene/RTFM/issues
350
+ .SH AUTHOR
351
+ Written by Geir Isene <g@isene.com>
352
+ .SH SEE ALSO
353
+ .BR ls (1),
354
+ .BR ranger (1),
355
+ .BR mc (1)
356
+ .PP
357
+ Project homepage: https://isene.com/
358
+ .br
359
+ GitHub: https://github.com/isene/RTFM
360
+ .br
361
+ Termpix gem: https://github.com/isene/termpix
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rtfm-filemanager
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.3.6
4
+ version: 7.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Geir Isene
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-11-03 00:00:00.000000000 Z
11
+ date: 2025-11-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rcurses
@@ -67,7 +67,7 @@ dependencies:
67
67
  - !ruby/object:Gem::Version
68
68
  version: '7.4'
69
69
  description: |-
70
- RTFM v7.3.6: Preview toggle clears images and performance optimization with termpix 0.2.1.
70
+ RTFM v7.4.0: Comprehensive documentation release with man page, guides, and examples.
71
71
  A full featured terminal browser with syntax highlighted files, images shown in the terminal, videos thumbnailed, etc. Features include remote SSH/SFTP browsing, interactive SSH shell, comprehensive undo system, bookmarks, and much more. You can bookmark and jump around easily, delete, rename, copy, symlink and move files. RTFM is one of the most feature-packed terminal file managers.
72
72
  email: g@isene.com
73
73
  executables:
@@ -75,10 +75,20 @@ executables:
75
75
  extensions: []
76
76
  extra_rdoc_files: []
77
77
  files:
78
+ - CHANGELOG.md
78
79
  - README.md
79
80
  - bin/rtfm
81
+ - docs/configuration.md
82
+ - docs/faq.md
83
+ - docs/getting-started.md
84
+ - docs/keyboard-reference.md
85
+ - docs/plugins.md
86
+ - docs/remote-browsing.md
87
+ - docs/troubleshooting.md
88
+ - examples/rtfm.conf
80
89
  - img/logo.png
81
90
  - img/rtfm-kb.png
91
+ - man/rtfm.1
82
92
  homepage: https://isene.com/
83
93
  licenses:
84
94
  - Unlicense