Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

6
  • ...Please tell me you wouldn't have to type all of this in order to accomplish this in emacs. Commented Dec 31, 2016 at 0:56
  • 1
    @Hashim The idea is that you have it defined in your init and then bound to a key. Technically I could have it bound to D if I wanted to, but since I don't have a common need for this, all I have to type is M-x *ded RET and bam–done. (If I did indeed have to type this every time, you're absolutely right that it'd be absurd – luckily that's not the case.) Commented Jan 1, 2017 at 7:33
  • Fair enough, that sounds more plausible. Commented Jan 1, 2017 at 22:30
  • Does M-x *ded RET have any significance or is it random? If the latter, how do you keep track of all the shortcuts you've assigned in emacs? Does memorisation suffice or do you find yourself having to look them up? Commented Jan 1, 2017 at 22:32
  • 1
    @Hashim *ded is an abbreviation for the full function name *-delete-empty-directories. Many completion engines (such as ivy, the one I use) understand this kind of fuzzy matching. As for keeping them memorized… I simply don't have to. The functions I've defined all start with * so I can easily find them if they're not bound to a key. Otherwise, emacs itself will tell me if there was a faster way of calling the function. If all else fails, there's always apropos. Commented Jan 2, 2017 at 2:10