Skip to content

Instantly share code, notes, and snippets.

@prium
Created June 8, 2017 05:42
Show Gist options
  • Select an option

  • Save prium/c6b5054b0967a71dd90cd646145c84c8 to your computer and use it in GitHub Desktop.

Select an option

Save prium/c6b5054b0967a71dd90cd646145c84c8 to your computer and use it in GitHub Desktop.

Revisions

  1. prium renamed this gist Jun 8, 2017. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  2. prium created this gist Jun 8, 2017.
    7 changes: 7 additions & 0 deletions .sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,7 @@
    git checkout --orphan newBranch
    git add -A # Add all files and commit them
    git commit
    git branch -D master # Deletes the master branch
    git branch -m master # Rename the current branch to master
    git push -f origin master # Force push master branch to github
    git gc --aggressive --prune=all # remove the old files