Noobie Emacs config reddit / emacs ---------------------------------------------------------------------- Mimi_Valsi · 2022-12-16 10:48 Hey ppl, So trying to configure Emacs, it's my 1st time so it ain't much but it's something. Any trick or tips might add to my init file? [https://github.com/MimiValsi/my-emacs- config.git](https://github.com/MimiValsi/my-emacs-config.git) ​ @ the moment only have eglot, gopls, YASnippet. For those, got the feeling I might miss something important in there. Cheers , \^\^' ​ EDIT: Is there a "good" way to learn Lisp or Elisp? ---------------------------------------------------------------------- your_sweetpea · 2022-12-16 11:30 Off the top of my head, I feel it's much cleaner to use a `custom- file` than to allow emacs to continue writing to your `init.el`. Use `C-h v custom-file RET` in emacs to get the documentation of the variable -- it has recommendations for usage there. ---------------------------------------------------------------------- deaddyfreddy · 2022-12-16 11:37 > (defvar bootstrap-version) you don't need a global variable in order to use it in local `let` bindings > (set-face-attribute 'default nil :font "FiraCode Nerd Font" :height 140) breaks if there's no such font found, either use `ignore-errors` or `face-font-family-alternatives` customizable > custom-set-variables probably you want to store manual customizations in a separate file, see `custom-file` Also, some things are spread all over the config (like yasnippet installation/configuration), consider using `use-package` for configuration management, if you use Emacs from 29 branch - it's already in the box. ---------------------------------------------------------------------- Mimi_Valsi · 2022-12-16 12:39 I see, I guess the best to do is to create \~/.emacs.el or \~/.config/.emacs-custom.el ? Everything before line 78 was "written" by me. So I guess that I cut everything before line 78 and paste it in custom file. Thx for the advice ---------------------------------------------------------------------- Mimi_Valsi · 2022-12-16 12:42 Ok, gonna see what I can do with it. Thx for the advice ---------------------------------------------------------------------- xenodium · 2022-12-16 13:26 There’s something very comforting about how simple this init file is. No need to feel like one must add more to it if already happy with it. Having said all that, I sometimes post Emacs tips here and there at https://xenodium.com. I try to add screencasts so it’s easier to get an idea of the tip in action. If you see something you like, I typically share the snippets. I’ve recently re-posted a lot of the screencasts, so it’s easier to quickly browse through them https://indieweb.social/@xenodium/109350129085202603 ---------------------------------------------------------------------- Mimi_Valsi · 2022-12-16 13:33 Neat thx for the share. Will definitely take a look ---------------------------------------------------------------------- lastnamebird · 2022-12-16 13:40 The custom file is for emacs to edit, so you would need to copy everything *after* line 78. The documentation will provide more info on this. ---------------------------------------------------------------------- Mimi_Valsi · 2022-12-16 13:43 Huh yh after! sry my bad! thx :) ---------------------------------------------------------------------- Likhon-BaRoy · 2022-12-16 15:00 Here's mine, you can check this out for better understanding... https://github.com/Likhon-baRoy/.emacs.d#readme ---------------------------------------------------------------------- Mimi_Valsi · 2022-12-16 15:08 Neat thx ---------------------------------------------------------------------- timmymayes · 2022-12-16 16:20 Personally for me the biggest thing is a literate config using org- mode and org-babel. Other than that I'm just a big fan of AVY. ---------------------------------------------------------------------- 00-11 · 2022-12-16 18:02 This. ---------------------------------------------------------------------- MitchellMarquez42 · 2022-12-16 18:18 The `defvar bootstrap-version` is pasted from straight.el's Readme. I've tried changing it before and I vaguely remember it breaking something. ---------------------------------------------------------------------- [deleted] · 2022-12-16 18:20 [removed] ---------------------------------------------------------------------- field_thought_slight · 2022-12-16 20:01 > probably you want to store manual customizations in a separate file Why? I think it's perfectly fine to apply customizations in `init.el`. ---------------------------------------------------------------------- danderzei · 2022-12-16 22:47 Good way to learn Emacs lisp is An Introduction to Programming in Emacs Lisp by Robert Chassell. https://shop.fsf.org/books/signed- introduction-programming-emacs-lisp-3rd-edition Also available in Emacs: `(info "(eintr) top")`. ---------------------------------------------------------------------- deaddyfreddy · 2022-12-17 09:24 whatever works for you ---------------------------------------------------------------------- deaddyfreddy · 2022-12-17 09:25 ok, looks strange, though