1
00:00:01,230 --> 00:00:06,550
Now with that knowledge we have learned it's time to build something amazing.

2
00:00:06,570 --> 00:00:12,530
Imagine that you work for a company where a group of people work with specific files which cannot have

3
00:00:12,590 --> 00:00:17,080
dabster spaces at the beginning or at the end of lines.

4
00:00:17,190 --> 00:00:23,790
So your boss asked you to create a script for checking if there is no space or up at the beginning or

5
00:00:23,870 --> 00:00:25,630
at the end of each line.

6
00:00:25,770 --> 00:00:29,390
And also the script should be able to fix possible issues.

7
00:00:29,400 --> 00:00:37,570
And that means remove any space or taps at the beginning or at the end of each line.

8
00:00:37,620 --> 00:00:45,060
So when I for example check file that text I see graphically where the spaces and tabs are present.

9
00:00:45,360 --> 00:00:48,420
And in addition I also see line numbering.

10
00:00:48,630 --> 00:00:52,430
So here I have eight lines and batch of errors.

11
00:00:53,220 --> 00:00:55,070
But I should be able to fix it.

12
00:00:55,100 --> 00:00:59,060
Now let's use barometer H for help.

13
00:00:59,070 --> 00:01:04,450
So I see that using parameter def or a fix I can fix space issue.

14
00:01:04,500 --> 00:01:05,310
So let's write

15
00:01:10,730 --> 00:01:18,230
I see printed fixing spaces and UPS at the beginning and at the end of lines then I see content of the

16
00:01:18,230 --> 00:01:27,010
file with no error and the message with the green background done so fixes them has rejected we don't

17
00:01:27,010 --> 00:01:28,240
see any issue now.

18
00:01:28,240 --> 00:01:29,030
Great.

19
00:01:29,140 --> 00:01:31,380
So let's create some errors.

20
00:01:37,840 --> 00:01:45,570
So I got a few spaces summed up on another line.

21
00:01:45,610 --> 00:01:57,580
I am adding new spaces and also I can add more taps next to each other and do on space here and we can

22
00:01:57,580 --> 00:01:59,810
save the file.

23
00:01:59,920 --> 00:02:01,490
Now we can run our script.

24
00:02:01,540 --> 00:02:06,650
And if you write we see where the arrows are great.

25
00:02:06,700 --> 00:02:08,490
So let's fix it.

26
00:02:09,190 --> 00:02:15,110
I will now instead of Desch f barometer use parameter.

27
00:02:15,160 --> 00:02:16,200
They should fix

28
00:02:19,330 --> 00:02:20,770
both of them do the same.

29
00:02:20,860 --> 00:02:21,680
And I see.

30
00:02:21,690 --> 00:02:26,590
Message them when I recheck.

31
00:02:26,900 --> 00:02:28,670
I don't see any space issue.

32
00:02:28,670 --> 00:02:29,380
Great.

33
00:02:29,420 --> 00:02:31,910
It works perfectly.

34
00:02:31,970 --> 00:02:40,140
I can of course use another location for example I can check Basford file.

35
00:02:40,260 --> 00:02:42,940
I don't see any red warning here.

36
00:02:43,080 --> 00:02:49,840
So password file doesn't have any space or top at the beginning or at the end of each line.

37
00:02:51,050 --> 00:02:58,790
So in following pictures we will build discrete Step-By-Step we will use a lot of set features and we

38
00:02:58,790 --> 00:03:02,550
will definitely Pretis require expression it out.

39
00:03:02,750 --> 00:03:09,530
Basically we will use knowledge we have learned about scripting and combine them with set.
