How to restore deleted icons (how to restore icons to default)

Hello,
While attempting to change some cursor themes, I deleted some icons in the /usr/share/icons/ directory. Is there any way to restore the deleted icons ? or change the icons to default ie: the icon and cursor theme set that came during the original installation

My start menu zorin icon has gone blank now and I cannot see the check boxes in synaptics :frowning:

I haven’t done this but, as root, make a list of installed icon packages and reinstall.

sudo -i
apt-get list–installed | grep -i icon | xargs apt-get --reinstall install

I’d have to be at my machine to verify that the above works. But basically lists all packages and returns a list of all packages with the word icon in list then apptmpts to reinstall them.

When I get time on my laptop I’ll experiment more.

When I ran that as root, I get the following:
E: Invalid operation list–installed Reading package lists... Done Building dependency tree Reading state information... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Nothing reinstalled or removed :frowning:

Can you please have a look in your directory and tell me which folders you have by default (if haven’t modified :slight_smile:)?

I currently have these folders/files in my /usr/share/icons/ directory:

Adwaita
default
gnome
HighContrast
redglass
whiteglass
Zorin
Zorin-95
ZorinBlue-Dark
ZorinBlue-Light
ZorinGreen-Dark
ZorinGreen-Light
ZorinGrey-Dark
ZorinGrey-Light
ZorinOrange-Dark
ZorinOrange-Light
ZorinPurple-Dark
ZorinPurple-Light
ZorinRed-Dark
ZorinRed-Light

While you’re waiting for jgordon’s response:
Adwaita
breeze
breeze-dark
cab_extract.png
cab_view.png
default
gnome
handhelds
hicolor
HighContrast
locolor
mozc
oxygen
redglass
whiteglass
Zorin
Zorin-95
ZorinBlue-Dark
ZorinBlue-Light
ZorinGreen-Dark
ZorinGreen-Light
ZorinGrey-Dark
ZorinGrey-Light
ZorinOrange-Dark
ZorinOrange-Light
ZorinPurple-Dark
ZorinPurple-Light
ZorinRed-Dark
ZorinRed-Light

You may also want to see:

1 Like

@carmar Thanks, a command from the ask ubuntu link fixed everything and now I got the zorin icon back too :grinning:

The command:

sudo apt-get install --reinstall $(dpkg -S /usr/share/icons | sed -e 's#,##g' | sed "s|: /usr/share/icons||")

For anybody, who is in similar situation, please note that it only restores icons which are downloaded from the repositories or icons that are present in the repositories. Some other applications such as .deb files installed manually (which have lost their icons) will require a reinstall to fix it.

2 Likes