Personalis folder nexus in desktop

I wanted to ask for help. For no reason all the personal folders that are in the Home on the desktop have appeared, such as; images, music, documents, etc., etc.
Now I can't make them invisible on the desktop. If I delete them, it also deletes the actual folders with all the content inside.
How do I solve this problem? Thank you very much!

Just to clarify: the contents of your home directory are appearing in your desktop?

Can you open up a terminal and run the following commands and compare the output?

ls -l $HOME
ls -l $HOME/Desktop

For example:

Do you see the same number of lines after each command? Are there any duplicates? If there are, check if the first letter of each line: a hypen - means it's a regular file, d stands for directory (folder) and l means a link (shortcut). I suspect you will see a lot of these.

You should take a Look at this Thread:

2 Likes

Sorry for the delay. Here's what it looks like in the terminal:

carlo@carlo-System-Product-Name:~$ ls -l $HOME
totale 20
drwxrwxr-x 2 carlo carlo 4096 set 19 16:57 Documenti
drwxrwxr-x 3 carlo carlo 4096 set 21 22:08 Immagini
drwxrwxr-x 2 carlo carlo 4096 set 19 16:56 Musica
drwxrwxr-x 2 carlo carlo 4096 set 21 22:41 Scaricati
drwxrwxr-x 2 carlo carlo 4096 set 19 16:57 Video
carlo@carlo-System-Product-Name:~$ ls -l $HOME/Desktop
ls: impossibile accedere a '/home/carlo/Desktop': File o directory non esistente
carlo@carlo-System-Product-Name:~$

To the command
ls -l $HOME/Desktop
the message appears: cannot access file, File or directory does not exist.

All right, something looks off there. Take a look at the thread posted above by @Ponce-De-Leon, it links to a similar issue. The solution in that case was to manually edit the file located at $HOME/.config/user-dirs.dirs, which is what defines the actual location of the various folders in your user home folder.

I looked at the thread and made the changes. But the problem remains.
This is what's inside the user-dirs.dirs file.

XDG_DESKTOP_DIR="$HOME/"
XDG_DOWNLOAD_DIR="$HOME/Scaricati"
XDG_TEMPLATES_DIR="$HOME/"
XDG_PUBLICSHARE_DIR="$HOME/"
XDG_DOCUMENTS_DIR="$HOME/Documenti"
XDG_MUSIC_DIR="$HOME/Musica"
XDG_PICTURES_DIR="$HOME/Immagini"
XDG_VIDEOS_DIR="$HOME/Video"

I modified the command by adding Desktop:
XDG_DESKTOP_DIR="$HOME/Desktop
When I restart, the file is restored and any changes I made are discarded.
So I thought, maybe I'm wrong, I should use the term in Italian. In fact ZorinOS for DOCUMENTS uses Documenti, MUSIC, Musica, etc., etc.
So I wrote:
XDG_DESKTOP_DIR="$HOME/Scrivania
When I restart, the file is restored and any changes I made are discarded.
Am I doing something wrong?

Maybe I should lock the changes to the file with the command:

chattr +i ~/.config/user-dirs.dirs

I used the command, and the problem was partially solved. The folders, Documents, images, Music, Videos and Downloads disappeared.
The problem is that the other icons, such as the Recycle Bin and the Home folder, also disappeared.
Then I removed the block on the file, restarted and all the icons reappeared. Unfortunately, even those that should not be displayed on the Desktop.

Make sure you are not leaving any trailing slashes (/) after each line, it should look something like this:

XDG_DESKTOP_DIR="$HOME/Desktop"
XDG_DOWNLOAD_DIR="$HOME/Downloads"
XDG_TEMPLATES_DIR="$HOME/Templates"
XDG_PUBLICSHARE_DIR="$HOME/Public"
XDG_DOCUMENTS_DIR="$HOME/Documents"
XDG_MUSIC_DIR="$HOME/Music"
XDG_PICTURES_DIR="$HOME/Pictures"
XDG_VIDEOS_DIR="$HOME/Videos"

I'm actually not sure about the language, from that other thread the user had it in Portuguese and that seemed to work fine. If you already have everything else in Italian, go ahead and change it accordingly. Otherwise, use the English from the snippet above:

The issue is likely due to a bad format, so I wouldn't recommend it. You can revert this with: chattr -i ~/.config/user-dirs.dirs.

I made these changes correctly, the problem is that when restarting, the operating system cancels the change, restoring the file as it was before and consequently the folders are displayed on the desktop.

Try it in the Terminal with the sudo nano ~/.config/user-dirs.dirs Command. After making the Changes, You press ctrl+o to save the changes, Enter to confirm and ctrl+x to exit.

Yes, You should use the italian Terms.

Nothing to do... The problem remains. Upon reboot the file is restored and the changes are undone. This is a bug...

And You saved the Changes like it wrote, yes?

When you installed Zorin OS, was it originally in Italian or did you change the language afterwards?

If yes, that might be what caused the issue as it just happened to me while troubleshooting this. Otherwise, we found a different type of bug.

And it did for some, but there are quite a few issue there still:


EDIT:

Everything seems to be working fine; the new folders are acting exactly as they should and the ones that remain as per the screenshot above seem to be there only because they contained some files already.
So, this is probably just a only a bug in the sense that it doesn't rename the folders as one might have thought, but it's not breaking any functionality.

Let's ignore this last part (I'll leave it here for future reference just in case).


Can you check the contents of the file located at /etc/xdg/user-dirs.defaults? This is the one that gets used when the one in your home directory is missing or not working. Ideally, it should look something like this:

DESKTOP=Desktop
DOWNLOAD=Downloads
TEMPLATES=Templates
PUBLICSHARE=Public
DOCUMENTS=Documents
MUSIC=Music
PICTURES=Pictures
VIDEOS=Videos

Absolutely yes, I saved the changes. But when I restart the changes are canceled.
ZorinOS was installed immediately in Italian.

Here's what the file information looks like:
Schermata del 2024-09-25 20-14-31

Hmm ... Okay. There are definately the italian Terms for Desktop, Templates and Public Share missing. On Your other Picture these Folders are missing in Nautilus under home, too. Which isn't wondering.

So, when You add it in Italian, save it, it will be reset ... weird Behavior. When you open this file with Gedit (Text Editor), do you have the same Behavior when you change and save it?

Check also the one at /etc/xdg/user-dirs.defaults; what does that look like?

1 Like

Schermata del 2024-09-26 22-09-41

Something came to my mind. Now I remember that this problem occurred when I installed a Windows program, and it made the program link appear on the desktop, but with a red X. In fact, it was unusable. So I deleted it and then uninstalled the program. Here, once this operation was done, the folders mysteriously appeared on the desktop!

1 Like

So, everything is fine and working normal now? Can I ask what for a Program that was?

Sorry for my bad English. No it doesn't work at all. I just described when the problem appeared. Maybe Wine is interfering somehow. Maybe it restores the file on reboot, undoing the changes?

Oh, okay. You could try it. Sometimes a Reboot can help.