Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
+1000. This answer saved my sanity. I love nxml-mode but was switching constantly between it and a dedicated XML editor just for the latter's tag-folding support. I wonder, though, if it'd be possible to implement this functionality using the same library as dirtree.el, which supports fold/unfold with the mouse and line-drawing of the tree structure in GUI Emacsen?
@zsquare I don't use magit (I know, I'm nuts) so I can't test this to be sure, but it sounds like magit's keymap for TAB, which binds it to magit-section-toggle, is conflicting with the line (global-set-key [tab] 'tab-indent-or-complete) above. A quick and dirty fix would be to add a check at the beginning of the function tab-indent-or-complete above to see whether we're in magit mode, e.g. for a global variable that gets set on magit-mode-hook.
It's not a company backend, but you can get this behavior easily by turning on HippieExpand mode and integrating it with Company by adding company-complete to hippie-expand-try-functions-list.
This is disappointing. Like a lot of devs these days, I write code on my Mac, but run it in various virtual Linux machines via Vagrant, both to keep the environment clean and avoid polluting OS X with lots of dependency cruft. It'd be really nice for Elpy (and tools like it, e.g. robe for Ruby, or irony-mode for C++, for that matter) to support that use case.
regexp-quote has the nice alternate use of escaping special characters in a string properly for use when a function expects a regexp in "Emacs form"--e.g. if you can't remember how many backslashes to use to escape a literal backslash, just run it through regexp-quote in the scratch buffer or ielm.
This GitHub issue thread suggests that this was a known issue for a while, but the bug was fixed. Can you pull the latest version of undo-tree.el from MELPA, or failing that, straight from GH, and see if it goes away?