1
00:00:00,060 --> 00:00:02,050
- In many cases I work with files

2
00:00:02,050 --> 00:00:04,040
that reference other files.

3
00:00:04,040 --> 00:00:06,010
If you look at "index.md";

4
00:00:06,010 --> 00:00:08,070
Vim index dot md.

5
00:00:08,070 --> 00:00:10,060
You will see a list of files.

6
00:00:10,060 --> 00:00:12,010
Lets go to "new.txt";

7
00:00:12,010 --> 00:00:14,070
So file, slash, new and enter.

8
00:00:14,070 --> 00:00:17,020
We can now copy the file name and open it,

9
00:00:17,020 --> 00:00:20,040
but instead of that we can use "gf",

10
00:00:20,040 --> 00:00:22,030
which stands for "go to file"

11
00:00:22,030 --> 00:00:25,030
and the new file will be opened.

12
00:00:25,030 --> 00:00:29,020
If you have an error from a compiler, such as in "error.txt"

13
00:00:29,020 --> 00:00:33,070
so colon e for edit, "error.txt".

14
00:00:33,070 --> 00:00:35,030
This is a very common format.

15
00:00:35,030 --> 00:00:37,050
We see the file name, the line number

16
00:00:37,050 --> 00:00:39,040
and the offending column.

17
00:00:39,040 --> 00:00:42,080
"gf" will open the file, but if you use g, shift, f,

18
00:00:42,080 --> 00:00:44,090
it will open the file in the right line.

19
00:00:44,090 --> 00:00:47,080
So g, shift, f, and we open the file

20
00:00:47,080 --> 00:00:51,090
in the right line number. Very handy.

21
00:00:51,090 --> 00:00:54,050
If you have "wget" or "crn" installed,

22
00:00:54,050 --> 00:00:56,080
you can even fetch URLs.

23
00:00:56,080 --> 00:00:58,040
Switch to "index.md".

24
00:00:58,040 --> 00:01:02,020
So, "b" buffer, "IN" and then tab and

25
00:01:02,020 --> 00:01:04,030
Vim will complete the file name.

26
00:01:04,030 --> 00:01:05,060
Now enter.

27
00:01:05,060 --> 00:01:08,030
Lets go to the bottom with shift, g.

28
00:01:08,030 --> 00:01:13,050
And then, w, w, w you get to the url.

29
00:01:13,050 --> 00:01:16,090
And now if you do "gf" Vim is going to fetch

30
00:01:16,090 --> 00:01:19,090
the sources and if you click on enter you will

31
00:01:19,090 --> 00:01:22,000
see the HTML source of the webpage.

