spacemacs

Drew Verlee 2022-02-11T16:22:49.266509Z

What are some common ways to keep spacemacs as snappy and fast as possible? I realize this is something of an impossible question, but maybe there are some easy wins. Like if it was the jvm maybe you would check how much mem was allocated. Or how in most projects having as few deps as possible usually helps.

practicalli-johnny 2022-02-11T16:39:42.265099Z

Profile Emacs to see if there is any issues seems to be a common approach https://practical.li/spacemacs/install-spacemacs/troubleshooting.html#profiling-emacs

practicalli-johnny 2022-02-11T16:41:53.911209Z

The scorched earth approach would be to backup your config and reinstall from scratch. Test without applying any of your own configuration and steadily add your customisations back in to see if there is an impact

practicalli-johnny 2022-02-11T16:43:17.174329Z

Less drastic would be to remove any config and packages not needed. Also clean out the .cache files

practicalli-johnny 2022-02-11T16:49:33.507509Z

Removing unused layers shouldn't make any difference, as its all lazy loaded. It could be possible that a package in a layer is causing problems. This package could be excluded by adding the package name to dotspacemacs-excluded-packages although this might break some functionality.

practicalli-johnny 2022-02-11T16:50:46.120969Z

I added some font rendering optomisations to dotspacemacs/user-config but not sure if they made any real difference. https://github.com/practicalli/spacemacs.d/blob/live/init.el#L806-L825

practicalli-johnny 2022-02-11T16:55:30.157759Z

If using MacOSX, then some versions of Emacs are not that fast when running Spacemacs. These seem to be the recommended versions https://github.com/syl20bnr/spacemacs/tree/develop#macos

practicalli-johnny 2022-02-11T16:59:16.694169Z

A potentially significant change is to switch to Ivy for completion, rather than helm. I believe this is done by adding the ivy layer and removing the helm layer in the Spacemacs configuration layers. https://develop.spacemacs.org/layers/+completion/ivy/README.html Ivy is a sub-set of the features of helm, so you may or may not miss those features.

practicalli-johnny 2022-02-11T17:00:50.331909Z

Oh, and of course, update Spacemacs code, your Spacemacs config against the template (`SPC f e D`) and get the latest packages (`SPC f e U`) to get the latest updates and improvements (but dont update when you are busy in the rare case that there is an issue) https://practical.li/spacemacs/install-spacemacs/update.html

practicalli-johnny 2022-02-11T17:11:29.979809Z

Finally, use Emacs 28 with native compilation. This may speed things up or break things (or both)

👀 2
Diego Naya 2022-02-11T19:31:39.660389Z

I had a great speedup migrating from emacs27 (the std package in fedora 35) to emacs 28 (had to install an outside package)

Drew Verlee 2022-02-11T22:03:45.855459Z

Thanks a ton! I'm definitely going to try these ideas over the weekend.

Drew Verlee 2022-02-11T22:04:16.706379Z

Moving around my project has been sluggish and that's a mental drag i don't need.

Drew Verlee 2022-02-12T03:29:23.432949Z

ok wow. yea. i'm on 28 right now and it feels snapper. That or i'm just excited its Friday. time will tell i suppose.

🎉 1
practicalli-johnny 2022-02-12T11:47:32.743539Z

I am curious to understand what is sluggish when moving around projects. What commands are used?

practicalli-johnny 2022-02-12T11:50:12.807049Z

Nothing like a new installation to give a sense of speed 😁 All those newly downloaded and complied Emacs pages should help, even more so if the packages were natively compiled (something I haven't tried yet)

Drew Verlee 2022-02-12T13:42:36.756599Z

Just normal text movement (evil mode up down etc..) had delays i was noticing. I didn't run profiler and collect samples so I'm not sure how often it was happening or why. But 28 feels faster right out of the box for me. I used the snap from ubuntu which i read is natively compiled.