I accidentally untarred archive intended to be extracted in root directory, which among others included some files for /etc directory.
I went on to rm -rv ~/etc, but I quickly typed rm -rv /etc instead, and hit enter, while using a root account.


Yeah, same thing like with unclosed bottles, cup too close to the table edge, etc.: Accidents that can hapen, will happen.
Better name them something else in your user dir.
And yes, painful experience.