Skip to content

Instantly share code, notes, and snippets.

@ax2mx
Last active November 30, 2018 12:00
Show Gist options
  • Save ax2mx/a2f87c9084d2e1fa3c99dc4e17b75d7e to your computer and use it in GitHub Desktop.
Save ax2mx/a2f87c9084d2e1fa3c99dc4e17b75d7e to your computer and use it in GitHub Desktop.
Создание удалённого репозитория из локального проекта

На всякий случай удаляем историю изменений локального проекта:

rm -rf .git

Заново создаём репозиторий:

git init
git add .
git commit -m "Initial commit"

Пушим в удалённый репозиторий, гарантированно перетирая историю изменений:

git remote add origin [email protected]:<YOUR ACCOUNT>/<YOUR REPOS>.git
git push -u --force origin master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment