7c408d6d70
Signed-off-by: Billy Brawner <billy@wbrawner.com>
20 lines
326 B
Bash
Executable file
20 lines
326 B
Bash
Executable file
#!/usr/bin/env sh
|
|
|
|
if [[ -z "$1" ]]; then
|
|
echo "Please enter a source repository name"
|
|
exit 1
|
|
fi
|
|
|
|
if [[ -z "$2" ]]; then
|
|
echo "Please enter a destination repository name"
|
|
exit 1
|
|
fi
|
|
|
|
if [[ -d "$2.git" ]]; then
|
|
echo "Repo $2 already exists"
|
|
exit 1
|
|
fi
|
|
|
|
mv "$1.git" "$2.git"
|
|
echo "Successfully renamed repository $1 to $2"
|
|
|