WEBVTT NOTE Introduction: Amin Bandali, software developer and free software activist 00:00:00.000 --> 00:00:11.559 [Sacha]: Let me do the thing. Go live. 00:00:11.560 --> 00:00:14.399 Let's check in. 00:00:14.400 --> 00:00:16.559 Alright, hello. 00:00:16.560 --> 00:00:20.719 This is Emacs Chat 21 coming back after a decade of not 00:00:20.720 --> 00:00:22.279 doing it, so... 00:00:22.280 --> 00:00:26.759 And today I've got Amin Bandali who's a... 00:00:26.760 --> 00:00:29.279 Is it seven years now that we've been doing 00:00:29.280 --> 00:00:31.579 EmacsConf together? 00:00:31.580 --> 00:00:32.267 [Amin]: I think so. 00:00:31.760 --> 00:00:33.719 Since fall 2019. 00:00:32.268 --> 00:00:32.268 Yeah. 00:00:33.720 --> 00:00:35.679 [Sacha]: Yeah, yeah, yeah, yeah. 00:00:35.680 --> 00:00:38.799 But of course you also do a whole lot of other things. 00:00:38.800 --> 00:00:40.519 I was looking through your Emacs configuration and 00:00:40.520 --> 00:00:43.119 there's like translation and other stuff in there. 00:00:43.120 --> 00:00:45.239 So would you like to start off with a brief 00:00:45.240 --> 00:00:47.559 introduction of who you are 00:00:47.560 --> 00:00:50.259 and how and why you use Emacs? 00:00:50.260 --> 00:00:51.799 [Amin]: Yeah, sure. 00:00:51.800 --> 00:00:53.439 Yeah, first of all, hello, everyone. 00:00:53.440 --> 00:00:54.639 Sorry if I'm looking to the side. 00:00:54.640 --> 00:00:55.879 This is a new setup. 00:00:55.880 --> 00:00:58.879 My laptop, which has my webcam, is there, but my main 00:00:58.880 --> 00:01:00.119 display is here. 00:01:00.120 --> 00:01:03.039 So I might be looking to the side from time to time. 00:01:03.040 --> 00:01:05.279 But yeah, that aside, hello. NOTE Aspects of life: notetaking, editing, multiple 00:01:05.280 --> 00:01:06.399 Yeah, I'm Amin Bandali. 00:01:06.400 --> 00:01:12.359 I've been, I think, using Emacs since 2014 or 15, so I 00:01:12.360 --> 00:01:14.679 guess more than a decade now. 00:01:14.680 --> 00:01:18.879 I'm a software engineer by day, or software developer, 00:01:18.880 --> 00:01:22.159 slash programmer, slash computing scientist. 00:01:22.160 --> 00:01:25.839 I'm also a free software activist. 00:01:25.840 --> 00:01:29.279 I volunteer on a lot of free software projects as 00:01:29.280 --> 00:01:30.639 well, which Sacha mentioned. 00:01:30.640 --> 00:01:31.799 I do things around GNU. 00:01:31.800 --> 00:01:33.319 I volunteer with FSF. 00:01:33.320 --> 00:01:35.719 I'm a Debian developer, so I try to maintain some 00:01:35.720 --> 00:01:37.399 packages in Debian. 00:01:37.400 --> 00:01:41.959 I try to help run EmacsConf from time to time. 00:01:41.960 --> 00:01:45.239 Hopefully this year I will be much more present. 00:01:45.240 --> 00:01:47.039 But yeah, that's that. 00:01:47.040 --> 00:01:50.439 So I first got into using Emacs, I guess, as a 00:01:50.440 --> 00:01:53.039 programmer tool, like as a text editor. 00:01:53.040 --> 00:01:56.439 But I've since then kind of integrated it into a lot 00:01:56.440 --> 00:01:57.839 of other aspects of my life. 00:01:57.840 --> 00:01:59.959 And I do much more with it, as I'm sure a lot of us do. 00:01:59.960 --> 00:02:04.239 Yeah, so I use it for kind of note-taking, just any 00:02:04.240 --> 00:02:06.279 writing, editing purposes. 00:02:06.280 --> 00:02:09.679 in multiple natural and programming languages. 00:02:09.680 --> 00:02:14.559 Reading and sending email for chatting via IRC. 00:02:14.560 --> 00:02:16.779 All of that good stuff. 00:02:16.780 --> 00:02:18.599 [Sacha]: This is the sort of thing that isn't 00:02:18.600 --> 00:02:20.399 immediately obvious from your configuration. 00:02:20.400 --> 00:02:23.239 I know you've got your Gnus setup in there and you've 00:02:23.240 --> 00:02:26.519 got your ERC setup in there, but sometimes when 00:02:26.520 --> 00:02:28.959 newcomers are trying to figure out, okay, there are 00:02:28.960 --> 00:02:31.199 all these packages, but how do I use them 00:02:31.200 --> 00:02:32.359 to get stuff done? 00:02:32.360 --> 00:02:35.679 That's one of the reasons why we want to do this Emacs 00:02:35.680 --> 00:02:38.479 chat, so that maybe you can show us 00:02:38.480 --> 00:02:40.239 some of the cool stuff. 00:02:40.240 --> 00:02:42.879 We are live, but if you accidentally show something 00:02:42.880 --> 00:02:45.279 personal, let me know and I can kill the stream within 00:02:45.280 --> 00:02:48.279 10 seconds and I think then we can be like, okay, 00:02:48.280 --> 00:02:50.799 we'll just flush that out and then come back once 00:02:50.800 --> 00:02:53.239 we've hidden the top secret plans for taking over the 00:02:53.240 --> 00:02:55.399 world, that sort of thing. 00:02:55.400 --> 00:02:57.719 Sounds good. 00:02:57.720 --> 00:03:00.639 Where do we want to start? NOTE Configuration: keeping things simple 00:03:00.640 --> 00:03:03.919 [Amin]: I'm happy to do it however you like. 00:03:03.920 --> 00:03:06.679 I can either share my screen, pull up my configuration. 00:03:06.680 --> 00:03:09.479 Yeah, okay, so let's do that. 00:03:09.480 --> 00:03:10.279 [Sacha]: Yeah. 00:03:10.280 --> 00:03:13.479 If you share your screen sometimes, I think what we 00:03:13.480 --> 00:03:15.479 did ages ago was we just started walking through the 00:03:15.480 --> 00:03:18.279 configuration and then sometimes people say, oh yeah, 00:03:18.280 --> 00:03:19.159 that's really interesting. 00:03:19.160 --> 00:03:21.919 Let's go and demonstrate that so that people can get a 00:03:21.920 --> 00:03:23.559 sense of how this actually works. 00:03:23.560 --> 00:03:27.319 And there were some things in your configuration that 00:03:27.320 --> 00:03:30.159 I had no idea, like what is FFS? 00:03:30.160 --> 00:03:31.919 There's like no package. 00:03:31.920 --> 00:03:34.559 I couldn't find any information about it. 00:03:34.560 --> 00:03:38.079 But yeah, so your config, if you want to go ahead and 00:03:38.080 --> 00:03:39.639 share your screen while I 00:03:39.640 --> 00:03:42.319 Fill the air with hand-waving. 00:03:42.320 --> 00:03:47.719 Admin's config tends to be more on the minimalist side. 00:03:47.720 --> 00:03:52.999 I think you mostly rely on built-in things with a 00:03:53.000 --> 00:03:55.239 couple of external packages. 00:03:55.240 --> 00:03:58.919 You don't even use use-package at all. 00:03:58.920 --> 00:04:01.639 It's all run-at-idle-time to delay the startup of 00:04:01.640 --> 00:04:05.867 various things, and then it's all vanilla Emacs as you 00:04:05.868 --> 00:04:09.800 can get for loading and configuring things. 00:04:09.840 --> 00:04:11.033 [Amin]: Yeah, pretty much, yeah. 00:04:11.034 --> 00:04:13.433 Yeah, so before I continue, quick note, Sacha, if you 00:04:13.434 --> 00:04:15.159 can make me presenter because I don't have access to 00:04:15.160 --> 00:04:16.033 share my screen. 00:04:16.034 --> 00:04:18.599 [Sacha]: Oh, that would be important, yes. 00:04:18.600 --> 00:04:20.399 Hang on a second. 00:04:20.400 --> 00:04:21.359 Let me see. 00:04:21.360 --> 00:04:22.359 Okay, here we go. 00:04:22.360 --> 00:04:23.399 Make presenter. 00:04:23.400 --> 00:04:25.559 I might as well promote you to moderator while we're 00:04:25.560 --> 00:04:26.319 at it. 00:04:26.320 --> 00:04:27.439 There you go. 00:04:27.440 --> 00:04:31.239 You should now have magic powers. 00:04:31.240 --> 00:04:32.399 [Amin]: Thanks. 00:04:32.400 --> 00:04:33.999 Let's see. 00:04:34.000 --> 00:04:35.559 [Sacha]: It's a good thing we're practicing this 00:04:35.560 --> 00:04:40.799 before EmacsConf so I remember how all this stuff works. 00:04:40.800 --> 00:04:43.079 [Amin]: Yep, for sure. 00:04:43.080 --> 00:04:44.079 Okay, let's see. 00:04:44.080 --> 00:04:45.319 I think I got it now. 00:04:45.320 --> 00:04:46.899 Can you see my screen? 00:04:46.900 --> 00:04:50.059 [Sacha]: Yes, I can see your screen. 00:04:50.060 --> 00:04:51.559 [Amin]: Okay, excellent. 00:04:51.560 --> 00:04:53.799 Let's see. 00:04:53.800 --> 00:04:58.639 Okay. NOTE user-lisp-directory, site-lisp if you're using an older Emacs 00:04:58.640 --> 00:05:03.159 Yeah, so as Sacha mentioned at the moment, my config 00:05:03.160 --> 00:05:07.919 is kind of very minimalist and kind of conservative by 00:05:07.920 --> 00:05:11.439 design, in part because I tend to work on a lot of 00:05:11.440 --> 00:05:14.439 different machines, whether it's for work or 00:05:14.440 --> 00:05:18.119 volunteering or whatever, and I prefer to use Emacs 00:05:18.120 --> 00:05:18.879 if I can. 00:05:18.880 --> 00:05:22.159 So I want my config to be fairly self-contained so I 00:05:22.160 --> 00:05:25.599 can easily either git clone or rsync it over. 00:05:25.600 --> 00:05:27.399 Yeah. 00:05:27.400 --> 00:05:32.279 To keep it simple, I was using package.el for a while 00:05:32.280 --> 00:05:36.479 for installing and managing my packages, which I don't 00:05:36.480 --> 00:05:38.879 keep in my configs repository. 00:05:38.880 --> 00:05:43.239 But then I decided to switch over to very manual 00:05:43.240 --> 00:05:46.759 package management with the awesome new feature 00:05:46.760 --> 00:05:50.399 user-lisp-directory of the next upcoming Emacs release, 00:05:50.400 --> 00:05:52.999 which basically you can give it a subdirectory in your 00:05:53.000 --> 00:05:56.919 .emacs.d or .config/emacs. 00:05:56.920 --> 00:05:59.599 And then it'll go through all the Emacs Lisp files 00:05:59.600 --> 00:06:01.519 recursively, byte compile them, native compile them, 00:06:01.520 --> 00:06:03.719 all that good stuff, and add them to the load path. 00:06:03.720 --> 00:06:06.559 And for people who are using existing or older 00:06:06.560 --> 00:06:11.039 releases of Emacs, there's also site-lisp by Philip 00:06:11.040 --> 00:06:13.959 Kaludercic, which is kind of the... 00:06:13.960 --> 00:06:17.199 I guess first implementation of what later became 00:06:17.200 --> 00:06:19.079 user-lisp and built into Emacs. 00:06:19.080 --> 00:06:22.559 So you can make it conditional and fall back to 00:06:22.560 --> 00:06:27.159 site-lisp if you want to be able to use user-lisp on 00:06:27.160 --> 00:06:29.959 older Emacs but still have your configuration be 00:06:29.960 --> 00:06:30.919 usable. 00:06:30.920 --> 00:06:32.439 Yeah, anyway. NOTE Organizing configuration into modules 00:06:32.440 --> 00:06:35.239 So I've experimented with like a couple different ways 00:06:35.240 --> 00:06:37.319 of managing my configurations like single giant init 00:06:37.320 --> 00:06:40.199 file of like four or five thousand lines which I know 00:06:40.200 --> 00:06:43.199 is actually not very large by comparison to I think 00:06:43.200 --> 00:06:47.239 like someone like Sacha's configuration and also like 00:06:47.240 --> 00:06:50.319 You know, split into multiple different files, which 00:06:50.320 --> 00:06:51.239 has its own benefits. 00:06:51.240 --> 00:06:53.879 And I've kind of actually converged to the approach 00:06:53.880 --> 00:06:55.159 that Prot uses. 00:06:55.160 --> 00:06:59.359 If you actually take a look at my configuration file, 00:06:59.360 --> 00:07:02.239 you see I've drawn a lot of inspiration from Prot 00:07:02.240 --> 00:07:02.839 switches. 00:07:02.840 --> 00:07:06.839 Having a literate single file configuration, which 00:07:06.840 --> 00:07:10.319 then all of the Emacs LISPs source blocks get tangled 00:07:10.320 --> 00:07:11.599 to individual files. 00:07:11.600 --> 00:07:15.719 So I can maintain a single source of truth and edit it 00:07:15.720 --> 00:07:18.799 all in one place, but then also easily be able to 00:07:18.800 --> 00:07:21.559 share individual pieces to people if they want. 00:07:21.560 --> 00:07:23.879 So yeah, that's kind of the general approach. 00:07:23.880 --> 00:07:26.779 And I can dive right in. 00:07:26.780 --> 00:07:28.759 [Sacha]: Yeah, that's definitely the structure that 00:07:28.760 --> 00:07:30.999 I've also stolen from Prot. 00:07:31.000 --> 00:07:32.159 And I like the way that you're 00:07:32.160 --> 00:07:36.759 Your heading names are all long and descriptive, and 00:07:36.760 --> 00:07:39.159 you've got everything broken down in detail. 00:07:39.160 --> 00:07:42.839 So yeah, go ahead and walk us through it, please. 00:07:42.840 --> 00:07:44.679 [Amin]: Yeah, sure. 00:07:44.680 --> 00:07:45.039 Let's see. NOTE early-init #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0014.jpg #+SCREENSHOT_TIME: 00:08:00.067 00:07:45.040 --> 00:07:49.159 So that's a brief introduction, and then I have an 00:07:49.160 --> 00:07:51.879 early init section for doing the early init file. 00:07:51.880 --> 00:07:54.319 There's a couple of subheadings here. 00:07:54.320 --> 00:07:56.559 Actually, let me enlarge the font size a little bit to 00:07:56.560 --> 00:07:57.919 make it more legible. 00:07:57.920 --> 00:07:59.199 OK, great. 00:07:59.200 --> 00:08:03.279 I do a couple of things here like disabling package at 00:08:03.280 --> 00:08:05.999 startup because I don't use package as I mentioned. 00:08:06.000 --> 00:08:10.559 I manually install and update my packages as git 00:08:10.560 --> 00:08:14.559 submodules in my configurations repository. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0015.jpg #+SCREENSHOT_TIME: 00:08:15.567 00:08:14.560 --> 00:08:18.039 I set load-prefer-newer to t to make sure that I 00:08:18.040 --> 00:08:20.199 never load any stale code. 00:08:20.200 --> 00:08:23.759 For example, I might edit some Emacs Lisp file by hand 00:08:23.760 --> 00:08:26.039 and forget to byte compile or native compile it. 00:08:26.040 --> 00:08:29.159 And this tells Emacs to basically just use the version 00:08:29.160 --> 00:08:31.679 of these three variants that's the most recent. 00:08:31.680 --> 00:08:34.639 Yeah. 00:08:34.640 --> 00:08:35.679 Nothing super fancy here. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0016.jpg #+SCREENSHOT_TIME: 00:08:35.700 00:08:35.680 --> 00:08:38.039 I turn off a couple of things that I find a little bit 00:08:38.040 --> 00:08:40.359 distracting, like the menu bar or toolbar. 00:08:40.360 --> 00:08:43.359 Although I do say here that for people who are new to 00:08:43.360 --> 00:08:45.479 Emacs, they're actually super helpful. 00:08:45.480 --> 00:08:48.399 Sure, it's a little bit of visual clutter, but in the 00:08:48.400 --> 00:08:51.599 beginning, it's really, really helpful to help you 00:08:51.600 --> 00:08:54.639 orient yourself of what mode you're in, what tools do 00:08:54.640 --> 00:08:57.359 you have available in your disposal. 00:08:57.360 --> 00:08:59.599 And even someone who's been using Emacs for more than 00:08:59.600 --> 00:09:02.119 10 years, I also use it sometimes when I'm like... 00:09:02.120 --> 00:09:04.119 just starting to use a new mode. 00:09:04.120 --> 00:09:06.179 So yeah, good stuff. NOTE ring-bell-function 00:09:06.180 --> 00:09:09.479 [Sacha]: I was very amused by the comment on the... 00:09:09.480 --> 00:09:11.600 "I don't like getting jumpscared out of my chair." 00:09:11.601 --> 00:09:15.239 You turned off the bell. 00:09:15.240 --> 00:09:17.080 [Amin]: Yeah, because that actually used to happen 00:09:17.120 --> 00:09:19.039 when I first started using Emacs. 00:09:19.040 --> 00:09:21.679 Like when I would, I don't know, I don't even remember 00:09:21.680 --> 00:09:23.639 when it bells or rings, but 00:09:23.640 --> 00:09:28.359 Maybe if you like quit like with C-g or like try to 00:09:28.360 --> 00:09:31.999 backspace into like delete where there's no more 00:09:32.000 --> 00:09:34.959 characters to delete so it rings a bell and it's very 00:09:34.960 --> 00:09:39.999 like can be jarring so yeah I turn that off. NOTE performance optimizations #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0017.jpg #+SCREENSHOT_TIME: 00:09:56.367 00:09:40.000 --> 00:09:41.759 [Sacha]: Yeah, and then you've got a whole bunch of 00:09:41.760 --> 00:09:44.719 things where you set some variables to nil temporarily 00:09:44.720 --> 00:09:47.199 to make it faster, so that's in your startup in garbage 00:09:47.200 --> 00:09:48.839 collection. 00:09:48.840 --> 00:09:50.159 [Amin]: Exactly. 00:09:50.160 --> 00:09:53.359 Empirically, there is no hard and fast science 00:09:53.360 --> 00:09:54.639 behind this. 00:09:54.640 --> 00:09:56.359 I experimented over the years. 00:09:56.360 --> 00:10:00.399 I'm pretty sure I believe the default, for example, 00:10:00.400 --> 00:10:02.839 the garbage collection con threshold is about eight 00:10:02.840 --> 00:10:03.839 megabytes. 00:10:03.840 --> 00:10:06.559 I tried increasing that a little bit to see how much 00:10:06.560 --> 00:10:10.159 If I increase it to what point 00:10:10.160 --> 00:10:12.599 will it make my startup faster? 00:10:12.600 --> 00:10:16.519 And I found this 30 megabytes or mibibytes to be 00:10:16.520 --> 00:10:17.119 kind of a sweet spot. 00:10:17.120 --> 00:10:18.719 So I bumped that up. 00:10:18.720 --> 00:10:21.839 And then after Emacs has finished initializing, in the 00:10:21.840 --> 00:10:25.299 after-init-hook, I just restored the defaults. NOTE user-lisp #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0018.jpg #+SCREENSHOT_TIME: 00:10:51.900 00:10:25.300 --> 00:10:27.500 And then, yeah, this is the bit with 00:10:27.501 --> 00:10:29.599 the user-lisp-directory that I was talking about. 00:10:29.600 --> 00:10:31.519 Awesome stuff. 00:10:31.520 --> 00:10:34.639 So you can basically designate a directory. 00:10:34.640 --> 00:10:36.461 For example, in my configuration, 00:10:36.462 --> 00:10:37.799 it's just a lisp directory. 00:10:37.800 --> 00:10:41.799 And then on startup, Emacs will go through and byte 00:10:41.800 --> 00:10:44.919 compile, native-compile if necessary, and then add all 00:10:44.920 --> 00:10:47.159 of that stuff to the load path automatically. 00:10:47.160 --> 00:10:47.999 So you get that. 00:10:48.000 --> 00:10:51.119 Yeah, and then this is the bit about site-lisp that I 00:10:51.120 --> 00:10:51.879 was talking about. 00:10:51.880 --> 00:10:53.879 So if you want to use user-lisp, but you're still 00:10:53.880 --> 00:10:57.999 using older Emacs versions that you maintain, you need 00:10:58.000 --> 00:11:00.719 to maintain backward compiling in your config. 00:11:00.720 --> 00:11:02.359 This is how you do it, for example. 00:11:02.360 --> 00:11:06.239 So you just yeah, add it to load-path, require it and 00:11:06.240 --> 00:11:08.079 then call prepare-user-lisp. 00:11:08.080 --> 00:11:14.219 That's about it. NOTE ignoring byte compilation warnings 00:11:14.220 --> 00:11:16.279 [Sacha]: I'm picking up that tip about using the 00:11:16.280 --> 00:11:16.999 ignore directories. 00:11:17.000 --> 00:11:19.679 I'm getting by with just ignoring all of the byte 00:11:19.680 --> 00:11:22.519 compilation output, but it would be nice to just say, 00:11:22.520 --> 00:11:23.799 you know, that stuff is test. 00:11:23.800 --> 00:11:26.639 I don't need to worry about it. 00:11:26.640 --> 00:11:29.879 [Amin]: Right, right. Thanks. Yeah, I was also doing 00:11:29.880 --> 00:11:30.519 that. 00:11:30.520 --> 00:11:33.559 I actually have it as a comment to suppress 00:11:33.560 --> 00:11:36.999 warning types, like by compilation, but I was... 00:11:37.000 --> 00:11:39.159 I plan on working on some packages, 00:11:39.160 --> 00:11:40.199 whether my own or others, 00:11:40.200 --> 00:11:42.079 and it would still be helpful to get those warnings, 00:11:42.080 --> 00:11:44.399 so I keep them enabled. It's still a bit annoying. 00:11:44.400 --> 00:11:46.279 I still get some of them when I launch emacs 00:11:46.280 --> 00:11:50.479 but I don't restart or launch emacs as frequently 00:11:50.480 --> 00:11:55.239 so it's pretty bearable. NOTE init-file-debug = --debug-init #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0019.jpg #+SCREENSHOT_TIME: 00:12:00.400 00:11:55.240 --> 00:11:58.319 Yeah, and then I have the main init file. 00:11:58.320 --> 00:12:00.399 And there's not much in it. 00:12:00.400 --> 00:12:05.039 It's just the debug-on-error and debug-on-quit. 00:12:05.040 --> 00:12:08.879 So the debug-on-error thing, I set it to the value of 00:12:08.880 --> 00:12:09.999 init-file-debug. 00:12:10.000 --> 00:12:13.519 And if you look at that, the help for this variable, 00:12:13.520 --> 00:12:18.919 basically if you pass or launch Emacs with 00:12:18.920 --> 00:12:23.039 --debug-init, this variable will be true. 00:12:23.040 --> 00:12:26.279 So yeah. 00:12:26.280 --> 00:12:26.879 [Sacha]: I did not know that. 00:12:26.880 --> 00:12:28.933 Cool. 00:12:28.934 --> 00:12:30.079 [Amin]: Yeah, it's pretty helpful. 00:12:30.080 --> 00:12:32.879 I think, if I'm not mistaken, I took this from 00:12:32.880 --> 00:12:35.559 John Wiegley's .emacs, but I can't remember for sure. 00:12:35.560 --> 00:12:36.239 It's been years. 00:12:36.240 --> 00:12:39.359 Yeah, it's pretty nice. 00:12:39.360 --> 00:12:44.319 And then here, I just set my name and email address. 00:12:44.320 --> 00:12:49.679 And very early I set a custom file to keep all of that 00:12:49.680 --> 00:12:51.959 stuff separate from my .emacs. 00:12:51.960 --> 00:12:53.199 I don't want it mixing in. NOTE Core #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0020.jpg #+SCREENSHOT_TIME: 00:13:03.467 00:12:53.200 --> 00:12:56.359 And then pretty much the only other thing that's in my 00:12:56.360 --> 00:12:59.159 main init file is just to require and load these 00:12:59.160 --> 00:13:03.439 different modules or packages of my configuration. 00:13:03.440 --> 00:13:06.959 I have these as actual packages or as actual features. 00:13:06.960 --> 00:13:08.599 They provide themselves. 00:13:08.600 --> 00:13:10.999 And that's just something that I've found 00:13:11.000 --> 00:13:12.519 straightforward enough to do. 00:13:12.520 --> 00:13:16.879 I know, for example, Prot uses a dual approach. 00:13:16.880 --> 00:13:20.519 He has some of his configuration that's more readily 00:13:20.520 --> 00:13:22.879 usable, available as actual packages. 00:13:22.880 --> 00:13:26.719 And then the other ones, it's just Emacs Lisp code. 00:13:26.720 --> 00:13:28.119 It's not actual packages. 00:13:28.120 --> 00:13:31.599 But for me, I just keep it simple. 00:13:31.600 --> 00:13:36.779 Everything has packages and that's about that. 00:13:36.780 --> 00:13:37.479 [Sacha]: Fantastic. 00:13:37.480 --> 00:13:42.479 Let's dive into some of those configuration modules. 00:13:42.480 --> 00:13:44.359 [Amin]: Sure, let's see. 00:13:44.360 --> 00:13:48.119 Yeah, so this there's this like core thing which is 00:13:48.120 --> 00:13:51.679 kind of included gets included in all of my other 00:13:51.680 --> 00:13:53.579 files. NOTE no longer using bandali-configure; scoping errors, timing execution #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0021.jpg #+SCREENSHOT_TIME: 00:14:27.533 00:13:53.580 --> 00:13:57.199 I wrote a bandali-configure macro 00:13:57.200 --> 00:14:00.359 shamelessly based on prot-emacs-configure which 00:14:00.360 --> 00:14:05.079 is what Prot uses and it basically is a way of kind of 00:14:05.080 --> 00:14:07.919 similar to use package for like wrapping a bunch of 00:14:07.920 --> 00:14:11.399 relevant like Emacs Lisp code all together. 00:14:11.400 --> 00:14:17.359 It has the benefit, if you use it, if there is an 00:14:17.360 --> 00:14:22.279 error in that block or in the body basically, then it 00:14:22.280 --> 00:14:23.559 won't crash everything. 00:14:23.560 --> 00:14:26.959 That body will just get ignored and we display an 00:14:26.960 --> 00:14:27.519 error. 00:14:27.520 --> 00:14:30.799 And that's also the main reason that Prot uses it. 00:14:30.800 --> 00:14:35.439 The one thing that I added extra to mine, which I took 00:14:35.440 --> 00:14:40.439 with inspiration from Echelle Yaron's ESY slash init 00:14:40.440 --> 00:14:47.879 step, is to wrap it up in basically time the execution 00:14:47.880 --> 00:14:51.119 of each of these blocks, which can be pretty helpful 00:14:51.120 --> 00:14:54.919 to help you see, okay, which part of my configuration 00:14:54.920 --> 00:14:56.559 is particularly slow. 00:14:56.560 --> 00:14:59.519 Usage examples. 00:14:59.520 --> 00:15:00.799 I just have it here. 00:15:00.800 --> 00:15:04.799 You can either basically pass it like a symbol like 00:15:04.800 --> 00:15:08.319 thing or you can also pass in a string as the first 00:15:08.320 --> 00:15:09.239 argument. 00:15:09.240 --> 00:15:12.479 And this is what will be displayed when you display a 00:15:12.480 --> 00:15:16.919 list of the evaluation times for all of these 00:15:16.920 --> 00:15:18.979 blocks in your configuration. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0022.jpg #+SCREENSHOT_TIME: 00:15:22.133 00:15:18.980 --> 00:15:22.119 Yeah, and then I have a neat little function 00:15:22.120 --> 00:15:24.719 here like configure-report-times 00:15:24.720 --> 00:15:28.200 that will report these times, 00:15:28.201 --> 00:15:29.600 whether in the order that it's 00:15:29.601 --> 00:15:31.367 encountered them, or you can have it 00:15:31.368 --> 00:15:33.600 sort by fastest to slowest, 00:15:33.601 --> 00:15:36.399 slowest to fastest, blah blah blah. 00:15:36.400 --> 00:15:37.559 [Sacha]: You mentioned you're no longer using this. 00:15:37.560 --> 00:15:41.439 Is it because you wanted it to be easier to 00:15:41.440 --> 00:15:43.119 copy and paste your code? 00:15:43.120 --> 00:15:45.639 What got you to shift back to the regular vanilla type 00:15:45.640 --> 00:15:47.640 of configuration? 00:15:47.680 --> 00:15:53.279 [Amin]: Right, as neat as it is, I didn't find it 00:15:53.280 --> 00:15:56.959 super useful. For one thing, because I don't add or 00:15:56.960 --> 00:16:00.999 remove a ton of stuff to my Emacs configuration 00:16:01.000 --> 00:16:04.759 regularly, so if there is an error, it wouldn't cause 00:16:04.760 --> 00:16:06.799 an issue for the rest of my configuration. I didn't 00:16:06.800 --> 00:16:11.199 really find that very useful. 00:16:11.200 --> 00:16:14.279 And then my other potential concern is that the way I 00:16:14.280 --> 00:16:18.159 was structuring things, I would put all of the 00:16:18.160 --> 00:16:21.079 configuration, let's say for GNU, in one of these 00:16:21.080 --> 00:16:21.799 blocks. 00:16:21.800 --> 00:16:25.759 But I wanted to be able to break that down into, for 00:16:25.760 --> 00:16:28.279 example, Org Mode sections more easily. 00:16:28.280 --> 00:16:32.759 So far, I just decided to not use it. 00:16:32.760 --> 00:16:35.119 I know I could technically break those down into 00:16:35.120 --> 00:16:38.559 smaller blocks, but I haven't done that yet. 00:16:38.560 --> 00:16:41.319 [Sacha]: Ihor says, this configure macro looks a lot 00:16:41.320 --> 00:16:43.599 like good old use package, which you're not even using 00:16:43.600 --> 00:16:44.919 in the rest of your config. 00:16:44.920 --> 00:16:47.519 And I hear you about wanting to be able to split 00:16:47.520 --> 00:16:50.639 things into smaller blocks with more explanations in 00:16:50.640 --> 00:16:51.279 between them. 00:16:51.280 --> 00:16:53.719 So in my config, yeah, sure, I've got the use-package 00:16:53.720 --> 00:16:55.799 there to do the ensure and all that stuff. 00:16:55.800 --> 00:16:59.279 But I also have with-eval-after-load because I still 00:16:59.280 --> 00:17:01.719 want, you know, the links and the screenshots in 00:17:01.720 --> 00:17:02.759 between. NOTE Why not use use-package 00:17:02.760 --> 00:17:06.728 [Amin]: Right. Yeah, exactly. use-package is awesome. 00:17:06.729 --> 00:17:08.791 I have used that in the past, 00:17:08.792 --> 00:17:11.479 especially when I was using the straight.el 00:17:11.480 --> 00:17:15.999 package manager. It pairs nicely with it. But yeah, 00:17:16.000 --> 00:17:17.999 since then, I found it a little bit like too magical 00:17:18.000 --> 00:17:21.279 for my tastes, kind of along the lines of 00:17:21.280 --> 00:17:23.159 declaring an init file bankruptcy at some point I 00:17:23.160 --> 00:17:24.279 really wanted to 00:17:24.280 --> 00:17:27.039 understand every single line that I have in my Emacs 00:17:27.040 --> 00:17:27.839 configuration. 00:17:27.840 --> 00:17:31.359 And at the time, I didn't know a whole lot about 00:17:31.360 --> 00:17:33.999 macros or wasn't very well-versed with them. 00:17:34.000 --> 00:17:36.879 So I just ditched it in favor of simply using, as you 00:17:36.880 --> 00:17:38.479 mentioned, with-eval-after-load. 00:17:38.480 --> 00:17:42.359 And then that causes all that code to be basically 00:17:42.360 --> 00:17:45.279 delayed, not evaluated immediately, but when that 00:17:45.280 --> 00:17:46.679 package is loaded. 00:17:46.680 --> 00:17:50.439 And then as to when to pull that package in, depending 00:17:50.440 --> 00:17:52.879 on if I want it right from the get-go of my Emacs 00:17:52.880 --> 00:17:54.319 starts, then I would require it. 00:17:54.320 --> 00:17:56.959 Otherwise, I add this, as you also mentioned earlier, 00:17:56.960 --> 00:18:00.119 this kind of timer thing where if Emacs is idle for, I 00:18:00.120 --> 00:18:03.559 don't know, 0.2 seconds or 0.4 seconds, then go ahead 00:18:03.560 --> 00:18:06.279 and require this package. 00:18:06.280 --> 00:18:07.479 [Sacha]: Ihor has a tip in the chat. 00:18:07.480 --> 00:18:11.479 Of course, Ihor has an Org way to do this. 00:18:11.480 --> 00:18:14.919 He uses use-package whatever config and then he has a 00:18:14.920 --> 00:18:17.439 noweb reference to the Babel blocks. 00:18:17.440 --> 00:18:23.279 Then he just says :tangle no on the source blocks so 00:18:23.280 --> 00:18:24.799 that they don't actually get repeated. 00:18:24.800 --> 00:18:27.479 Anyway, you can look at it later when you go through. 00:18:27.480 --> 00:18:29.039 I'll send you the comments or whatever. 00:18:29.040 --> 00:18:31.119 But show us how you're actually configuring things 00:18:31.120 --> 00:18:37.819 since you're not using this. NOTE Defining multiple keybindings #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0023.jpg #+SCREENSHOT_TIME: 00:18:55.133 00:18:37.820 --> 00:18:39.067 [Amin]: Then I just have another 00:18:39.068 --> 00:18:42.479 quick macro thingy here, bandali-define-keys, which 00:18:42.480 --> 00:18:47.759 wraps around Emacs's define-key. It affords me the 00:18:47.760 --> 00:18:52.799 convenience of defining multiple key bindings, and 00:18:52.800 --> 00:18:55.119 Prot's version of this (I think it's 00:18:55.120 --> 00:19:00.239 prot-emacs-keybind, or something like that) he 00:19:00.240 --> 00:19:05.399 imposes the limitation that the keys should be valid 00:19:05.400 --> 00:19:08.199 strings that can be passed to the =kbd= function, 00:19:08.200 --> 00:19:12.639 which is very fair and valid, but I wanted to not 00:19:12.640 --> 00:19:15.559 impose that, to keep the flexibility of using 00:19:15.560 --> 00:19:18.079 define-key directly. 00:19:18.080 --> 00:19:23.119 The consequences of that, as we can see, is we can 00:19:23.120 --> 00:19:25.599 pass in the old representation of key bindings, like 00:19:25.600 --> 00:19:29.839 the vector or whatever syntax, which Prot's doesn't 00:19:29.840 --> 00:19:32.479 support by choice, whereas mine does. 00:19:32.480 --> 00:19:35.799 Let's see. 00:19:35.800 --> 00:19:42.279 For example, let's look at the Bandali theme, which is 00:19:42.280 --> 00:19:42.719 all about... 00:19:42.720 --> 00:19:45.899 The appearance, I guess, of Emacs. NOTE doric-oak uses emphasis instead of colours #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0024.jpg #+SCREENSHOT_TIME: 00:19:45.900 00:19:45.900 --> 00:19:48.119 Yeah, so I just have a conditional block where, you 00:19:48.120 --> 00:19:50.039 know, if you're in a graphical environment, I'll just 00:19:50.040 --> 00:19:53.399 go ahead and load Prot's Doric themes, specifically 00:19:53.400 --> 00:19:55.719 Doric Oak, which is what we're seeing right now. 00:19:55.720 --> 00:19:59.079 I'm using, it's very beautiful, it's very subtle, and 00:19:59.080 --> 00:20:02.159 it uses emphasis, bolding and stuff to draw 00:20:02.160 --> 00:20:05.239 your eye to something instead of using a million 00:20:05.240 --> 00:20:07.439 different colors, which I find pretty nice. 00:20:07.440 --> 00:20:14.039 Yeah, and then for example here I set up some fonts. 00:20:14.040 --> 00:20:17.319 I use this Sahel font for Persian and Arabic 00:20:17.320 --> 00:20:17.759 text. 00:20:17.760 --> 00:20:23.359 I set a color emoji font here and this is like we get 00:20:23.360 --> 00:20:25.479 a kind of preview of what I do. 00:20:25.480 --> 00:20:28.279 It's like with-eval-after-load faces and then blah 00:20:28.280 --> 00:20:30.139 blah blah. 00:20:30.140 --> 00:20:31.536 [Sacha]: Ihor would like to point out that 00:20:31.537 --> 00:20:33.841 with-eval-after-load is also a macro 00:20:33.842 --> 00:20:35.399 that calls another macro. 00:20:35.400 --> 00:20:39.519 So I'm just going to mention it because it's there. 00:20:39.520 --> 00:20:41.679 These are your fonts. 00:20:41.680 --> 00:20:43.879 This is your theme. 00:20:43.880 --> 00:20:46.799 This is great because everyone always asks, what theme 00:20:46.800 --> 00:20:47.279 is this? 00:20:47.280 --> 00:20:48.159 What font is this? 00:20:48.160 --> 00:20:49.159 All right. NOTE global font scaling instead of the local ones #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0025.jpg #+SCREENSHOT_TIME: 00:20:59.967 00:20:49.160 --> 00:20:52.159 I like your text scaling tweaks that you're just about 00:20:52.160 --> 00:20:56.459 to go into. You've changed the global mappings. 00:20:56.460 --> 00:20:56.919 [Amin]: Yeah, yeah, yeah. 00:20:56.920 --> 00:20:58.439 And I actually took this from Prot as well. 00:20:58.440 --> 00:20:59.959 And it makes a lot more sense. 00:20:59.960 --> 00:21:03.239 So by default, this, C-x C-+, -, 00:21:03.240 --> 00:21:05.759 blah, blah, blah, it only scales the text 00:21:05.760 --> 00:21:07.679 for the current buffer only. 00:21:07.680 --> 00:21:12.839 But in newer version of Emacs, in Emacs 29, they also 00:21:12.840 --> 00:21:16.115 added commands to adjust this globally, including 00:21:16.116 --> 00:21:17.866 the mode line and all that stuff, 00:21:17.867 --> 00:21:19.359 which is usually what I want, 00:21:19.360 --> 00:21:21.719 for example, in this presentation or when I'm sharing 00:21:21.720 --> 00:21:22.559 my screen right now. 00:21:22.560 --> 00:21:24.479 It scales everything up globally. 00:21:24.480 --> 00:21:28.959 So yeah, I just swapped these to be the default, and 00:21:28.960 --> 00:21:32.119 then I add keybinds for the just local variants in 00:21:32.120 --> 00:21:36.359 case I need to use that. 00:21:36.360 --> 00:21:37.119 Yep. NOTE display-fill-column-indicator 00:21:37.120 --> 00:21:39.239 And then here I have display-fill-column-indicator. 00:21:39.240 --> 00:21:42.559 I don't know, maybe this is just me, but sometimes I'm 00:21:42.560 --> 00:21:45.519 kind of OCD about keeping my text lined up at exactly, 00:21:45.520 --> 00:21:49.079 for example, the 70 characters column. 00:21:49.080 --> 00:21:52.479 I care a lot about that, especially if I'm writing 00:21:52.480 --> 00:21:56.479 code or text that I want to also visually look nice. 00:21:56.480 --> 00:21:57.999 And I enable this. 00:21:58.000 --> 00:22:02.399 And let's see, I enable it for prog-mode. 00:22:02.400 --> 00:22:08.439 So yeah, I guess if I, for example, do this... 00:22:08.440 --> 00:22:11.159 This little thin line that we see here, that's the 00:22:11.160 --> 00:22:13.559 display filler column indicator. 00:22:13.560 --> 00:22:17.159 I used to have it globally enabled, but then I found 00:22:17.160 --> 00:22:20.239 that a bit too much, so I just enable it with a hook 00:22:20.240 --> 00:22:22.759 in the modes that I want. 00:22:22.760 --> 00:22:25.033 [Sacha]: Yeah, and the theme makes it very subtle. 00:22:25.034 --> 00:22:26.967 It's just there as a reminder, 00:22:26.968 --> 00:22:27.900 don't go beyond this line. 00:22:27.901 --> 00:22:31.367 You can if you really want to, but just try not to. 00:22:31.368 --> 00:22:39.579 [Amin]: Yeah, exactly. And then my essentials... 00:22:39.580 --> 00:22:42.999 This is where I configure a lot of key 00:22:43.000 --> 00:22:46.439 behaviors of Emacs, all built-in stuff for the most 00:22:46.440 --> 00:22:49.119 part, or things that are key to my workflows. 00:22:49.120 --> 00:22:52.119 For example, I always want to start with a scratch 00:22:52.120 --> 00:22:53.759 buffer. NOTE emacsclient for EDITOR and VISUAL #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0026.jpg #+SCREENSHOT_TIME: 00:22:53.767 00:22:53.760 --> 00:22:57.439 Start the Emacs server if it's not running. 00:22:57.440 --> 00:23:01.599 And this is very useful, very helpful so that then you 00:23:01.600 --> 00:23:04.959 can call into an existing Emacs process with 00:23:04.960 --> 00:23:07.439 Emacs client and have it edit a file. 00:23:07.440 --> 00:23:10.079 I don't use it for anything fancy just yet. 00:23:10.080 --> 00:23:12.919 I believe Prot also mentioned in his video with you, 00:23:12.920 --> 00:23:16.239 Sacha, that he uses it for things like org-capture to 00:23:16.240 --> 00:23:20.519 spawn a new buffer in his existing Emacs session 00:23:20.520 --> 00:23:22.039 and things like that. 00:23:22.040 --> 00:23:23.879 You can do pretty cool things with it. 00:23:23.880 --> 00:23:28.519 But yeah, I just use it for being able to easily use 00:23:28.520 --> 00:23:31.799 my Emacs as editor and visual text editors. 00:23:31.800 --> 00:23:37.759 So yeah, this sets that up. NOTE fundamental-mode-hook #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0027.jpg #+SCREENSHOT_TIME: 00:23:42.200 00:23:37.760 --> 00:23:38.719 Adding a fundamental mode hook. 00:23:38.720 --> 00:23:40.619 Again, I took this from Prot. 00:23:40.620 --> 00:23:42.199 [Sacha]: I was surprised by that because I was like, 00:23:42.200 --> 00:23:44.519 oh, there isn't a fundamental-mode-hook? 00:23:44.520 --> 00:23:47.519 Okay, that makes sense now. 00:23:47.520 --> 00:23:49.067 [Amin]: Right, right. 00:23:49.068 --> 00:23:52.319 Yeah, there isn't a fundamental-mode-hook by design. 00:23:52.320 --> 00:23:55.119 But I still, in the past, have found that I wanted 00:23:55.120 --> 00:23:55.319 that. 00:23:55.320 --> 00:23:57.959 For example, for this display-fill-column-indicator, 00:23:57.960 --> 00:24:00.319 when I had it enabled everywhere, I was like, it would 00:24:00.320 --> 00:24:02.639 be nice if I could at least disable it for fundamental 00:24:02.640 --> 00:24:02.959 mode. 00:24:02.960 --> 00:24:04.399 And at the time, I didn't have this. 00:24:04.400 --> 00:24:05.999 I added this just recently. 00:24:06.000 --> 00:24:08.599 So if I decide to go back to using something globally, 00:24:08.600 --> 00:24:11.239 but I don't want it in fundamental-mode, then I can 00:24:11.240 --> 00:24:13.919 disable it using this. 00:24:13.920 --> 00:24:18.359 Yeah, and then some standard stuff like I prefer 00:24:18.360 --> 00:24:23.579 spaces and a tab with four characters. NOTE indicate-buffer-boundaries #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0008.jpg #+SCREENSHOT_TIME: 00:22:02.433 00:24:23.580 --> 00:24:25.319 Visually indicate buffer boundaries. 00:24:25.320 --> 00:24:28.801 This is a little bit hard to see right now, 00:24:28.802 --> 00:24:31.020 but here at the bottom left NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0009.jpg #+SCREENSHOT_TIME: 00:22:02.433 #+SCREENSHOT_CROP: 2 750 200 850 00:24:31.021 --> 00:24:33.159 you see a little down arrow NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0012.jpg #+SCREENSHOT_TIME: 00:24:33.800 #+SCREENSHOT_CROP: 10 37 111 113 00:24:33.160 --> 00:24:34.799 and then the little top arrow. 00:24:34.800 --> 00:24:41.619 And... Let's see if I can. 00:24:41.620 --> 00:24:44.319 [Sacha]: Oh! NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0010.jpg #+SCREENSHOT_TIME: 00:24:43.167 #+SCREENSHOT_CROP: 6 43 500 180 00:24:44.320 --> 00:24:46.559 [Amin]: And also here, for example, when it all fits 00:24:46.560 --> 00:24:47.239 in the view. 00:24:47.240 --> 00:24:49.759 [Sacha]: Huh, that is cool. 00:24:49.760 --> 00:24:50.919 I was looking at that. 00:24:50.920 --> 00:24:51.919 What does it do? 00:24:51.920 --> 00:24:54.799 And so that tells you, you can still scroll up or you 00:24:54.800 --> 00:24:57.039 can still scroll down, and you don't have to look at 00:24:57.040 --> 00:24:58.799 the scroll bar to see where you are. 00:24:58.800 --> 00:25:01.679 It just says there's more there. 00:25:01.680 --> 00:25:03.399 [Amin]: Yeah, exactly. 00:25:03.400 --> 00:25:03.839 Yeah. 00:25:03.840 --> 00:25:06.359 And it also helps distinguish when there's a newline 00:25:06.360 --> 00:25:08.119 character at the end of the file or not. 00:25:08.120 --> 00:25:09.799 So here in this buffer, there is. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0013.jpg #+SCREENSHOT_TIME: 00:25:10.533 #+SCREENSHOT_CROP: 6 39 500 180 00:25:09.800 --> 00:25:14.199 But if I delete that, you see this indicator here 00:25:14.200 --> 00:25:15.639 changed shape. 00:25:15.640 --> 00:25:18.479 But if I go back and add the new line again. 00:25:18.480 --> 00:25:21.639 So yeah, that's also been very helpful for me because 00:25:21.640 --> 00:25:23.959 I added configuration files and some of these pieces 00:25:23.960 --> 00:25:26.199 of software are sensitive to having a new line at the 00:25:26.200 --> 00:25:26.959 end of the file. 00:25:26.960 --> 00:25:31.099 So yeah, it's very helpful and useful for that. 00:25:31.100 --> 00:25:34.119 [Sacha]: I would not have guessed that from the very 00:25:34.120 --> 00:25:36.959 short line in your config that turns that on. 00:25:36.960 --> 00:25:38.678 It's one line, setq-default 00:25:38.679 --> 00:25:43.079 indicate-buffer-boundaries 'left, and yet it adds this nice little 00:25:43.080 --> 00:25:46.219 nuance to the way that fringe looks. 00:25:46.220 --> 00:25:46.719 [Amin]: Right. 00:25:46.720 --> 00:25:47.839 Yeah, absolutely. 00:25:47.840 --> 00:25:50.799 Perhaps I should expand more on it at some point later 00:25:50.800 --> 00:25:52.399 to explain these things. 00:25:52.400 --> 00:25:54.859 But yeah, just this one line. 00:25:54.860 --> 00:25:59.059 [Sacha]: May I recommend screenshots? 00:25:59.060 --> 00:26:00.519 [Amin]: Yes, you may, for sure. Yeah, I will 00:26:00.520 --> 00:26:04.959 definitely do that as well, 00:26:04.960 --> 00:26:07.067 because I'm also a bit of a visual person. 00:26:07.068 --> 00:26:08.733 I like seeing screenshots and videos, 00:26:08.734 --> 00:26:10.159 so yeah I'll take that to heart 00:26:10.160 --> 00:26:12.299 and do that for my own configuration as well. 00:26:12.300 --> 00:26:15.500 [Sacha]: When I post this, I'll probably... I figured 00:26:15.501 --> 00:26:18.033 out how to have the transcripts and then screenshots 00:26:18.034 --> 00:26:19.433 embedded into my transcript. 00:26:19.434 --> 00:26:22.033 I'll generate it automatically from the subtitle file. 00:26:22.034 --> 00:26:24.633 Our EmacsConf transcripts are going to get so fancy 00:26:24.634 --> 00:26:28.300 next year. But you can pull those screenshots 00:26:28.301 --> 00:26:31.719 and drop them into your config. It'll be great. 00:26:31.720 --> 00:26:36.419 [Amin]: Nice. Yeah, for sure. Sounds good. NOTE enabling and disabling commands #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0028.jpg #+SCREENSHOT_TIME: 00:26:36.433 00:26:36.420 --> 00:26:38.600 And then here, I just enabled some of these 00:26:38.601 --> 00:26:40.733 commands that are disabled by default. 00:26:40.734 --> 00:26:45.800 So yeah, it's useful, especially narrow-to-page, 00:26:45.801 --> 00:26:47.267 for example, or narrow-to-region. 00:26:47.268 --> 00:26:49.433 These are commands where Emacs disables them 00:26:49.434 --> 00:26:52.833 by default so that newcomers 00:26:52.834 --> 00:26:55.100 don't accidentally hit them and get very 00:26:55.101 --> 00:26:57.133 confused by what just happened. 00:26:57.134 --> 00:26:59.500 It doesn't disable them for good. 00:26:59.501 --> 00:27:01.733 It just basically prompts you for confirmation. 00:27:01.734 --> 00:27:04.267 Are you sure you want to run this command? 00:27:04.268 --> 00:27:06.900 I'm sure, at least about these commands. 00:27:06.901 --> 00:27:08.167 So I just enabled them. 00:27:08.168 --> 00:27:11.233 And then something like, for example, overwrite-mode, 00:27:11.234 --> 00:27:12.800 which I never use 00:27:12.801 --> 00:27:14.267 and I don't want to accidentally enable. 00:27:14.268 --> 00:27:16.667 I just put it disabled so that if I do accidentally 00:27:16.668 --> 00:27:19.300 hit the keys, which might be, I don't know, something 00:27:19.301 --> 00:27:23.000 insert or whatever, then it will prompt me 00:27:23.001 --> 00:27:25.899 to make sure that I meant to do that. 00:27:25.900 --> 00:27:28.233 [Sacha]: That reminds me, I should probably turn that 00:27:28.234 --> 00:27:30.833 off for myself and then you get a whole new keyboard 00:27:30.834 --> 00:27:33.979 shortcut you can use too. 00:27:33.980 --> 00:27:36.933 [Amin]: Right, yeah. 00:27:36.934 --> 00:27:37.879 Let's see. NOTE package-review-policy #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0029.jpg #+SCREENSHOT_TIME: 00:27:37.900 00:27:37.880 --> 00:27:42.999 Yeah, I have just one line setting for package.el. 00:27:43.000 --> 00:27:46.279 In Emacs 31, we will be getting a package review policy 00:27:46.280 --> 00:27:47.439 which is very helpful. 00:27:47.440 --> 00:27:50.479 So if you do use package.el for installing packages 00:27:50.480 --> 00:27:54.159 from GNU ELPA, NonGNU ELPA, MELPA or whatever else, 00:27:54.160 --> 00:27:56.359 you can enable this, and then whenever you update your 00:27:56.360 --> 00:28:00.679 packages, you'll get a diff of what changed in this 00:28:00.680 --> 00:28:03.719 new revision of the package that you're downloading 00:28:03.720 --> 00:28:05.519 and you're about to enable. 00:28:05.520 --> 00:28:08.039 And you can presumably say yes or 00:28:08.040 --> 00:28:11.579 at least see what's going on, which I find helpful. 00:28:11.580 --> 00:28:13.759 [Sacha]: But you're not using packages, you mentioned, 00:28:13.760 --> 00:28:20.919 so you're just checking everything out and then you're 00:28:20.920 --> 00:28:21.979 just git pulling whenever you feel like it. 00:28:21.980 --> 00:28:24.239 [Amin]: Yeah, so right now I'm using git pulls and git 00:28:24.240 --> 00:28:26.079 submodules, very manual. 00:28:26.080 --> 00:28:29.999 I put this here because I think it's generally a very 00:28:30.000 --> 00:28:33.679 welcome change and awesome new feature that I want to 00:28:33.680 --> 00:28:34.959 spread the word about. 00:28:34.960 --> 00:28:38.239 So maybe someone who's looking at my config, they use 00:28:38.240 --> 00:28:40.159 package and that's perfectly fine. 00:28:40.160 --> 00:28:42.199 So this is just here to spread the word about it 00:28:42.200 --> 00:28:43.159 mainly, I guess. 00:28:43.160 --> 00:28:45.439 And if I start using package at some point myself in 00:28:45.440 --> 00:28:50.839 the future, then I will have this enabled. 00:28:50.840 --> 00:28:52.760 Let's see. NOTE getting the Info files from the Emacs source directory #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0030.jpg #+SCREENSHOT_TIME: 00:28:52.800 00:28:52.800 --> 00:28:58.239 Very quickly, here I extend Info-directory-list. 00:28:58.240 --> 00:29:01.919 I like to, at least on some of my machines, 00:29:01.920 --> 00:29:05.399 use Emacs that I built from source directly in the 00:29:05.400 --> 00:29:08.599 source repository of Emacs. 00:29:08.600 --> 00:29:12.639 Just after doing make, I don't run make install, 00:29:12.640 --> 00:29:14.919 even though it's very easy to do that. 00:29:14.920 --> 00:29:17.919 You can install to a custom location by providing dash 00:29:17.920 --> 00:29:20.399 dash prefix when you're configuring Emacs. 00:29:20.400 --> 00:29:22.999 Sometimes I just find it more convenient for me to not 00:29:23.000 --> 00:29:26.039 do that and just run make and then exit and reopen 00:29:26.040 --> 00:29:26.959 Emacs. 00:29:26.960 --> 00:29:30.519 And for that kind of a setup, I just extend the info 00:29:30.520 --> 00:29:33.879 directory list to include the info subdirectory of the 00:29:33.880 --> 00:29:37.359 Emacs source repository so that the built-in Emacs 00:29:37.360 --> 00:29:45.119 info manuals will be available to me. NOTE recentf, adding directories #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0031.jpg #+SCREENSHOT_TIME: 00:29:46.600 00:29:45.120 --> 00:29:46.600 And then I use recentf 00:29:46.601 --> 00:29:52.039 for tracking recent revisited files. 00:29:52.040 --> 00:29:54.560 I bind it to C-c f r e 00:29:54.600 --> 00:30:00.239 for me to get a pop-up completion for visiting a 00:30:00.240 --> 00:30:03.759 recent file, it has completion. 00:30:03.760 --> 00:30:08.079 So if I hit TAB here, for example, we can see some of 00:30:08.080 --> 00:30:11.499 these files or directories that I visited recently. 00:30:11.500 --> 00:30:13.200 [Sacha]: I see. 00:30:13.201 --> 00:30:16.399 And then you're adding the directory to it. 00:30:16.400 --> 00:30:19.519 So what does that let you do? 00:30:19.520 --> 00:30:21.999 Because I'm assuming you're already in there in the 00:30:22.000 --> 00:30:22.759 directory. 00:30:22.760 --> 00:30:26.819 But how does that change your recentf? 00:30:26.820 --> 00:30:30.279 [Amin]: Right. So I need to think to remember this, 00:30:30.280 --> 00:30:34.239 but I think the point of this was that if I 00:30:34.240 --> 00:30:39.759 open a project in VC or in Dired, then I 00:30:39.760 --> 00:30:43.039 would like that directory to also get added to my 00:30:43.040 --> 00:30:46.719 recentf files list, because I think by default, 00:30:46.720 --> 00:30:54.399 recentf only includes files, not directories. 00:30:54.400 --> 00:30:57.319 [Sacha]: You're in it, you start up Magit or whatever, 00:30:57.320 --> 00:31:00.079 and then you move on to something else, but you want 00:31:00.080 --> 00:31:03.339 to be able to easily go back to it. 00:31:03.340 --> 00:31:06.239 [Amin]: Yeah, for example, I like to keep my recently 00:31:06.240 --> 00:31:09.159 visited directories in recentf as well. 00:31:09.160 --> 00:31:11.759 Because that's one of the main ways I jump between 00:31:11.760 --> 00:31:14.159 projects and stuff, even though there is literally a 00:31:14.160 --> 00:31:16.319 built-in Emacs project mode, which I still use. 00:31:16.320 --> 00:31:19.919 The only thing that I have here is... 00:31:19.920 --> 00:31:25.879 I don't want to add my home directory to the recently 00:31:25.880 --> 00:31:29.599 visited list, so the only thing that this function 00:31:29.600 --> 00:31:34.319 does is to skip that if I'm opening the home directory. 00:31:34.320 --> 00:31:38.439 That's about it. NOTE Scrolling #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0033.jpg #+SCREENSHOT_TIME: 00:32:10.933 00:31:38.440 --> 00:31:41.759 And then here I configure mouse and scrolling behavior. 00:31:41.760 --> 00:31:47.159 So I want Emacs to scroll very gently, one line at a 00:31:47.160 --> 00:31:47.679 time. 00:31:47.680 --> 00:31:50.679 I think the default is that when you reach the end of 00:31:50.680 --> 00:31:53.799 the page, it'll jump half a page down and then 00:31:53.800 --> 00:31:54.439 recenter. 00:31:54.440 --> 00:31:57.999 I don't remember default behavior because I don't use 00:31:58.000 --> 00:32:01.599 it very much, but yeah, this basically makes it 00:32:01.600 --> 00:32:03.919 very predictable. For example, when I reach 00:32:03.920 --> 00:32:07.039 the edge of the page here and I press C-n, 00:32:07.040 --> 00:32:10.919 it'll only scroll one line at a time, instead of 00:32:10.920 --> 00:32:13.399 jumping and then doing something like 00:32:13.400 --> 00:32:14.800 this. 00:32:14.801 --> 00:32:17.359 [Sacha]: Oh yeah, mine does! Mine doesn't do that, so 00:32:17.360 --> 00:32:19.879 it does that jumping thing. I see what you mean 00:32:19.880 --> 00:32:22.200 here. Interesting. 00:32:22.201 --> 00:32:25.599 [Amin]: Yeah, so you can tweak that with scroll conservatively 00:32:25.600 --> 00:32:28.599 and then scroll preserve screen position, I believe. NOTE auto revert #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0034.jpg #+SCREENSHOT_TIME: 00:32:37.733 00:32:28.600 --> 00:32:36.239 Yeah, and then I use autorevert, which is pretty 00:32:36.240 --> 00:32:37.719 helpful. 00:32:37.720 --> 00:32:41.239 So this will have Emacs watch, for example, files that 00:32:41.240 --> 00:32:43.679 are open in your buffers. 00:32:43.680 --> 00:32:46.799 And if they change on disk, Emacs will automatically 00:32:46.800 --> 00:32:49.959 refresh the buffer so that you get the latest version. 00:32:49.960 --> 00:32:53.199 The cool thing is you can press undo in one of these 00:32:53.200 --> 00:32:56.119 files that's been autoreverted so that you get the 00:32:56.120 --> 00:32:58.959 revision that was there right before the change. 00:32:58.960 --> 00:33:03.139 So I've used that sometimes as well. 00:33:03.140 --> 00:33:05.919 [Sacha]: Yeah, and sometimes autofollow also is nice 00:33:05.920 --> 00:33:08.119 for log files and things like that. 00:33:08.120 --> 00:33:12.519 But yeah, autoreverting is great. 00:33:12.520 --> 00:33:14.059 [Amin]: Yeah, for sure. NOTE Repeat mode #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0035.jpg #+SCREENSHOT_TIME: 00:33:14.067 00:33:14.060 --> 00:33:16.959 Repeat mode is something that I've only recently 00:33:16.960 --> 00:33:20.639 started using, especially with my Emacs EXWM setup, 00:33:20.640 --> 00:33:22.959 using Emacs as my window manager. 00:33:22.960 --> 00:33:26.599 For example, if I hit C-x o, we see here in the 00:33:26.600 --> 00:33:31.319 echo area where it says repeat with o or capital O. So 00:33:31.320 --> 00:33:35.159 I can now only press o instead of saying C-x o, 00:33:35.160 --> 00:33:39.319 C-x o to do that multiple times. 00:33:39.320 --> 00:33:43.559 Keymaps that have support for this basically indicate 00:33:43.560 --> 00:33:47.919 that they want to be repeatable can declare that. 00:33:47.920 --> 00:33:51.439 And then once you invoke one of the keys in those 00:33:51.440 --> 00:33:54.279 keymaps, then you can repeat it with just that single 00:33:54.280 --> 00:33:55.039 character. 00:33:55.040 --> 00:33:57.879 And for example, for my setup, I have that with my 00:33:57.880 --> 00:34:01.359 EXWM workspace switching keys. 00:34:01.360 --> 00:34:05.599 So I can easily go to the next and previous 00:34:05.600 --> 00:34:08.519 workspaces, many of them at a time by just pressing P 00:34:08.520 --> 00:34:13.399 and N instead of doing the shortcut multiple times. 00:34:13.400 --> 00:34:16.479 [Sacha]: And actually, if you don't mind jumping 00:34:16.480 --> 00:34:20.679 ahead, the EXWM part of your config is fairly complex, 00:34:20.680 --> 00:34:25.439 and I think not a lot of people have a lot of 00:34:25.440 --> 00:34:27.599 experience seeing EXWM in action. 00:34:27.600 --> 00:34:31.039 And I don't know whether you're comfortable sharing 00:34:31.040 --> 00:34:33.439 you switching around to different workspaces, but if 00:34:33.440 --> 00:34:35.839 that is something that you can do, how are you doing 00:34:35.840 --> 00:34:38.719 all this awesomeness? 00:34:38.720 --> 00:34:43.479 I'm still too scared to use EXWM myself. 00:34:43.480 --> 00:34:44.359 Stability. 00:34:44.360 --> 00:34:51.319 But that's a me problem, not an EXWM problem. NOTE EXWM #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0036.jpg #+SCREENSHOT_TIME: 00:35:26.600 00:34:51.320 --> 00:34:53.799 [Amin]: Yeah, EXWM was pretty awesome. 00:34:53.800 --> 00:34:57.519 I used it back in 2018, '19 for a while, and then I 00:34:57.520 --> 00:35:00.079 kind of moved on to Sway and Wayland. 00:35:00.080 --> 00:35:02.159 But I don't know. 00:35:02.160 --> 00:35:04.759 It's something that I feel like once you try it, you 00:35:04.760 --> 00:35:06.479 want to keep going back to it. 00:35:06.480 --> 00:35:10.639 So recently, this past month or so, I decided to give 00:35:10.640 --> 00:35:14.679 it an earnest try and try to actually address any pain 00:35:14.680 --> 00:35:16.039 points that I've noticed. 00:35:16.040 --> 00:35:18.919 So it's much more usable for me now, and I'm sticking 00:35:18.920 --> 00:35:19.479 with it for now. 00:35:19.480 --> 00:35:22.359 I'm not a Wayland hater, but I'm just saying, at least 00:35:22.360 --> 00:35:24.039 for now, I'm using EXWM. 00:35:24.040 --> 00:35:26.599 And I'm happy to talk about it. 00:35:26.600 --> 00:35:28.599 [Sacha]: OK, what do you love about your setup for 00:35:28.600 --> 00:35:30.939 that one? 00:35:30.940 --> 00:35:32.319 [Amin]: EXWM? 00:35:32.320 --> 00:35:35.199 [Sacha]: Yeah, yeah. 00:35:35.200 --> 00:35:36.599 Like, you're doing a lot of rename buffers. 00:35:36.600 --> 00:35:39.199 Yeah, yeah, yeah. 00:35:39.200 --> 00:35:40.399 [Amin]: Right. 00:35:40.400 --> 00:35:41.159 Yeah, let me think. 00:35:41.160 --> 00:35:42.199 There's a couple of things. 00:35:42.200 --> 00:35:45.559 So, for the longest time, my Emacs EXWM configuration 00:35:45.560 --> 00:35:48.959 used super key as a prefix, 00:35:48.960 --> 00:35:51.719 which is the Windows [key] or the one with the 00:35:51.720 --> 00:35:55.159 logo, basically, to switch workspaces, launch 00:35:55.160 --> 00:35:56.239 applications and such. 00:35:56.240 --> 00:36:02.719 And at least the way that EXWM is right now, it 00:36:02.720 --> 00:36:03.319 doesn't... 00:36:03.320 --> 00:36:07.559 Like the way you have to add those global key bindings 00:36:07.560 --> 00:36:11.839 and kind of slows down the EXWM startup. 00:36:11.840 --> 00:36:13.599 And I had many such key bindings. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0037.jpg #+SCREENSHOT_TIME: 00:36:16.467 00:36:13.600 --> 00:36:16.439 So one thing that I did kind of recently is to 00:36:16.440 --> 00:36:24.799 define a prefix map here, like bandali-prefix-exwm-map. 00:36:24.800 --> 00:36:29.039 So I bind all of the keys and commands that I want 00:36:29.040 --> 00:36:33.399 here, and then this helps me really minimize what I'm 00:36:33.400 --> 00:36:35.439 telling EXWM, which is here. 00:36:35.440 --> 00:36:39.319 For example, this is how you set global keys with 00:36:39.320 --> 00:36:44.639 EXWM, and I just point it to my prefix map. 00:36:44.640 --> 00:36:47.759 C-c x and then any of those letters and 00:36:47.760 --> 00:36:48.679 functions that we saw. 00:36:48.680 --> 00:36:51.679 That's kind of annoying. 00:36:51.680 --> 00:36:57.439 I still use the super key here, but I have it s-x 00:36:57.440 --> 00:36:58.639 and s-,. 00:36:58.640 --> 00:37:02.319 On the left-hand side of my keyboard, X is right next 00:37:02.320 --> 00:37:06.279 to super, so I can hit it in one go with one motion 00:37:06.280 --> 00:37:08.639 almost as a single key with these two fingers. 00:37:08.640 --> 00:37:11.460 On the right side of my keyboard, 00:37:11.461 --> 00:37:13.109 I don't have a super key, 00:37:13.110 --> 00:37:16.279 but I have a control key that I remapped to super. 00:37:16.280 --> 00:37:21.079 On the right side, I do s-, with these two 00:37:21.080 --> 00:37:22.719 fingers. 00:37:22.720 --> 00:37:28.359 It's still very convenient for me to invoke those 00:37:28.360 --> 00:37:29.079 commands. 00:37:29.080 --> 00:37:33.399 And pairing this up with repeat mode, as we can see 00:37:33.400 --> 00:37:37.879 just here, actually, then I can hit s-, and 00:37:37.880 --> 00:37:42.319 then P, N, or H, J, K, L many times to switch 00:37:42.320 --> 00:37:46.559 workspaces or shift focus to different windows and 00:37:46.560 --> 00:37:49.919 stuff without having to hit that kind of annoying 00:37:49.920 --> 00:37:53.599 s-x or s-, repeatedly. 00:37:53.600 --> 00:37:58.319 Yeah. 00:37:58.320 --> 00:37:59.199 [Sacha]: That sounds really cool. 00:37:59.200 --> 00:38:00.279 I should look into that. 00:38:00.280 --> 00:38:02.999 Sorry, quick aside. NOTE Audio setup 00:38:03.000 --> 00:38:05.559 @blaiseutube would like to compliment you on your awesome 00:38:05.560 --> 00:38:06.359 audio setup. 00:38:06.360 --> 00:38:07.479 It sounds like you're in the room with him. 00:38:07.480 --> 00:38:10.039 Apparently, I sound like I'm on speakerphone, but your 00:38:10.040 --> 00:38:12.879 audio setup is top-notch, apparently. 00:38:12.880 --> 00:38:16.759 But that looks like a Blue Yeti, so I have to find out 00:38:16.760 --> 00:38:18.159 what's going on. 00:38:18.160 --> 00:38:20.919 what microphone are you using? 00:38:20.920 --> 00:38:22.159 [Amin]: It is indeed a Blue Yeti. 00:38:22.160 --> 00:38:23.079 [Sacha]: Yeah, yeah. 00:38:23.080 --> 00:38:25.399 So I just have to ask him for 00:38:25.400 --> 00:38:27.079 okay, what kind of boom mic? 00:38:27.080 --> 00:38:29.159 Anyway, we'll do that all offline because it's not 00:38:29.160 --> 00:38:32.399 Emacs related. 00:38:32.400 --> 00:38:33.919 [Amin]: Yeah, it's just the Blue Yeti. 00:38:33.920 --> 00:38:36.279 Yeah, I turned down the gain. 00:38:36.280 --> 00:38:39.599 I used to have gain higher, but then it picks up 00:38:39.600 --> 00:38:41.599 more noise from around the room or around 00:38:41.600 --> 00:38:42.439 the house. 00:38:42.440 --> 00:38:45.759 So I turned down the gain a lot and then I get 00:38:45.760 --> 00:38:48.639 close to the mic so that it only captures my voice. 00:38:48.640 --> 00:38:50.759 Okay. 00:38:50.760 --> 00:38:52.239 [Sacha]: I'm gonna need the boom. 00:38:52.240 --> 00:38:54.119 Otherwise, I'm squished into that corner. 00:38:54.120 --> 00:38:54.679 All right. 00:38:54.680 --> 00:38:57.599 So you were doing repeat-map before I said oh, 00:38:57.600 --> 00:39:00.879 let's talk about EXWM because you've got cool stuff 00:39:00.880 --> 00:39:03.079 there. 00:39:03.080 --> 00:39:06.599 [Amin]: Yeah, and I can continue talking about the EXWM. 00:39:06.600 --> 00:39:10.279 There's a lot here. NOTE keymaps for launching different applications 00:39:10.280 --> 00:39:15.399 I have, let's see, s-, SPC. 00:39:15.400 --> 00:39:17.719 I bind it to async-shell-command to use as my 00:39:17.720 --> 00:39:20.399 simple, little, dmenu-thing for 00:39:20.400 --> 00:39:21.639 launching applications. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0039.jpg #+SCREENSHOT_TIME: 00:39:11.767 00:39:21.640 --> 00:39:24.959 Some of these things, like browsers, I still 00:39:24.960 --> 00:39:27.119 do them frequently enough, and I use different 00:39:27.120 --> 00:39:28.119 browser profiles. 00:39:28.120 --> 00:39:34.999 So I just define a new keymap so I can basically one-shot 00:39:35.000 --> 00:39:38.439 launch Chromium or Firefox in a specific browser or an 00:39:38.440 --> 00:39:39.999 incognito window and such. 00:39:40.000 --> 00:39:44.359 So yeah, I just do s-x b and then, for example, c 00:39:44.360 --> 00:39:46.039 to launch Chromium and all that stuff. 00:39:46.040 --> 00:39:49.299 So I found this pretty convenient. NOTE bandali-call-interactively-insert #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0040.jpg #+SCREENSHOT_TIME: 00:40:57.567 00:39:49.300 --> 00:39:55.639 Speaking of key bindings, before I get down this, 00:39:55.640 --> 00:40:01.999 let's see if I can find... C-c h. 00:40:02.000 --> 00:40:05.239 I think this is just before my EXWM setup. 00:40:05.240 --> 00:40:07.839 I'm pretty proud of this. 00:40:07.840 --> 00:40:09.079 I love this. 00:40:09.080 --> 00:40:12.759 It really goes to show how awesome Emacs is and 00:40:12.760 --> 00:40:14.199 extensible it is. 00:40:14.200 --> 00:40:16.039 Let's see. 00:40:16.040 --> 00:40:19.799 So as we know, these various help commands and 00:40:19.800 --> 00:40:22.319 describe commands are under C-h prefix. 00:40:22.320 --> 00:40:23.879 But some of them are not bound. 00:40:23.880 --> 00:40:26.679 for example, find-library or describe-face. 00:40:26.680 --> 00:40:29.519 Some of these I use pretty frequently. 00:40:29.520 --> 00:40:33.309 I was really having trouble coming up with 00:40:33.310 --> 00:40:35.174 descriptive-enough keybindings 00:40:35.175 --> 00:40:38.439 or short-enough keybindings for all of them. 00:40:38.440 --> 00:40:41.839 I put some of them here, for example, like 00:40:41.840 --> 00:40:43.559 C-c f l for find library. 00:40:43.560 --> 00:40:47.319 But I can't do that for all of them. 00:40:47.320 --> 00:40:51.239 What I did was just do C-c h a or C-c h d. 00:40:51.240 --> 00:40:56.839 What this will do is basically, if I show that, 00:40:56.840 --> 00:41:01.279 It basically opens up M-x, fills in describe-, 00:41:01.280 --> 00:41:05.366 and then I can just type, for example, face, 00:41:05.367 --> 00:41:06.079 and that's it. 00:41:06.080 --> 00:41:08.839 So it basically opens up the minibuffer for me, 00:41:08.840 --> 00:41:11.759 pre-fills it with the string that I want, and I can 00:41:11.760 --> 00:41:13.959 type what is it that I'm looking for. 00:41:13.960 --> 00:41:15.319 And I found this to be 00:41:15.320 --> 00:41:18.999 better than trying to bind a million different 00:41:19.000 --> 00:41:20.719 keyboard things for describe this and that, 00:41:20.720 --> 00:41:23.359 apropos this and that, find this and that. 00:41:23.360 --> 00:41:27.439 So yeah and the way that we do that is to just use 00:41:27.440 --> 00:41:30.679 a minibuffer-with-setup hook, and you just have a 00:41:30.680 --> 00:41:32.319 little lambda to insert the string that you give 00:41:32.320 --> 00:41:36.279 it, and then you invoke it. 00:41:36.280 --> 00:41:37.479 [Sacha]: Yeah, this is pretty cool. 00:41:37.480 --> 00:41:39.599 When I saw that in your config, I was like, 00:41:39.600 --> 00:41:41.132 I'm going to steal that. 00:41:41.133 --> 00:41:42.380 Pre-filling the minibuffer 00:41:42.381 --> 00:41:44.119 but still letting you do stuff with it, 00:41:44.120 --> 00:41:46.879 it's such a powerful thing, not just for 00:41:46.880 --> 00:41:49.359 completing the command itself, but even for when 00:41:49.360 --> 00:41:50.934 you're using the command, 00:41:50.935 --> 00:41:53.741 but you want to do something with the input before. 00:41:53.742 --> 00:41:55.871 You don't want to do it all the way, 00:41:55.872 --> 00:41:57.679 send it in and submit right away. 00:41:57.680 --> 00:42:00.199 You want to actually do something with it after you 00:42:00.200 --> 00:42:01.239 insert it. 00:42:01.240 --> 00:42:02.779 So great tip. 00:42:02.780 --> 00:42:04.119 [Amin]: Yeah. 00:42:04.120 --> 00:42:04.719 Thanks. 00:42:04.720 --> 00:42:05.879 Yeah, it's pretty useful. 00:42:05.880 --> 00:42:07.479 It's pretty nice. 00:42:07.480 --> 00:42:07.959 Yeah. 00:42:07.960 --> 00:42:11.359 And then back to the Emacs or EXWM stuff. 00:42:11.360 --> 00:42:18.039 So before I had, I used to yeah, sorry, go ahead. 00:42:18.040 --> 00:42:20.279 [Sacha]: Sorry. 00:42:20.280 --> 00:42:21.933 I forgot whether I was muted or unmuted. 00:42:21.934 --> 00:42:26.719 [Amin]: Okay, no worries. NOTE workspaces #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0041.jpg #+SCREENSHOT_TIME: 00:42:56.600 00:42:26.720 --> 00:42:29.639 For the longest time, I had 10 default 00:42:29.640 --> 00:42:33.199 EXWM workspaces on startup, and that can slow 00:42:33.200 --> 00:42:35.399 things down a little bit. 00:42:35.400 --> 00:42:39.679 So I found that okay, I don't really use 00:42:39.680 --> 00:42:41.079 all 10 workspaces always. 00:42:41.080 --> 00:42:42.999 So I set it to five. 00:42:43.000 --> 00:42:44.879 So I get five workspaces initially. 00:42:44.880 --> 00:42:48.439 But I still bind keys here. 00:42:48.440 --> 00:42:49.879 Like if we go down. 00:42:49.880 --> 00:42:53.839 Let's see. 00:42:53.840 --> 00:42:54.639 Here. 00:42:54.640 --> 00:42:59.999 So here, I define those keys for all the way from, 00:43:00.000 --> 00:43:03.599 let's say, from 0 to 9 for all 10. 00:43:03.600 --> 00:43:06.479 And then if I try to switch to a workspace that 00:43:06.480 --> 00:43:09.479 doesn't exist, then EXWM will just go ahead and 00:43:09.480 --> 00:43:10.759 create it for me. 00:43:10.760 --> 00:43:14.279 Yeah, so I found that pretty cool. 00:43:14.280 --> 00:43:15.839 You can create workspaces on the fly. 00:43:15.840 --> 00:43:19.219 Yeah. 00:43:19.220 --> 00:43:21.239 [Sacha]: Yeah, and I saw that it moves your current 00:43:21.240 --> 00:43:22.159 window there, too. 00:43:22.160 --> 00:43:23.719 So that's just like, OK. 00:43:23.720 --> 00:43:26.359 Let's move it to workspace number two or whatever. 00:43:26.360 --> 00:43:28.699 Very cool. 00:43:28.700 --> 00:43:29.119 [Amin]: Yeah, yeah, yeah. 00:43:29.120 --> 00:43:31.879 I have keys or convenience keys for moving 00:43:31.880 --> 00:43:33.079 some window to some workspace. 00:43:33.080 --> 00:43:34.399 Yeah, it's nice. 00:43:34.400 --> 00:43:36.199 Let's see. 00:43:36.200 --> 00:43:36.559 Let's see. 00:43:36.560 --> 00:43:37.519 Yeah. 00:43:37.520 --> 00:43:39.839 So these are just made key bindings. 00:43:39.840 --> 00:43:46.379 I use hjkl here for switching windows. NOTE ZSA Voyager split keyboard, super x as a single key #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0042.jpg #+SCREENSHOT_TIME: 00:45:46.167 00:43:46.380 --> 00:43:50.439 I also have a ZSA Voyager split 00:43:50.440 --> 00:43:53.079 ergonomic keyboard. 00:43:53.080 --> 00:43:59.239 I can basically customize it infinitely. 00:43:59.240 --> 00:44:02.839 For example, I don't really have a super key on the 00:44:02.840 --> 00:44:03.479 first layer. 00:44:03.480 --> 00:44:06.559 What I have is a key that will do the s-x thingy, 00:44:06.560 --> 00:44:09.119 basically my prefix. 00:44:09.120 --> 00:44:12.279 So that's the last missing piece is that if I'm 00:44:12.280 --> 00:44:14.959 at home and if I have this keyboard with me, then I 00:44:14.960 --> 00:44:17.079 just hit one key and then that's it. 00:44:17.080 --> 00:44:18.679 I'm in my prefix. 00:44:18.680 --> 00:44:21.479 But even if not, on the laptop, the s-x or the 00:44:21.480 --> 00:44:24.279 super comma are still easy enough for me to hit 00:44:24.280 --> 00:44:26.619 it with one hand. 00:44:26.620 --> 00:44:28.799 [Sacha]: Now I'm jealous and I definitely want 00:44:28.800 --> 00:44:31.759 to assign my prefixes to their own keys. 00:44:31.760 --> 00:44:32.319 Very tempting. 00:44:32.320 --> 00:44:34.999 I've started using the numpad because my laptop has 00:44:35.000 --> 00:44:35.879 one. 00:44:35.880 --> 00:44:39.679 I only use the numpad rarely, but we all need more 00:44:39.680 --> 00:44:42.679 keys. 00:44:42.680 --> 00:44:45.039 [Amin]: Yeah, ergonomic keyboards are pretty nice, 00:44:45.040 --> 00:44:48.479 especially these ones. For example, the ZSA ones where 00:44:48.480 --> 00:44:52.879 you can put QMK on it, the QMK firmware. You can 00:44:52.880 --> 00:44:59.239 define keys in a C file. I can actually show that. 00:44:59.240 --> 00:45:16.239 Let's see... QMK Firmware, Keyboards, ZSA, 00:45:16.240 --> 00:45:26.519 Voyager, Bandali, and then keymap.c. 00:45:26.520 --> 00:45:32.619 [Sacha]: Is this in your repository somewhere? 00:45:32.620 --> 00:45:34.959 [Amin]: Right. It's in a different repository, but it's 00:45:34.960 --> 00:45:38.319 still on git.kelar.org next to my configs 00:45:38.320 --> 00:45:44.399 repository. You can find this as well, but if I go 00:45:44.400 --> 00:45:46.159 smaller... 00:45:46.160 --> 00:45:50.279 Yeah, you can define keys here and have different 00:45:50.280 --> 00:45:51.639 layers, like the base layer. 00:45:51.640 --> 00:45:54.959 And then you can define a key to switch between 00:45:54.960 --> 00:45:58.039 different layers and put some of the keys there anyway. 00:45:58.040 --> 00:46:02.479 So yeah, it's a whole rabbit hole in and of itself. 00:46:02.480 --> 00:46:05.639 Prot also uses a split ergonomic keyboard. 00:46:05.640 --> 00:46:08.759 It really does help if you're typing for long 00:46:08.760 --> 00:46:10.639 periods of time. 00:46:10.640 --> 00:46:15.159 I actually had these for a while, and I wasn't using 00:46:15.160 --> 00:46:18.039 them too much, but I started slowly getting some pain 00:46:18.040 --> 00:46:19.679 in my wrists and here. 00:46:19.680 --> 00:46:22.639 So I was like, okay, I have the keyboard. 00:46:22.640 --> 00:46:24.959 Might as well put it to good use, and I've started 00:46:24.960 --> 00:46:26.839 using it. NOTE Keybindings #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0043.jpg #+SCREENSHOT_TIME: 00:46:53.767 00:46:26.840 --> 00:46:28.839 [Sacha]: Okay, so most of your keyboard shortcuts come 00:46:28.840 --> 00:46:33.319 off that kind of s-x or C-c something, and 00:46:33.320 --> 00:46:36.759 then you have a long prefix sequence, and you just 00:46:36.760 --> 00:46:39.759 remember everything or you use your... 00:46:39.760 --> 00:46:44.959 pre-fill some of it and then fill in the rest of the 00:46:44.960 --> 00:46:50.859 command. 00:46:50.860 --> 00:46:53.759 [Amin]: Pretty much all my window management related 00:46:53.760 --> 00:46:58.079 keys are on this s-x prefix that I'm showing here. 00:46:58.080 --> 00:47:02.119 And then I have a few other ones which I think I 00:47:02.120 --> 00:47:02.679 showed earlier. 00:47:02.680 --> 00:47:04.879 Is it this one? 00:47:04.880 --> 00:47:08.679 Anyway, I bind a few general keys outside of the 00:47:08.680 --> 00:47:12.600 s-x thing, like C-c e i. 00:47:12.601 --> 00:47:17.033 For example, I have C-c e e for eval-last-sexp. 00:47:17.034 --> 00:47:19.367 I do that a lot, so it's easy to hit that. 00:47:19.368 --> 00:47:23.379 Making frames or deleting frames 00:47:23.380 --> 00:47:26.633 [Sacha]: I love how Emacs uptime is something you use 00:47:26.634 --> 00:47:31.379 frequently enough that you have a keyboard shortcut for it. 00:47:31.380 --> 00:47:32.233 [Amin]: Yeah, of course. 00:47:32.234 --> 00:47:34.100 I mean, I'm sometimes curious to see how long has my 00:47:34.101 --> 00:47:42.019 Emacs session been running. 00:47:42.020 --> 00:47:44.559 To continue with the EXWM stuff, let's see. 00:47:44.560 --> 00:47:49.559 This is just some keybindings I define here. 00:47:49.560 --> 00:47:51.399 It's all Emacs Lisp, right? 00:47:51.400 --> 00:47:52.119 It's amazing. 00:47:52.120 --> 00:47:55.119 You can mapc over whatever sequence and create 00:47:55.120 --> 00:47:57.519 keybindings like that. 00:47:57.520 --> 00:47:59.999 Only with Emacs we can do things like that. 00:48:00.000 --> 00:48:02.359 I just love it. 00:48:02.360 --> 00:48:05.040 Let's see. NOTE Media buttons #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0044.jpg #+SCREENSHOT_TIME: 00:48:36.200 00:48:05.080 --> 00:48:08.079 I still keep these three other keys for raising and 00:48:08.080 --> 00:48:12.799 lowering the volume and toggling mute off of that 00:48:12.800 --> 00:48:16.879 prefix and just directly on my keyboard, hitting it 00:48:16.880 --> 00:48:21.359 directly in the exwm-input-global-keys because I do 00:48:21.360 --> 00:48:24.279 that very, very frequently. 00:48:24.280 --> 00:48:26.599 But I also have scripts that I can invoke. 00:48:26.600 --> 00:48:30.239 I should do keycast. 00:48:30.240 --> 00:48:36.179 So yeah, I can 00:48:36.180 --> 00:48:37.639 invoke the prefix with semicolon. 00:48:37.640 --> 00:48:41.919 I can set my volume here, adjust it here, type in what 00:48:41.920 --> 00:48:47.039 volume I want, or with the single quote, I can enter a 00:48:47.040 --> 00:48:49.079 value for the screen brightness. 00:48:49.080 --> 00:48:51.359 I like these things to be exact depending on the 00:48:51.360 --> 00:48:52.039 lighting in the room. 00:48:52.040 --> 00:48:58.039 I have preferred brightness values of 50 or 12 or 10 00:48:58.040 --> 00:49:00.039 that I manually adjust. 00:49:00.040 --> 00:49:04.999 I guess it's a poor man's version of having something 00:49:05.000 --> 00:49:08.959 with a light sensor that can pick up and adjust 00:49:08.960 --> 00:49:11.599 automatically. 00:49:11.600 --> 00:49:12.279 I do it manually. 00:49:12.280 --> 00:49:12.959 Yeah. 00:49:12.960 --> 00:49:17.179 Sorry, you just muted yourself again. 00:49:17.180 --> 00:49:19.799 [Sacha]: You're just probably this close to writing 00:49:19.800 --> 00:49:22.119 the Emacs Lisp that takes your webcam image and then 00:49:22.120 --> 00:49:22.879 adjusts your light. 00:49:22.880 --> 00:49:25.639 But I think Prot was also saying he likes to do the 00:49:25.640 --> 00:49:27.999 lighting changes manually as well because warmer 00:49:28.000 --> 00:49:30.439 colors versus cooler colors and all of that stuff. 00:49:30.440 --> 00:49:32.839 Anyway, so you have all these buttons that EXWM 00:49:32.840 --> 00:49:36.639 listens to and it can launch various things for. 00:49:36.640 --> 00:49:41.899 That's a lot of things. 00:49:41.900 --> 00:49:43.279 [Amin]: Yeah, those are pretty cool. NOTE exwm-input-simulation-keys! #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0045.jpg #+SCREENSHOT_TIME: 00:50:08.267 00:49:43.280 --> 00:49:45.959 EXWM has this lovely feature called input 00:49:45.960 --> 00:49:47.239 simulation keys where 00:49:47.240 --> 00:49:50.439 You can basically use it to bring Emacs key bindings 00:49:50.440 --> 00:49:53.799 to other applications like Firefox or whatever. 00:49:53.800 --> 00:49:55.959 And yeah, it's mind blowing when you try it for the 00:49:55.960 --> 00:49:56.639 first time. 00:49:56.640 --> 00:50:00.719 for example, I bind C-b to just hit 00:50:00.720 --> 00:50:02.879 the left arrow on the keyboard. 00:50:02.880 --> 00:50:04.999 And it does that. 00:50:05.000 --> 00:50:08.239 So I can define all of these commands that I'm using 00:50:08.240 --> 00:50:10.279 or used to using in Emacs. 00:50:10.280 --> 00:50:14.279 So I can get them in Firefox or other applications as 00:50:14.280 --> 00:50:14.519 well. 00:50:14.520 --> 00:50:16.959 Realistically, it's mostly Firefox. 00:50:16.960 --> 00:50:19.319 It's the only other program that I spend any 00:50:19.320 --> 00:50:21.159 reasonable amount of time outside of Emacs. 00:50:21.197 --> 00:50:24.199 [Sacha]: Let me point out this very important one that 00:50:24.200 --> 00:50:25.039 you have there. 00:50:25.040 --> 00:50:28.239 Under selection, cut, copy, paste, I see a control W. 00:50:28.240 --> 00:50:30.519 Input simulation keys. 00:50:30.520 --> 00:50:33.079 So this is for all the people who have accidentally 00:50:33.080 --> 00:50:36.079 closed their browser tab while trying to copy text. 00:50:36.080 --> 00:50:38.239 This is how you solve that problem. 00:50:38.240 --> 00:50:41.879 Use EXWM and use EXWM input simulation keys and you 00:50:41.880 --> 00:50:45.599 don't have to accidentally close your browser tabs 00:50:45.600 --> 00:50:46.439 again. 00:50:46.440 --> 00:50:49.039 @blaiseutube asks, hey, what about time since last save? 00:50:49.040 --> 00:50:51.319 Or do you have some kind of autosave magic? 00:50:51.320 --> 00:50:55.399 you know, in reference to the uptime thing, 00:50:55.400 --> 00:50:56.119 right? 00:50:56.120 --> 00:51:04.679 You have this thing that shows you... 00:51:04.680 --> 00:51:05.359 [Amin]: I don't think I have anything for autosave, 00:51:05.360 --> 00:51:12.079 but I have this habit of... I save everything pretty 00:51:12.080 --> 00:51:13.239 regularly. 00:51:13.240 --> 00:51:15.359 Yeah, so I've never really needed that feature, but 00:51:15.360 --> 00:51:18.199 I'm sure Emacs has something where you can, at the 00:51:18.200 --> 00:51:21.239 very least, just very dumb, simple implementation of 00:51:21.240 --> 00:51:24.519 has it been idle for one minute, then just do a save 00:51:24.520 --> 00:51:25.599 buffer. 00:51:25.600 --> 00:51:27.759 You can roll your own. 00:51:27.760 --> 00:51:29.999 But I don't have anything. 00:51:30.000 --> 00:51:30.360 [Sacha]: All right. 00:51:30.401 --> 00:51:34.359 I'm getting really tempted now to try out EXWM, even 00:51:34.360 --> 00:51:37.919 if it's just for those global keyboard remapping 00:51:37.920 --> 00:51:39.339 things. NOTE exwm: managing floating windows #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0046.jpg #+SCREENSHOT_TIME: 00:51:43.100 00:51:39.340 --> 00:51:43.079 How is it for windows that you've got to have floating? 00:51:43.080 --> 00:51:46.559 I feel like it's very good at handling tiling things, 00:51:46.560 --> 00:51:49.599 but how is it for sometimes the apps kind of really 00:51:49.600 --> 00:51:52.439 want the floating window? 00:51:52.440 --> 00:51:54.879 [Amin]: Right, yeah, so you can toggle any window to 00:51:54.880 --> 00:51:58.279 be floating or not, and you can also — actually, we're 00:51:58.280 --> 00:52:01.359 just looking at it here. EXWM manage configurations, 00:52:01.360 --> 00:52:06.039 to match on the instance name or the class name of a 00:52:06.040 --> 00:52:10.199 window that you can get from `xprop`, to automatically 00:52:10.200 --> 00:52:14.959 make that tiling. For example, if I do my prefix and 00:52:14.960 --> 00:52:18.159 then capital T, it launches a floating terminal for me 00:52:18.160 --> 00:52:21.039 here. 00:52:21.040 --> 00:52:25.839 And if I go back to where I set it up, I just launch 00:52:25.840 --> 00:52:27.719 Xterm with the name argument. 00:52:27.720 --> 00:52:30.159 This is where it can set the instance. 00:52:30.160 --> 00:52:32.759 And I just put any string you can want, like floating, 00:52:32.760 --> 00:52:33.359 for example. 00:52:33.360 --> 00:52:37.399 And then here in my configuration, I just check that 00:52:37.400 --> 00:52:40.079 if the instance name is floating, then I'll go ahead 00:52:40.080 --> 00:52:41.519 and float the window. 00:52:41.520 --> 00:52:43.919 Simple as that. 00:52:43.920 --> 00:52:45.639 [Sacha]: All right. 00:52:45.640 --> 00:52:49.879 This is starting to look exceedingly tempting. 00:52:49.880 --> 00:52:53.839 Lol, I save everything regularly, so he's one of those 00:52:53.840 --> 00:53:00.639 people who compulsively hit C-x C-s. 00:53:00.640 --> 00:53:01.639 [Amin]: Yeah, I do that a lot. 00:53:01.640 --> 00:53:02.239 I don't know. 00:53:02.240 --> 00:53:02.999 It's just me. 00:53:03.000 --> 00:53:04.759 But, yeah. 00:53:04.760 --> 00:53:05.239 Yeah. 00:53:05.240 --> 00:53:09.399 And then, I don't know. 00:53:09.400 --> 00:53:10.999 EXWM is awesome. NOTE exwm: application-specific local simulation keys #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0047.jpg #+SCREENSHOT_TIME: 00:53:11.000 00:53:11.000 --> 00:53:13.879 You can also put local simulation keys, 00:53:13.880 --> 00:53:16.999 application-specific simulation keys, depending 00:53:17.000 --> 00:53:19.999 on, the application, terminals, for 00:53:20.000 --> 00:53:21.559 example, or, Zathura. 00:53:21.560 --> 00:53:23.079 This is a PDF viewer. 00:53:23.080 --> 00:53:28.759 To have application-specific custom key bindings, 00:53:28.760 --> 00:53:29.999 how cool is that? 00:53:30.000 --> 00:53:33.199 For example, if I'm in Xterm or something like the 00:53:33.200 --> 00:53:37.879 Mate terminal, hitting C-c C-c twice basically, 00:53:37.880 --> 00:53:40.919 it'll just send the C-c key to the terminal. 00:53:40.920 --> 00:53:43.879 Because one thing with EXWM is that you can set it to 00:53:43.880 --> 00:53:47.639 capture a couple of Emacs prefixes, like C-x or 00:53:47.640 --> 00:53:48.079 C-c. 00:53:48.080 --> 00:53:52.399 So the application by default doesn't see it because 00:53:52.400 --> 00:53:53.279 Emacs captures it. 00:53:53.280 --> 00:53:54.959 But this is one of those 00:53:54.960 --> 00:53:59.599 mechanisms by which you can send a key through. 00:53:59.600 --> 00:54:04.219 Let's see. NOTE binding C-q to exwm-input-send-next-key 00:54:04.220 --> 00:54:09.639 The other thing is, you can set it like EXWM inputs 00:54:09.640 --> 00:54:10.999 send next key. 00:54:11.000 --> 00:54:13.999 So the default is C-c C-q, but I just 00:54:14.000 --> 00:54:19.319 bind it to C-q, and I, for example, can do 00:54:19.320 --> 00:54:21.639 C-q C-t to send C-t to the 00:54:21.640 --> 00:54:22.679 underlying application. 00:54:22.680 --> 00:54:24.159 So that's the other thing. 00:54:24.160 --> 00:54:28.579 Yeah, and then let's see. NOTE Renaming buffers #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0049.jpg #+SCREENSHOT_TIME: 00:55:05.333 00:54:28.580 --> 00:54:31.239 So this thingy here, I enable EXWM and I add this 00:54:31.240 --> 00:54:35.199 rename hook and all it does is basically to add the 00:54:35.200 --> 00:54:41.559 window titles to the buffer that I can see on the 00:54:41.560 --> 00:54:43.479 mode line. 00:54:43.480 --> 00:54:45.599 But as long as it's within a certain 00:54:45.600 --> 00:54:47.759 reasonable length, like for example, I have 25 00:54:47.760 --> 00:54:48.239 characters. 00:54:48.240 --> 00:54:51.479 If it's longer than that, it will just put dot dot dot. 00:54:51.480 --> 00:54:53.879 So yeah, that's all the purpose of that. 00:54:53.880 --> 00:55:00.599 Let's see, for example, if I launch Xterm, it appears 00:55:00.600 --> 00:55:01.439 there. 00:55:01.440 --> 00:55:05.319 The perfect example is actually here on the right-hand 00:55:05.320 --> 00:55:05.519 side. 00:55:05.520 --> 00:55:07.879 On the mode line, we see Firefox, ESR, Emacs, Comp 00:55:07.880 --> 00:55:08.159 Chat. 00:55:08.160 --> 00:55:11.079 It's a bit long, so it just puts the dot dot dot there. 00:55:11.080 --> 00:55:16.919 So that's all that does. 00:55:16.920 --> 00:55:19.759 [Sacha]: Yeah, now being able to use Emacs to manage 00:55:19.760 --> 00:55:21.919 the tiling of these things instead of my having to 00:55:21.920 --> 00:55:26.079 fiddle with alt-dragging things to snap nicely into 00:55:26.080 --> 00:55:26.639 buffers. 00:55:26.640 --> 00:55:28.759 Yes, very cool stuff. 00:55:28.760 --> 00:55:29.559 EXLDM. 00:55:29.560 --> 00:55:32.739 Gotta try it. 00:55:32.740 --> 00:55:34.399 [Amin]: Yeah, for sure. 00:55:34.400 --> 00:55:36.279 Yeah, let's see. NOTE dunst for notifications #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0050.jpg #+SCREENSHOT_TIME: 00:55:36.300 00:55:36.280 --> 00:55:38.359 Here I launch Dunst if the executable is 00:55:38.360 --> 00:55:40.959 installed for getting notifications in ESWM. 00:55:40.960 --> 00:55:44.839 I think there's at least one or two Emacs specific 00:55:44.840 --> 00:55:48.039 packages that implement a simple notification 00:55:48.040 --> 00:55:51.599 daemon or backend so that Emacs itself can handle 00:55:51.600 --> 00:55:52.039 that. 00:55:52.040 --> 00:55:54.679 But I found Dunst good enough for my use cases coming 00:55:54.680 --> 00:55:57.399 from I3, Sway, like tiling window manager 00:55:57.400 --> 00:55:58.639 background. 00:55:58.640 --> 00:56:00.559 I just reuse that. 00:56:00.560 --> 00:56:05.719 So yeah, I just start a process, keep a handle of it 00:56:05.720 --> 00:56:07.759 in this dunst process variable here. 00:56:07.760 --> 00:56:11.919 And this thing I discovered recently, it's cool. 00:56:11.920 --> 00:56:15.279 using set-process-query-on-exit-flag, you 00:56:15.280 --> 00:56:18.159 can basically have Emacs not ask you if you want to 00:56:18.160 --> 00:56:21.159 exit Emacs if that process is still running. 00:56:21.160 --> 00:56:23.359 It'll just kill it without confirming with you. 00:56:23.360 --> 00:56:27.199 So just a little convenience. 00:56:27.200 --> 00:56:29.279 [Sacha]: That is also cool. 00:56:29.280 --> 00:56:31.479 Just a heads up, I have about 15 minutes before the 00:56:31.480 --> 00:56:34.919 kiddo runs out because she'll be done with school then. 00:56:34.920 --> 00:56:37.879 Even just the EXWM part and other things that you've 00:56:37.880 --> 00:56:41.599 shown us in the config have been super awesome. 00:56:41.600 --> 00:56:44.599 But are there other things in the next 15 minutes that 00:56:44.600 --> 00:56:47.519 you would love to show people so that they can see how 00:56:47.520 --> 00:56:54.539 it works in practice? NOTE exwm xsettings and responding to screen configuration changes #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0051.jpg #+SCREENSHOT_TIME: 00:57:13.733 00:56:54.540 --> 00:56:55.999 [Amin]: One thing I'll just mention, EXWM, 00:56:56.000 --> 00:56:59.319 one more thing, and then I'll go check. 00:56:59.320 --> 00:57:04.679 I think this is kind of recent: EXWM xsettings, and 00:57:04.680 --> 00:57:10.439 this allows you to dynamically at runtime change some 00:57:10.440 --> 00:57:13.719 of these things that you would normally set in an X 00:57:13.720 --> 00:57:20.839 resources file, like fonts. These kinds of settings 00:57:20.840 --> 00:57:24.759 were especially commonplace back when Wayland wasn't a 00:57:24.760 --> 00:57:27.279 thing or wasn't very popular. You would set some of 00:57:27.280 --> 00:57:28.399 these font settings there. 00:57:28.400 --> 00:57:31.999 With EXWM xsettings, you can do this dynamically, 00:57:32.000 --> 00:57:39.119 and what's awesome about that is it also lets you hook 00:57:39.120 --> 00:57:43.119 into, for example, if your screen configuration 00:57:43.120 --> 00:57:47.839 changes, if you plug in a monitor or unplug it, then 00:57:47.840 --> 00:57:53.399 you can run whatever `xrandr` command to set it up and 00:57:53.400 --> 00:57:55.199 also adjust those settings. 00:57:55.200 --> 00:57:59.399 The main thing I use it for is to change the DPI 00:57:59.400 --> 00:58:03.639 setting. The thing with X11 or Xorg is, unfortunately, 00:58:03.640 --> 00:58:07.439 there's no per-monitor DPI. There's one global DPI. 00:58:07.440 --> 00:58:11.799 But I found that on my high-DPI laptop screen, if I 00:58:11.800 --> 00:58:16.159 set the resolution to 1920x1080 instead of the full 00:58:16.160 --> 00:58:20.079 resolution, then the default DPI of 96 works just fine 00:58:20.080 --> 00:58:24.479 with my external monitor as well. All this little hook 00:58:24.480 --> 00:58:28.079 does, by calling into this function, is: if I'm 00:58:28.080 --> 00:58:30.879 plugging in my external monitor, lower the resolution 00:58:30.880 --> 00:58:35.119 and lower the DPI, and if I unplug it, go back to the 00:58:35.120 --> 00:58:39.359 high thing. I just love this. 00:58:39.360 --> 00:58:40.533 [Sacha]: That's great. 00:58:40.534 --> 00:58:42.199 We're definitely not going to demonstrate that because 00:58:42.200 --> 00:58:44.079 plugging in and unplugging monitors is not a good 00:58:44.080 --> 00:58:47.279 thing for screen sharing, but that sounds really cool. 00:58:47.280 --> 00:58:50.559 When things change, you can actually get your system 00:58:50.560 --> 00:58:53.399 to adapt to the changes for you. 00:58:53.400 --> 00:58:54.359 [Amin]: Yeah, it's lovely. 00:58:54.360 --> 00:58:55.559 Let's see. 00:58:55.560 --> 00:58:59.879 There's so much more to talk about. NOTE Slowly getting back into Org mode 00:58:59.880 --> 00:59:03.359 I'm slowly getting back into Org Mode again. 00:59:03.360 --> 00:59:08.479 For the longest time, I didn't use it and I just used 00:59:08.480 --> 00:59:10.119 Markdown for my website as well. 00:59:10.120 --> 00:59:13.119 But I found that it's kind of limited. 00:59:13.120 --> 00:59:15.919 For example, I was using a Markdown implementation 00:59:15.920 --> 00:59:19.199 that was written in C and I can't easily customize it. 00:59:19.200 --> 00:59:23.919 Whereas with Org, I can hook into or create 00:59:23.920 --> 00:59:26.519 my custom HTML back-end that's a 00:59:26.520 --> 00:59:30.479 derivative of ox-html, even if I don't necessarily like 00:59:30.480 --> 00:59:33.759 the defaults or the settings for ox-html. 00:59:33.760 --> 00:59:38.359 I just recently started writing a new back-end called 00:59:38.360 --> 00:59:41.079 bhtml for Bandali HTML. 00:59:41.080 --> 00:59:43.439 It's just a boilerplate. 00:59:43.440 --> 00:59:46.459 I don't have much there yet, but that's the idea. 00:59:46.460 --> 00:59:49.199 [Sacha]: I love how you can hook into all of these different 00:59:49.200 --> 00:59:52.119 aspects of Emacs and get it to do exactly what you 00:59:52.120 --> 00:59:53.979 want. 00:59:53.980 --> 00:59:54.679 [Amin]: Yeah, so that's cool. 00:59:54.680 --> 00:59:58.159 Let's see. NOTE chat notes #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0052.jpg #+SCREENSHOT_TIME: 01:00:16.067 00:59:58.160 --> 01:00:01.319 I have written some things about the prompt for this 01:00:01.320 --> 01:00:01.679 meeting. 01:00:01.680 --> 01:00:08.999 Yeah, so I talked about that stuff briefly. 01:00:09.000 --> 01:00:11.639 Minibuffer setup. 01:00:11.640 --> 01:00:14.559 Things that I love about my setup is that it's kind of 01:00:14.560 --> 01:00:16.039 portable, simple. 01:00:16.040 --> 01:00:18.839 People can easily copy things from it if they want. 01:00:18.840 --> 01:00:20.159 It's kind of self-contained. 01:00:20.160 --> 01:00:23.319 And that was kind of a big thing a while back when I 01:00:23.320 --> 01:00:27.159 wanted to use my configurations on a couple of work 01:00:27.160 --> 01:00:28.199 machines. 01:00:28.200 --> 01:00:32.799 And these don't have direct outbound internet access. 01:00:32.800 --> 01:00:36.599 So I couldn't do things like installing packages with 01:00:36.600 --> 01:00:39.759 Elpa because that's done over HTTP. 01:00:39.760 --> 01:00:42.879 So yeah, I use submodules now. 01:00:42.880 --> 01:00:47.439 I recently began documenting my setup, very much 01:00:47.440 --> 01:00:52.139 inspired by Prot and Sacha and others. NOTE Mode line 01:00:52.140 --> 01:00:54.759 The things that I'm looking forward to tweaking next 01:00:54.760 --> 01:00:55.759 is the mode line. 01:00:55.760 --> 01:00:58.933 This is basically the default mode line of Emacs. 01:00:58.934 --> 01:01:01.879 A couple versions ago, they added a setting for 01:01:01.880 --> 01:01:03.479 compacting the mode line, which 01:01:03.480 --> 01:01:06.733 improves a lot of the extraneous whitespace in it, 01:01:06.734 --> 01:01:07.700 which is great. 01:01:07.701 --> 01:01:10.100 It's still... There's too much information. 01:01:10.101 --> 01:01:12.733 If you use multiple windows 01:01:12.734 --> 01:01:14.067 or even especially if you use EXWM 01:01:14.068 --> 01:01:16.900 all of those things like the date 01:01:16.901 --> 01:01:18.467 or like the battery get repeated 01:01:18.468 --> 01:01:20.000 in all of the windows, 01:01:20.001 --> 01:01:22.000 so I'm looking forward to 01:01:22.001 --> 01:01:24.700 doing my mode line in such a way that 01:01:24.701 --> 01:01:29.619 for example, it shows most of those things. 01:01:29.620 --> 01:01:31.500 And Prot actually has 01:01:31.501 --> 01:01:32.900 an excellent video about that 01:01:32.901 --> 01:01:35.667 where he shows how you can create 01:01:35.668 --> 01:01:38.739 your own custom mode line. 01:01:38.740 --> 01:01:39.700 [Sacha]: I've also been tempted 01:01:39.701 --> 01:01:41.833 to start using the header line too 01:01:41.834 --> 01:01:42.833 because that's another thing 01:01:42.834 --> 01:01:45.799 that you can put information in. 01:01:45.800 --> 01:01:49.319 [Amin]: Right, yep, header-line is awesome. NOTE display-buffer-alist 01:01:49.320 --> 01:01:50.319 [Sacha]: Yeah, the display-buffer-alist 01:01:50.320 --> 01:01:51.799 is particularly powerful 01:01:51.800 --> 01:01:54.799 because you're combining it with EXWM, so it'd be 01:01:54.800 --> 01:01:58.959 interesting to see how you can manage windows and 01:01:58.960 --> 01:02:01.479 applications and stuff. 01:02:01.480 --> 01:02:02.833 [Amin]: Especially, just like how we saw 01:02:02.834 --> 01:02:03.599 in today's video call 01:02:03.600 --> 01:02:05.959 and also a call that I had with Prot recently. 01:02:05.960 --> 01:02:08.119 For example, if I open a describe-variable or 01:02:08.120 --> 01:02:11.999 something, it'll by default use the right area of the 01:02:12.000 --> 01:02:14.999 screen right now where our video is. 01:02:15.000 --> 01:02:15.639 So it reuses that. 01:02:15.640 --> 01:02:21.439 So I'm also looking forward to reading more about and 01:02:21.440 --> 01:02:23.480 configuring display-buffer-alist. NOTE TRAMP slowness, maybe disabling VC detection? 01:02:23.481 --> 01:02:24.619 I'd like to figure out some TRAMP slowness. 01:02:24.620 --> 01:02:25.679 I recently tried using it again. 01:02:25.680 --> 01:02:26.199 It's awesome. 01:02:26.200 --> 01:02:30.039 You can seamlessly open files, SSH into other 01:02:30.040 --> 01:02:31.399 machines and edit files there. 01:02:31.400 --> 01:02:33.039 But I don't know. 01:02:33.040 --> 01:02:33.959 It's kind of slow. 01:02:33.960 --> 01:02:36.919 So I want to see aside from the latency, you know, the 01:02:36.920 --> 01:02:40.759 physical limit of the latency because of the distance. 01:02:40.760 --> 01:02:43.479 Is there anything slowing it down? 01:02:43.480 --> 01:02:47.439 I think I read in the Tramp FAQ that maybe trying to 01:02:47.440 --> 01:02:53.479 disable VC mode or VC detection for remote connections 01:02:53.480 --> 01:02:56.119 might help speed it up, or at least having it do only 01:02:56.120 --> 01:03:00.479 Git, for example, because by default, Emacs' VC has 01:03:00.480 --> 01:03:07.399 support for Mercurial, CVS, SVN, Git, RCS even. 01:03:07.400 --> 01:03:09.639 [Sacha]: Anything anyone has ever wanted to use in the 01:03:09.640 --> 01:03:10.879 last 40 years. 01:03:10.880 --> 01:03:13.519 Here we go. 01:03:13.520 --> 01:03:18.879 I saw in your chat config actually that you were doing 01:03:18.880 --> 01:03:23.079 something with the SSH configs and I'd never come 01:03:23.080 --> 01:03:23.799 across that. 01:03:23.800 --> 01:03:29.879 So I was like, oh, that's something I should look into 01:03:29.880 --> 01:03:32.639 later. 01:03:32.640 --> 01:03:34.159 [Amin]: I don't remember the specifics, but it's all 01:03:34.160 --> 01:03:34.839 out there. 01:03:34.840 --> 01:03:39.239 Feel free to look into it. NOTE eat 01:03:39.240 --> 01:03:42.959 Especially with this EXWM setup, I still use Xterm 01:03:42.960 --> 01:03:45.919 sometimes and I have the Emacs EAT terminal, which is 01:03:45.920 --> 01:03:49.799 a terminal emulator written in Emacs Lisp. 01:03:49.800 --> 01:03:53.159 If I launch it right now, it's awesome. 01:03:53.160 --> 01:03:57.119 It actually is very powerful and it's a properly 01:03:57.120 --> 01:03:58.479 capable terminal emulator. 01:03:58.480 --> 01:04:00.719 It just can be a little bit slow. 01:04:00.720 --> 01:04:04.319 It is slower than xterm, but it's still a lot faster 01:04:04.320 --> 01:04:06.119 than whatever Emacs has built in. 01:04:06.120 --> 01:04:07.519 So this is pretty cool. 01:04:07.520 --> 01:04:10.159 But yeah, I don't want to use it a lot. 01:04:10.160 --> 01:04:13.919 And I kind of started testing, delegating more 01:04:13.920 --> 01:04:18.119 things or using more async-shell-command to just 01:04:18.120 --> 01:04:20.679 basically open this prompt and then do whatever I 01:04:20.680 --> 01:04:21.159 want. 01:04:21.160 --> 01:04:22.879 anyway. 01:04:22.880 --> 01:04:26.839 [Sacha]: I've also heard things about Ghost TTY. 01:04:26.840 --> 01:04:30.599 Anyway, so that's another thing to look into. 01:04:30.600 --> 01:04:36.959 Yes, so @Paniash47 says, "With Emacs 31, there's a new 01:04:36.960 --> 01:04:38.759 variable where you can hide the minor modes in the 01:04:38.760 --> 01:04:39.079 mode line." 01:04:39.080 --> 01:04:41.559 @pkal says it's mode-line-collapse-minor-modes. 01:04:41.560 --> 01:04:44.599 And @Paniash47 also says, "I personally use the Minions 01:04:44.600 --> 01:04:47.679 package by Tarsius, and it has some nice features in 01:04:47.680 --> 01:04:48.959 addition to the built-in features." 01:04:48.960 --> 01:04:51.008 So other people are tinkering around 01:04:51.009 --> 01:04:52.919 with their mode lines as well. 01:04:58.320 --> 01:04:58.919 [Amin]: Yeah, it's pretty cool. 01:04:58.920 --> 01:05:02.479 And then I don't know, I think maybe you touched on 01:05:02.480 --> 01:05:04.399 something a couple of minutes ago that I was going to 01:05:04.400 --> 01:05:07.179 go back to, but I forget. NOTE TRAMP completion 01:05:07.180 --> 01:05:09.999 [Sacha]: Tramp SSH completion out of your configs. 01:05:10.000 --> 01:05:12.919 I was like, there's a Tramp sconfig in here that I've 01:05:12.920 --> 01:05:13.639 never used. 01:05:13.640 --> 01:05:15.119 And that sounded interesting. 01:05:15.120 --> 01:05:20.839 Yeah, tramp-parse-sconfig. 01:05:20.840 --> 01:05:24.699 [Amin]: Ah, right, right, right. Yeah. 01:05:24.700 --> 01:05:26.599 [Sacha]: Which, of course, we're not going to let go 01:05:26.600 --> 01:05:29.359 because it's private stuff, but yeah. 01:05:29.360 --> 01:05:29.999 [Amin]: Right. 01:05:30.000 --> 01:05:31.199 Yeah, you're welcome to try this. 01:05:31.200 --> 01:05:33.319 I'm pretty sure, actually, I took this from the Tramp 01:05:33.320 --> 01:05:34.159 manual itself. 01:05:34.160 --> 01:05:37.679 And it's one of those things where it's set and 01:05:37.680 --> 01:05:40.719 forget, I don't remember. 01:05:40.720 --> 01:05:41.639 But yeah, it's here. 01:05:41.640 --> 01:05:45.519 There was something else that I also wanted to show, 01:05:45.520 --> 01:05:46.159 but I forget. 01:05:46.160 --> 01:05:49.759 Let me see if looking at the outlines will remind me 01:05:49.760 --> 01:05:52.539 or if I will see it. 01:05:52.540 --> 01:05:53.799 [Sacha]: And that's one of the things I love about 01:05:53.800 --> 01:05:56.199 literate configuration is, you know, just kind of look 01:05:56.200 --> 01:05:59.479 at the structure and skim it and try to find something 01:05:59.480 --> 01:06:03.839 with keywords and ordered lists and all that stuff. 01:06:03.840 --> 01:06:07.799 [Amin]: Right. Yup. Exactly. 01:06:07.800 --> 01:06:10.039 [Sacha]: Oh, and you know, people will have access to 01:06:10.040 --> 01:06:12.119 your full configuration because it is in your 01:06:12.120 --> 01:06:14.999 repository and you have that lovely HTML expert for it 01:06:15.000 --> 01:06:15.559 as well. 01:06:15.560 --> 01:06:20.159 So if you, uh, if, if people want to follow up, they 01:06:20.160 --> 01:06:20.799 can go through that 01:06:20.800 --> 01:06:24.319 at length. At some point, you're going to add some more 01:06:24.320 --> 01:06:27.919 screenshots and possibly even video clips to it. 01:06:27.920 --> 01:06:34.539 so that's there you at git.kelar.org NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0053.jpg #+SCREENSHOT_TIME: 01:06:34.567 01:06:34.540 --> 01:06:36.159 [Amin]: This is my configurations repository. 01:06:36.160 --> 01:06:41.159 If you go here to treeview .emacs.d, this is the org 01:06:41.160 --> 01:06:41.919 file. 01:06:41.920 --> 01:06:45.639 I also export all of those individual components into 01:06:45.640 --> 01:06:47.279 this lisp subdirectory. 01:06:47.280 --> 01:06:49.319 All that stuff is here. 01:06:49.320 --> 01:06:54.299 The QMK thingy that was mentioned. NOTE ffs: form feed slides, ^L #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0054.jpg #+SCREENSHOT_TIME: 01:08:15.933 01:06:54.300 --> 01:06:55.359 Oh, I wanted to mention FFS. 01:06:55.360 --> 01:06:56.399 Okay, I'll do that as well. 01:06:56.400 --> 01:06:57.959 Yeah, what's up with that? 01:06:57.960 --> 01:06:59.199 [Sacha]: I was trying to find information. 01:06:59.200 --> 01:07:00.559 It was like, there's no package. 01:07:00.560 --> 01:07:05.539 It's not what is this thing? 01:07:05.540 --> 01:07:07.959 [Amin]: It's FormFeed Slides and it's going to soon be 01:07:07.960 --> 01:07:08.359 a package. 01:07:08.360 --> 01:07:10.519 I was actually talking to Prot about it and I'm hoping 01:07:10.520 --> 01:07:13.399 to submit it for inclusion in GNU ELPA within, I don't 01:07:13.400 --> 01:07:15.279 know, the next couple of weeks. 01:07:15.280 --> 01:07:18.759 It's basically very similar to Prot's Logos package. 01:07:18.760 --> 01:07:22.999 Turns out we both had the same kind of idea at the 01:07:23.000 --> 01:07:26.599 exact same time in 2022, and we both used it for our 01:07:26.600 --> 01:07:30.319 LibrePlanet 2022 presentations. 01:07:30.320 --> 01:07:33.119 Of course, Prot being the diligent person that he is, 01:07:33.120 --> 01:07:35.428 he polished his work, documented it, 01:07:35.429 --> 01:07:36.479 put it on GNU ELPA. 01:07:36.480 --> 01:07:38.622 I still haven't gotten around to doing it yet, 01:07:38.623 --> 01:07:40.719 but better late than never. 01:07:40.720 --> 01:07:42.359 Yeah, let's see. 01:07:42.360 --> 01:07:44.559 I can maybe show a quick demonstration of that. 01:07:44.560 --> 01:07:47.719 So let's see. 01:07:47.720 --> 01:07:49.399 Let's see. 01:07:49.400 --> 01:07:57.439 Anyway, so if I go to my website sources and 01:07:57.440 --> 01:08:00.159 net-beyond-web. 01:08:00.160 --> 01:08:03.759 So I had the LibrePlanet talk a couple years ago. 01:08:03.760 --> 01:08:07.959 So what FFS is basically, it looks for a 01:08:07.960 --> 01:08:08.867 particular character in this case, 01:08:08.868 --> 01:08:12.919 or the default case, 01:08:12.920 --> 01:08:15.929 it's the page delimiter, ^L, 01:08:15.930 --> 01:08:19.079 which you can insert by hitting C-q C-l. 01:08:19.080 --> 01:08:23.759 It basically then designates each of these areas 01:08:23.760 --> 01:08:28.959 as one slide. So, very, very simple slideshow 01:08:28.960 --> 01:08:31.439 that you don't even have to use Org or outline or any 01:08:31.440 --> 01:08:35.599 other major or minor mode. If I launch ffs, 01:08:35.600 --> 01:08:42.239 by default, it's in a mode where it binds a couple of 01:08:42.240 --> 01:08:44.919 convenience keys, like p and n, to go into the next 01:08:44.920 --> 01:08:45.639 and previous slide. 01:08:45.640 --> 01:08:49.999 You can hit e to edit a slide, similar to Org source, and 01:08:50.000 --> 01:08:52.639 then make your changes and all of that. 01:08:52.640 --> 01:08:57.899 And then you can start a presentation by hitting s. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0055.jpg #+SCREENSHOT_TIME: 01:08:58.767 01:08:57.900 --> 01:09:01.439 It has hooks for, for example, bumping up the font size 01:09:01.440 --> 01:09:04.599 or whatever, hiding the mode line. 01:09:04.600 --> 01:09:07.599 I can toggle the mode line by hitting M here. 01:09:07.600 --> 01:09:10.959 Let's see. 01:09:10.960 --> 01:09:16.399 I can also toggle the cursor, to make the cursor 01:09:16.400 --> 01:09:17.199 visible or not. 01:09:17.200 --> 01:09:18.439 So, yeah. 01:09:18.440 --> 01:09:23.479 And then I'm just hitting P and N. 01:09:23.480 --> 01:09:25.119 [Sacha]: Very simple, very minimalist. 01:09:25.120 --> 01:09:28.399 You have a file, you've got page markers, and that's 01:09:28.400 --> 01:09:31.859 all you got. 01:09:31.860 --> 01:09:32.919 [Amin]: Yeah, pretty much. 01:09:32.920 --> 01:09:34.819 And then... NOTE Speaker notes 01:09:34.820 --> 01:09:36.799 The neat thing that it has that I also liked 01:09:36.800 --> 01:09:39.799 implementing at the time is it has a speaker notes 01:09:39.800 --> 01:09:40.639 feature. NOTE #+SCREENSHOT: /home/sacha/proj/yay-emacs/mpv-shot0056.jpg #+SCREENSHOT_TIME: 01:09:47.767 01:09:40.640 --> 01:09:44.999 So you can designate a file as being the speaker 01:09:45.000 --> 01:09:47.759 notes where it has the same structure separators with 01:09:47.760 --> 01:09:50.679 ^L. But you can type your notes over here, 01:09:50.680 --> 01:09:50.959 whatever. 01:09:50.960 --> 01:09:54.639 And you can basically open these in two different 01:09:54.640 --> 01:09:57.879 windows or two different frames on separate displays. 01:09:57.880 --> 01:10:01.159 And then in whichever one of those you advance the 01:10:01.160 --> 01:10:05.779 slides, like p n n, it also does the other one. 01:10:05.780 --> 01:10:06.967 [Sacha]: That's brilliant. 01:10:06.968 --> 01:10:09.319 I was looking for a way to do that so I can pretend to 01:10:09.320 --> 01:10:11.279 know what I'm talking about when I have something on 01:10:11.280 --> 01:10:15.159 screen, but I can just read my notes or even just 01:10:15.160 --> 01:10:16.839 remember what points I wanted to make. 01:10:16.840 --> 01:10:18.039 So this is great. 01:10:18.040 --> 01:10:19.119 You have speaker notes. 01:10:19.120 --> 01:10:20.639 You've got the main screen. 01:10:20.640 --> 01:10:21.999 They can be in two different frames. 01:10:22.000 --> 01:10:24.679 You can have your frame that you're sharing and your 01:10:24.680 --> 01:10:27.199 frame that you're not sharing that has all of your 01:10:27.200 --> 01:10:27.799 cheat sheets. 01:10:27.800 --> 01:10:29.079 Excellent. 01:10:29.080 --> 01:10:31.119 And on that note, in about one minute, the kid is 01:10:31.120 --> 01:10:34.039 going to come running out and want to have snack and 01:10:34.040 --> 01:10:34.599 all that stuff. 01:10:34.600 --> 01:10:37.959 Thank you so much for walking through parts of your 01:10:37.960 --> 01:10:38.279 config. 01:10:38.280 --> 01:10:39.559 There is more. 01:10:39.560 --> 01:10:42.559 And so everyone who wants to find out more can go 01:10:42.560 --> 01:10:43.759 check out your setup. 01:10:43.760 --> 01:10:47.359 I have a great many things that I want to try out, 01:10:47.360 --> 01:10:53.039 starting from EXWM to little things like figuring out 01:10:53.040 --> 01:10:55.799 a boom mic setup because apparently your audio setup 01:10:55.800 --> 01:10:57.159 is making me very jealous. 01:10:57.160 --> 01:11:00.279 Yes, thank you for doing this. 01:11:00.280 --> 01:11:02.839 I'm going to post the transcript and the chapters. 01:11:02.840 --> 01:11:04.479 I have a chapter every minute. 01:11:04.480 --> 01:11:08.319 It's going to be a long time. 01:11:08.320 --> 01:11:09.399 But it was good. 01:11:09.400 --> 01:11:10.359 Lots of cool stuff. 01:11:10.360 --> 01:11:13.199 Thank you again. 01:11:13.200 --> 01:11:14.233 [Amin]: Sounds great. 01:11:14.234 --> 01:11:15.159 And yeah, you're very welcome. 01:11:15.160 --> 01:11:16.959 And thank you so much for having me as well, Sacha. 01:11:16.960 --> 01:11:19.159 I'm very delighted to be here, especially, I think, 01:11:19.160 --> 01:11:20.359 just by chance. 01:11:20.360 --> 01:11:23.079 I think I'm the first person who you're doing this 01:11:23.080 --> 01:11:24.759 with after the long hiatus. 01:11:24.760 --> 01:11:26.679 So that's an extra honor for me. 01:11:26.680 --> 01:11:28.759 But yeah, it's been fun. 01:11:28.760 --> 01:11:32.479 I could go on for hours. 01:11:32.480 --> 01:11:33.719 I'm sure we both could. 01:11:33.720 --> 01:11:37.219 This has been fun. 01:11:37.220 --> 01:11:39.233 [Sacha]: If we wanted to go on for hours, 01:11:39.234 --> 01:11:40.933 Prot has more flexible scheduling, 01:11:40.934 --> 01:11:43.033 so he can chat with people for 01:11:43.034 --> 01:11:44.667 two hours and stuff, and you already have 01:11:44.668 --> 01:11:46.159 conversations going on with him. 01:11:46.160 --> 01:11:48.959 But I unfortunately have a small mammal who's 10 01:11:48.960 --> 01:11:52.119 years old and loves me very much, and likes to not let 01:11:52.120 --> 01:11:53.799 me concentrate for very long. 01:11:53.800 --> 01:11:56.319 But thank you everyone for joining. 01:11:56.320 --> 01:11:57.799 Thank you for the chat. 01:11:57.800 --> 01:11:58.959 And thank you also, stream, 01:11:58.960 --> 01:12:00.319 for all the interesting questions. 01:12:00.320 --> 01:12:02.519 I will send you all the information 01:12:02.520 --> 01:12:03.479 and update the post. 01:12:03.480 --> 01:12:06.599 And we'll see you all on Thursday. 01:12:06.600 --> 01:12:08.279 I've got another chat. 01:12:08.280 --> 01:12:10.719 All of a sudden, all these Emacs chats 01:12:10.720 --> 01:12:11.719 are going to happen. 01:12:11.720 --> 01:12:12.119 Thanks. 01:12:12.120 --> 01:12:16.119 Oh, and you said you're happy to be on the hook for 01:12:16.120 --> 01:12:20.259 doing another EmacsConf this year, right? 01:12:20.260 --> 01:12:21.868 [Amin]: Yes. You can hold me to that. 01:12:21.480 --> 01:12:23.200 There will be another EmacsConf 01:12:23.201 --> 01:12:24.933 and I will be active in it. 01:12:24.934 --> 01:12:26.567 [Sacha]: Alright then, I'm going to end that broadcast. 01:12:26.568 --> 01:12:29.159 Thanks everyone, bye! 01:12:29.160 --> 01:12:30.000 [Amin]: Thank you, bye bye!