1

Recently the New... menu has overflown with useless options for new files, such as .bashrc, .Xauthority, or .steampath
Any suggestions for how to clear it out? right-click

Here's my ~/Templates directory, there's no hidden files ~/templates

6
  • Somehow I think some files and foldres got in the wrong place. Can you put a screen shot with the contents of the ~/Templates folder?
    – Vlad
    Jun 8 '20 at 11:34
  • @VladPop Sure, updated the question Jun 8 '20 at 12:04
  • 1
    Thanks for the added image. Normally, the 'New' menu lists the contents of the Templates folder. Since your Templates folder is almost empty, we need to see where those entries come from in your case. Can you locate the 'jack' and 'Guitar Pro6' folders? EDIT: look at the output of tail ~/.config/user-dirs.dirs, the XDG_TEMPLATES_DIR variable's value.
    – Vlad
    Jun 8 '20 at 15:02
  • OMG YES! Thank you :D Jun 8 '20 at 21:43
  • 1
    @BillO'Dwyer if you have the time, could you post an answer to the question with how you resolved the issue? That way, if anyone else has this issue, they can use your answer to solve it. Jun 9 '20 at 11:16
3

The "New" list in the right-click menu draws from XDG_TEMPLATES_DIR in .config/user-dirs.dirs.
Running the command tail ~/.config/user-dirs.dirs showed that XDG_TEMPLATES_DIR was set as $HOME and hence was trying to use all the various dotfiles in the home directory as templates.

Amending the file so it says XDG_TEMPLATES_DIR="$HOME/Templates" followed by a restart fixed the issue.

0

Just adding a comment here, as this has been an issue that I encountered recently.

If the Templates folder is Deleted, and the system is restarted, the config line changes to XDG_TEMPLATES_DIR="$HOME".

By setting it to "$HOME/Templates", then creating a folder called Templates in the Home Directory, then restarting, fixed my issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.