So I was trying to install some packages, but they were sort of broken so an answer recommended that I use "apt-get remove" to remove the corrupted versions and re-install them. While doing that I got a warning that said "this could be harmful" then I thought meh and wrote "Yes, do as I say!".
Next thing I know, most of my windows were closing and icons disappearing so I had to forcefully close the terminal. I tried opening a new one to re-install everything but it wouldn't open, so I restarted my laptop.
When Ubuntu opened again, it showed me the black and white terminal (I believe it is called tty) and when I tried to use apt-get to maybe fix things and install everything I removed (and perhaps a desktop), it said the "apt-get" package was not found.
So yeah, I kind of messed up my OS but I want to know if there's a way to fix this without reinstalling Ubuntu because there's a lot of software that I would rather not go through installing them again..
ubuntu-desktop
package too. – Parsa Mousavi Jun 26 '20 at 09:34wget http://archive.ubuntu.com/ubuntu/pool/main/a/apt/apt_1.6.1_amd64.deb ; sudo dpkg -i apt_1.6.1_amd64.deb
– Parsa Mousavi Jun 26 '20 at 09:41wget
to grab & thendpkg
to install is where I'd go until you can use higher level tools.. – guiverc Jun 26 '20 at 09:45apt
package; it lists the depends packagesapt
requires.. ie. when you removed the gnu C++ standard library you caused everything that was compiled in C++ (requiring) it to be removed... which is why you shouldn't '-y' or "yes" without at least scanning packages looking for consequences.. (unless it's for learning sake & you have good backups). It didn't wreck the OS, you just lost access to any tool that required it (dpkg
& many tools are written in C [not C++] so weren't impacted..), ie. learn... – guiverc Jun 26 '20 at 10:52