summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2010-01-09 00:34:27 +0100
committerhut <hut@lavabit.com>2010-01-09 00:34:27 +0100
commit2a64495f966991585dc7e4a35d48f8801fc556f8 (patch)
treea237d775186c42323b0c94c8327db5ce3500633c
parent07277a0a8a002464c83c81978549c42642493c2c (diff)
downloadranger-2a64495f966991585dc7e4a35d48f8801fc556f8.tar.gz
actions: fixed deletion of symlinks to directories
-rw-r--r--TODO2
-rw-r--r--ranger/actions.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/TODO b/TODO
index cc3b9c85..f5e5536f 100644
--- a/TODO
+++ b/TODO
@@ -34,7 +34,7 @@ Bugs
    (X) #19  10/01/01  resizing after pressing g
    (X) #23  10/01/04  stop dir loading with ^C -> wont load anymore
    (X) #25  10/01/06  directories sometimes dont reload correctly
-   ( ) #26  10/01/06  :delete on symlinks of directories fails
+   (X) #26  10/01/06  :delete on symlinks of directories fails
    ( ) #31  10/01/06  ^C breaks cd-after-exit
 
 
diff --git a/ranger/actions.py b/ranger/actions.py
index 42756379..7e1c1dd3 100644
--- a/ranger/actions.py
+++ b/ranger/actions.py
@@ -451,7 +451,7 @@ class Actions(EnvironmentAware, SettingsAware):
 		self.env.copy -= selected
 		if selected:
 			for f in selected:
-				if os.path.isdir(f.path):
+				if os.path.isdir(f.path) and not os.path.islink(f.path):
 					try:
 						shutil.rmtree(f.path)
 					except OSError as err:
00 committer hut <hut@lavabit.com> 2010-01-02 00:10:49 +0100 updated pydoc documentation' href='/akspecs/ranger/commit/doc/pydoc/ranger.gui.defaultui.html?h=v1.7.0-emacs&id=4c13e1f2d85483e026d79ab05da9f1e8e4b45293'>4c13e1f2 ^
f07bb12f ^
4c13e1f2 ^


f07bb12f ^












































4c13e1f2 ^
f07bb12f ^


4c13e1f2 ^
f07bb12f ^


4c13e1f2 ^
f07bb12f ^







4c13e1f2 ^
f07bb12f ^
4c13e1f2 ^

f07bb12f ^



f07bb12f ^















4c13e1f2 ^











f07bb12f ^
4c13e1f2 ^
f07bb12f ^









1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179