16 lines
382 B
Bash
16 lines
382 B
Bash
#!/bin/bash
|
|
|
|
# check if this is already a git repo.
|
|
if [[ -d ".git" ]]; then
|
|
echo "Found the .git directory. Already initialized?"
|
|
exit 1
|
|
fi
|
|
|
|
# sync.
|
|
git init &> /dev/null
|
|
git remote add origin https://git.voronind.com/voronind/linux.git &> /dev/null
|
|
git fetch &> /dev/null
|
|
git reset origin/master &> /dev/null
|
|
# git checkout -t origin/master
|
|
git reset --hard HEAD &> /dev/null
|