shell-scripte-code/cutname.sh
2018-12-14 00:43:11 +01:00

16 lines
142 B
Bash
Executable file

#!/bin/bash
set -x
while (( "$#" ))
do
FILENAME=${1%%-*}
mv ${1} ${FILENAME}
shift
cd -
done
#./cutname.sh <Ordner>/*-*