summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorhut <hut@lavabit.com>2013-06-16 18:20:26 +0200
committerhut <hut@lavabit.com>2013-06-16 18:23:13 +0200
commitc0b14f2b6e025c1cf22dfe9f4c7718d5beace6df (patch)
tree7741172cde9854fea19bf6102f668abb96382d68
parent329fd725230a5618be01414d51e7684e07a49680 (diff)
downloadranger-c0b14f2b6e025c1cf22dfe9f4c7718d5beace6df.tar.gz
data/scope.sh: fix extension matching on uppercase extension
Thanks to niku for the patch.
-rwxr-xr-xranger/data/scope.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/ranger/data/scope.sh b/ranger/data/scope.sh
index ce113a9e..76481f94 100755
--- a/ranger/data/scope.sh
+++ b/ranger/data/scope.sh
@@ -26,7 +26,7 @@ maxln=200    # Stop after $maxln lines.  Can be used like ls | head -n $maxln
 
 # Find out something about the file:
 mimetype=$(file --mime-type -Lb "$path")
-extension=${path##*.}
+extension=$(echo "${path##*.}" | tr "[:upper:]" "[:lower:]")
 
 # Functions:
 # runs a command and saves its output into $output.  Useful if you need
'n136' href='#n136'>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 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232