2

I am new to Linux, trying to clean my system after deleting a package 'thunderbird'.

I use command sudo ls -lRa . | grep thunderbird to find all the remaining config files and other leftover files to remove them from my system.

This command is very useful and helps me a lot to locate the files related to a specific package. I have already deleted all the directories related to thunderbird, but when I run sudo ls -lRa . | grep thunderbird command, this is what I am seeing now:

-rw-rw-r-- 1 kao kao 75786 bal.  16 01:26 appimagekit_206c725ecb426eabc4dcda2a204bf247_thunderbird.png
-rw-------  1 kao kao  140 bal.  17 16:48 thunderbird[2].desktop
-rw-------  1 kao kao  140 bal.  17 16:48 thunderbird[3].desktop
-rw-------  1 kao kao  140 bal.  17 16:50 thunderbird[4].desktop
-rw-------  1 kao kao  140 bal.  17 16:53 thunderbird[5].desktop
-rw-------  1 kao kao  140 bal.  17 16:53 thunderbird[6].desktop
-rw-------  1 kao kao  140 bal.  17 16:29 thunderbird.desktop

What are those files, how to locate them and remove them?

m27
  • 427
  • 1
  • 5
  • 18

4 Answers4

3

how to locate them and remove them?

One way to do it would be using the command find

sudo find / -iname '*thunderbird*'

Like this you will parse all the file system and will see every element that contains the expression "thunderbird"

Alternativly we have fd-find in our repositroy which is faster then find (because it uses multithread) It is not installed by default, you can install it with apt

sudo apt install fd-find

Syntax is lighter and output is colorized

fd thunderbird /

You can also use locate

locate thunderbird

To remove a file use the rm command

Gryu
  • 8,002
  • 9
  • 37
  • 53
kcdtv
  • 2,445
1

You generally don't need to do it by hand. Package manager will take care of removing system-wide configs of given package using purge action or when providing --purge for remove action

sudo apt purge thunderbird

From apt-get(8):

purge: purge is identical to remove except that packages are removed and purged (any configuration files are deleted too).

--purge: Use purge instead of remove for anything that would be removed. An asterisk ("*") will be displayed next to packages which are scheduled to be purged. remove --purge is equivalent to the purge command. Configuration Item: APT::Get::Purge.

If you still feel like looking up file by somehow matching with name use find as suggested in other answers; it will output full path of the matched file.

dav23r
  • 17
  • 5
0

Desktop files are analog to Start Menu shortcuts in Windows. Those files register some command or application in the system. Those files define the inicialization parameters of a application or command.

They are stored in /usr/share/applications to every user or ~/.local/share/applications if its only acessible to one user.

Exemple:

[Desktop Entry]
Type=Application
Encoding=UTF-8
Name=Nome do aplicativo de exemplo
Comment=Um aplicativo de exemplo
Exec=aplicativo
Icon=aplicativo.png
Terminal=false

[Desktop Entry]

First line and header of the file. 

Type=Application

Tells the enviroment that this desktop file belongs to a application. May also be a Link or Directory.

Encoding=UTF-8

Describe the coding of the file.

Name=Example Name

Application names for the menu and any launcher.

Comment=A exemple of an app

Describe the  application ("tooltip").

Exec=aplicativo

The shell command that start the application. 
May have arguments.

Icon=application.png

Icon's file.

Terminal=false

Describe if the application must beexecuted ina terminal.

Souce: https://developer.gnome.org/integration-guide/stable/desktop-files.html.pt_BR

0

When you want to remove user specific configuration files and application data:

Your configuration files are located in the ~/.thunderbird folder, where ~ means your home folder.

You can remove with the following command:

rm -fr ~/.thunderbird
GuBo
  • 1