I've been an emacs user for about a year now and I use it for Haskell programming. I chose to go the vanilla emacs route and customized a plain init file as I went along.
Over time, however, I realise that emacs started getting quite sluggish on my computer. The computer is not the bottleneck: its a powerful machine with 32GB of RAM.
My suspicion is that I have too many modes enabled, and hence my question: how do I debug where the modes are being enabled from?
For example; the current list of emacs modes I have enabled in a Haskell buffer are:
Enabled minor modes: Async-Bytecomp-Package Auto-Composition Auto-Compression Auto-Encryption Autopair Autopair-Global Blink-Cursor Cl-Old-Struct-Compat Company Desktop-Save Diff-Auto-Refine Dimmer Display-Line-Numbers Eldoc Erc-Button Erc-Fill Erc-Irccontrols Erc-List Erc-Match Erc-Menu Erc-Move-To-Prompt Erc-Netsplit Erc-Networks Erc-Noncommands Erc-Pcomplete Erc-Readonly Erc-Ring Erc-Sound Erc-Stamp Erc-Track Evil Evil-Commentary Evil-Local Evil-Surround Evil-Visual-Mark File-Name-Shadow Flx-Ido Flycheck Font-Lock Frames-Only Global-Display-Line-Numbers Global-Eldoc Global-Evil-Surround Global-Font-Lock Global-Git-Commit Global-Magit-File Global-Undo-Tree Haskell-Indentation Highlight-Indentation Hindent Ido-Everywhere Intero Intero-Global Line-Number Magit-Auto-Revert Magit-File Mouse-Wheel Override-Global Popwin Projectile Rainbow-Delimiters Recentf Shell-Dirtrack Subword Tooltip Transient-Mark Undo-Tree Which-Key Winner Yas
I can spot multiple ERC related modes which seem to be enabled, and they make no sense since:
- ERC is not running at this time
- I'm in a Haskell buffer
Moreover, I'm not too keen on starting over with a vanilla emacs configuration for 2 reasons:
- If this has happened now, it will likely happen again in future
- I'd like to dig into what enables these ERC modes
My init file as a gist
Can anyone help?
EDIT 2: I experienced a crash recently. The stacktrace doesn't really say much.