dotfiles/.zsh/functions/ren

8 lines
161 B
Bash

#!/bin/env zsh
function ren {
from="$1"
to="$2"
DIR="${$(realpath "$from")%%$(basename "$from")}"
# echo "$DIR"
echo "$(realpath "$from")" "$DIR$to"
}