rtfm-filemanager 7.1.2 → 7.1.4
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.
- checksums.yaml +4 -4
- data/bin/rtfm +33 -9
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e58a3ca5dea3c9a47fb684b59d6ca3e59e343e792da7f6bd920e19352a6ef304
|
|
4
|
+
data.tar.gz: b39baa83754fae08f10da279055508ea09fa0912c65533a3989a97dee57f9fea
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4cc0c86a87b3c2262bc8f54a0ba5e0289d87aced4090cdf43443e84454bd28afadebbc5d5fc693f132fdb818bda663ff9d94a451e67859c9022adc4a6c1ccbee
|
|
7
|
+
data.tar.gz: fdd25b0ea4a8683e6f13d07ad6e59ceeab7e9258f6ee54839f65e208d51eebe5e25ebd9fc923a0a145e8adee68a0bb7d4409f9a4ff40b0231b106ee07125cc49
|
data/bin/rtfm
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
# get a great understanding of the code itself by simply sending
|
|
19
19
|
# or pasting this whole file into you favorite AI for coding with
|
|
20
20
|
# a prompt like this: "Help me understand every part of this code".
|
|
21
|
-
@version = '7.
|
|
21
|
+
@version = '7.1.4' # Fixed terminal resizing issues in window managers
|
|
22
22
|
|
|
23
23
|
# SAVE & STORE TERMINAL {{{1
|
|
24
24
|
ORIG_STTY = `stty -g`.chomp
|
|
@@ -1124,6 +1124,17 @@ def show_version # {{{3
|
|
|
1124
1124
|
end
|
|
1125
1125
|
|
|
1126
1126
|
def refresh_all # {{{3
|
|
1127
|
+
# Re-read terminal size to handle window resizing
|
|
1128
|
+
begin
|
|
1129
|
+
new_h, new_w = IO.console.winsize
|
|
1130
|
+
# Validate terminal size (minimum 10x20 to be usable)
|
|
1131
|
+
if new_h && new_w && new_h >= 10 && new_w >= 20
|
|
1132
|
+
@h, @w = new_h, new_w
|
|
1133
|
+
end
|
|
1134
|
+
rescue
|
|
1135
|
+
# Keep current size if we can't read new size
|
|
1136
|
+
end
|
|
1137
|
+
|
|
1127
1138
|
# Clear remote directory cache if in remote mode
|
|
1128
1139
|
if @remote_mode
|
|
1129
1140
|
@remote_files_cache = []
|
|
@@ -3243,8 +3254,9 @@ def delete_items # {{{3
|
|
|
3243
3254
|
prompt_text = @trash ? "Move to trash? (y/n)" : "⚠️ PERMANENTLY DELETE? (y/n)"
|
|
3244
3255
|
@pB.say(" #{prompt_text}".fg(action_color))
|
|
3245
3256
|
if getchr == 'y'
|
|
3246
|
-
#
|
|
3247
|
-
|
|
3257
|
+
# Collect paths - include broken symlinks since they can be moved/deleted
|
|
3258
|
+
# File.exist? returns false for broken symlinks, but File.symlink? still works
|
|
3259
|
+
paths = (@tagged + [@selected]).uniq.select { |p| File.exist?(p) || File.symlink?(p) }
|
|
3248
3260
|
if paths.empty?
|
|
3249
3261
|
@pB.say("No valid items to #{action.downcase}".fg(196))
|
|
3250
3262
|
else
|
|
@@ -3341,7 +3353,7 @@ def change_ownership # {{{3
|
|
|
3341
3353
|
end
|
|
3342
3354
|
|
|
3343
3355
|
def change_permissions # {{{3
|
|
3344
|
-
# strip leading
|
|
3356
|
+
# strip leading "-" off e.g. "-rwxr-xr-x" → "rwxr-xr-x"
|
|
3345
3357
|
default = @fileattr.split[1][1..]
|
|
3346
3358
|
ans = @pB.ask('Permissions: ', default)
|
|
3347
3359
|
# Reset bottom pane after input
|
|
@@ -3378,6 +3390,9 @@ def change_permissions # {{{3
|
|
|
3378
3390
|
File.chmod(mode, @selected)
|
|
3379
3391
|
@tagged.each { |t| File.chmod(mode, t) rescue nil }
|
|
3380
3392
|
@pB.say("Permissions changed to: #{mode.to_s(8)}")
|
|
3393
|
+
# Invalidate cache for current directory to show updated colors
|
|
3394
|
+
@dir_cache.delete_if { |key, _| key.start_with?("#{Dir.pwd}:") }
|
|
3395
|
+
@pL.update = true
|
|
3381
3396
|
end
|
|
3382
3397
|
end
|
|
3383
3398
|
end
|
|
@@ -5696,15 +5711,24 @@ end
|
|
|
5696
5711
|
setborder
|
|
5697
5712
|
|
|
5698
5713
|
## Catch change in terminal resize, redraw {{{2
|
|
5699
|
-
Signal.trap('WINCH') do
|
|
5714
|
+
Signal.trap('WINCH') do
|
|
5700
5715
|
# Don't refresh/render if an external interactive program is running
|
|
5701
5716
|
# This prevents RTFM from painting over programs like HyperList when
|
|
5702
5717
|
# switching terminals in window managers like i3-wm
|
|
5703
5718
|
unless @external_program_running
|
|
5704
|
-
|
|
5705
|
-
|
|
5706
|
-
|
|
5707
|
-
|
|
5719
|
+
begin
|
|
5720
|
+
new_h, new_w = IO.console.winsize
|
|
5721
|
+
# Validate terminal size (minimum 10x20 to be usable)
|
|
5722
|
+
if new_h && new_w && new_h >= 10 && new_w >= 20
|
|
5723
|
+
@h, @w = new_h, new_w
|
|
5724
|
+
@pT.update = @pL.update = @pR.update = @pB.update = true
|
|
5725
|
+
refresh
|
|
5726
|
+
render
|
|
5727
|
+
end
|
|
5728
|
+
rescue => e
|
|
5729
|
+
# Silently ignore resize errors to prevent crashes
|
|
5730
|
+
# User can manually refresh with 'r' key if needed
|
|
5731
|
+
end
|
|
5708
5732
|
end
|
|
5709
5733
|
end
|
|
5710
5734
|
|
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.1.
|
|
4
|
+
version: 7.1.4
|
|
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-10-
|
|
11
|
+
date: 2025-10-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rcurses
|
|
@@ -53,7 +53,7 @@ dependencies:
|
|
|
53
53
|
- !ruby/object:Gem::Version
|
|
54
54
|
version: '7.4'
|
|
55
55
|
description: |-
|
|
56
|
-
RTFM v7.1.
|
|
56
|
+
RTFM v7.1.4: Fixed terminal resizing issues in window managers like i3-wm.
|
|
57
57
|
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.
|
|
58
58
|
email: g@isene.com
|
|
59
59
|
executables:
|