Ubuntu – Rename command not found when running a script


I'm trying to to execute a script, which uses the command rename.

When I execute it, I get a message rename: command not found. Any ideas?

if [[ -z '$3' ]]; then
    shopt -s dotglob
    rename "$EXPRESSION" ./*
    rename "$EXPRESSION" "$3"

Best Answer

I just had to install the rename package.

sudo apt install rename
Related Question