git create an orphan branch code example Example: git orphan branch git checkout --orphan orphan_name