How to ignore vim undo files


#1

Hi,

I want to ignore vim undo files like .Readme.un~ and added this to my config:

  core:
    ignoredNames: [
      ".*.un~"
    ]

but this doesn’t work. I tied also “.un~" and ".un~” without luck. I think the problem is the ~ char, but I have no idea how to escape this right.


#2

I added .*.un~ through the settings-view UI and watched .Readme.un~ disappear from the tree-view. Then I opened my config.cson and looked at what had been added. It wasn’t escaped at all:

    ignoredNames: [
      ".git"
      ".hg"
      ".svn"
      ".DS_Store"
      ".keep"
      "._*"
      "*.pyc"
      "Thumbs.db"
      "**/node_modules"
      ".*.un~"
    ]

#3

You don’t by any chance have duplicate core or ignoredNames keys do you? Cson and json silently ignore duplicate entries which is a big bug to me.


#4

As you listed the “.git” and othner dirs I saw that they are visible but grayed out in the tree-view. With working ignoreNames they should completely hide instead, is this correct?

I tested it with the “.git” dir, because it doesn’t have this ~ char. Without luck:

Complete config:

"*":
  core:
    disabledPackages: [
      "vim-mode"
    ]
    excludeVcsIgnoredPaths: false
    ignoredNames: [
      ".git"
    ]
  editor:
    invisibles: {}
  "exception-reporting":
    userId: "1d87bb72-bf1b-b32b-f30d-2ee0a71e0fc9"
  "keyboard-localization":
    useKeyboardLayout: "de_DE-neo"
  "vim-mode": {}
  "vim-mode-plus":
    flashOnUndoRedo: true
    incrementalSearch: true
    setCursorToStartOfChangeOnUndoRedo: true
    showHoverOnOperate: true
    showHoverSearchCounter: true
    useSmartcaseForSearch: true
  welcome:
    showOnStartup: false

#5

No, this isn’t correct. Whether they are hidden or just de-emphasized is controlled by the “Hide Ignored Names” setting in the tree-view package’s settings:

You can also toggle whether ignoredNames are hidden or de-emphasized by putting the focus on the tree-view and pressing I.


#6

@leedohm that worked! I didn’t thought about that core packages have their own settings, I look at them the next time. Thank you :slight_smile: