dockerfiles/gitserver/create_repo

13 lines
158 B
Plaintext
Raw Normal View History

#!/bin/bash
repo=$1
if [ $repo != *.git ]; then
repo="${repo}.git"
fi
echo "Creating $repo"
(
cd "$HOME"
git init --bare "$repo"
chown -R git:git "$repo"
)