[Script Info] Title: [Events] Format: Layer, Start, End, Style, Name, MarginL, MarginR, MarginV, Effect, Text Dialogue: 0,0:00:00.00,0:00:03.03,Default,,0000,0000,0000,,Hi Welcome to Emacs Rocks! Dialogue: 0,0:00:03.03,0:00:07.38,Default,,0000,0000,0000,,I just started using Emacs. I've been using TextMate for a few years and Dialogue: 0,0:00:08.12,0:00:12.23,Default,,0000,0000,0000,,I've been looking for something else. I tried vim, it's nice. Dialogue: 0,0:00:13.50,0:00:16.86,Default,,0000,0000,0000,,But I've been using Emacs for a few weeks now and Dialogue: 0,0:00:16.86,0:00:21.40,Default,,0000,0000,0000,,I'm really loving it, it's awesome. So I was thinking, Dialogue: 0,0:00:21.40,0:00:26.19,Default,,0000,0000,0000,,Hey! All this cool stuff I have to share with someone - and that's you! Dialogue: 0,0:00:26.47,0:00:32.20,Default,,0000,0000,0000,,So this is the first episode. If you want to see more, there's a Dialogue: 0,0:00:32.20,0:00:36.90,Default,,0000,0000,0000,,just follow me @emacsrocks on Twitter. Ok, First trick Dialogue: 0,0:00:39.87,0:00:46.63,Default,,0000,0000,0000,,I've been doing some Javascript testing lately and every so often I get to these situations Dialogue: 0,0:00:46.63,0:00:51.04,Default,,0000,0000,0000,,I have some local variables and I want to extract them into the setup method Dialogue: 0,0:00:51.35,0:00:53.16,Default,,0000,0000,0000,,So let's do that Dialogue: 0,0:01:05.00,0:01:08.90,Default,,0000,0000,0000,,Ok, for these variables to be available in my tests Dialogue: 0,0:01:08.90,0:01:12.93,Default,,0000,0000,0000,,I have to assign them to the test object, this. Dialogue: 0,0:01:13.39,0:01:14.48,Default,,0000,0000,0000,,And here is the trick. Dialogue: 0,0:01:17.88,0:01:23.01,Default,,0000,0000,0000,,Pay close attention to the keys I'm pressing Dialogue: 0,0:01:23.07,0:01:27.23,Default,,0000,0000,0000,,they appear in the lower right-hand corner and I will repeat it afterwards Dialogue: 0,0:01:38.79,0:01:40.38,Default,,0000,0000,0000,,Wow! Dialogue: 0,0:01:40.93,0:01:44.70,Default,,0000,0000,0000,,Did you see that? That's amazing. Let's try it again. Dialogue: 0,0:01:48.68,0:01:52.87,Default,,0000,0000,0000,,It's important that I start where I start now, just at the var Dialogue: 0,0:01:53.42,0:02:00.70,Default,,0000,0000,0000,,Because when I search for "l" like this, the mark is saved where my search started Dialogue: 0,0:02:00.70,0:02:04.69,Default,,0000,0000,0000,,so the mark is now at the beginning of the first var Dialogue: 0,0:02:04.69,0:02:10.84,Default,,0000,0000,0000,,the mark and the point of the cursor, together they form a region Dialogue: 0,0:02:10.84,0:02:14.72,Default,,0000,0000,0000,,including the three vars and the space afterwards. Dialogue: 0,0:02:14.72,0:02:19.68,Default,,0000,0000,0000,,So let me do: Control-x rectangle text Dialogue: 0,0:02:21.16,0:02:25.48,Default,,0000,0000,0000,,Which will replace the contents of the region with whatever I write. Dialogue: 0,0:02:27.22,0:02:29.64,Default,,0000,0000,0000,,That rocks! Dialogue: 0,0:02:31.18,0:02:36.57,Default,,0000,0000,0000,,So if we check up rectangles in the manual, here is the command I used Dialogue: 0,0:02:40.15,0:02:43.35,Default,,0000,0000,0000,,That was the first episode, thanks for watching Dialogue: 0,0:02:43.35,9:59:59.99,Default,,0000,0000,0000,,and follow me on @emacsrocks if you want more. Thanks.