By editor, 18 September, 2016 Question How to remove all git repository history and set the current state as initial commit ? This is the brute-force method. It also removes the configuration of the repository. Step 1: remove all history rm -rf .git Step 2: reconstruct the Git repository with current content git init git add . git commit -m "Initial Commit" Step 3: push to Git. git remote add origin <git-uri> git push -u --force origin master Tags Git Server Helpful git commands Make Correction on a git Comments You must have JavaScript enabled to use this form. Your name Subject Comment About text formats Plain text No HTML tags allowed. Lines and paragraphs break automatically. Web page addresses and email addresses turn into links automatically.
Comments