Let's step through them:
- "I make a project opensource without a license."
- "I continue contributing to it and at some point I commit a license doc and license text in the header files."
- From this point, the code is licensed under the license you put it under. Older revisions are technically still unlicensed, and still unusable under your new license.
- "I continue developing for it and continue committing fixes, new features, etc."
- Still under the same license, nothing has changed since the previous version
- "At some later stage I decide to scrap the license and I get rid of it."
- at this point it becomes important that you are the only contributor. Assuming that, that means that all new revisions are not available as open source. All old revisions to which the license was attached are still licensed under the old version. All open source and free licenses are irrevocable. You can choose to stop distributing something, but you can't stop others that you have already granted a license (read: others that downloaded the software while the open source license was attached) from distributing it under the license your originally released it under.
If there is code from other contributors that was released to you under an open source license, it depends on the license what you can do to it.
Under permissive licenses, generally (but check your license!) if you want to continue distributing it, you may not remove the license from the parts that you personally don't hold the copyright to.
Copyleft licenses like the GPL enforce that you must release all derivatives that you distribute under the GPL. You may not distribute works that derive from GPL source that you don't hold the copyright to under another license, or closed source.
Take a look at the comments on Combining code written under different licenses (Eiffel Forum License, MIT and Apache), what are my options? for how to handle mixed licenses in your source in the permissive case.
You can also take a look at What are the advantages of adding a Contributor License Agreement to a project? for the CLA route around this