Skip to content

Commit 3701ee3

Browse files
seefoodakinomyoga
andauthored
Update plugins/available/base.plugin.bash
Co-authored-by: Koichi Murase <[email protected]>
1 parent e625443 commit 3701ee3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

plugins/available/base.plugin.bash

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,5 +194,8 @@ function renex() {
194194
local ext2replace="${1:-}"
195195
local newext="${2:-}"
196196
local files=(*."$ext2replace")
197-
for file in "${files[@]}"; do mv "$file" "${file/%.$ext2replace/.$newext}"; done
197+
for file in "${files[@]}"; do
198+
local dst=${file/%."$ext2replace"/."$newext"}
199+
mv "$file" "$dst"
200+
done
198201
}

0 commit comments

Comments
 (0)