How to create a new (and empty!) "root" branch?
Use the --orphan
when creating the branch:
git checkout --orphan YourBranchName
This will create a new branch with zero commits on it, however all of your files will be staged. At that point you could just remove them.
("remove them": A git reset --hard
will empty the index, leaving you with an empty working tree)
Take a look at the man page for checkout for more information on --orphan.
To add to the accepted answer - best practice to revert to clean state is to create an initial empty commit so you can easily rebase while setting up your branches for posterity. Plus since you want a clean state you probably have committed files that you shouldn't, so you have to remove them from the index. With those in mind you should:
$ git checkout --orphan dev2
Switched to a new branch 'dev2'
$ git reset # unstage all the files, you probably don't want to commit all of them
$ git commit --allow-empty -m 'Initial empty commit'
[dev2 (root-commit) a515c28] Initial empty commit