WEBVTT

00:00.540 --> 00:02.059
All right. Hello and welcome to

00:02.100 --> 00:03.100
Command Line.

00:03.240 --> 00:04.612
This module will be an intro

00:05.280 --> 00:06.660
to Common Windows Tools.

00:06.810 --> 00:08.489
I'm Christopher Haler and let's get

00:08.490 --> 00:09.490
started.

00:10.050 --> 00:11.765
So the learning objectives for this

00:11.970 --> 00:13.469
module is we want to learn how to

00:13.470 --> 00:15.749
read files, learn how to copy files,

00:15.960 --> 00:17.879
understand how to delete files,

00:18.120 --> 00:19.619
and understand how to search through

00:19.620 --> 00:21.286
files all from the Windows command

00:21.480 --> 00:22.480
line

00:23.940 --> 00:24.940
assessment.

00:24.990 --> 00:27.239
So moving a file

00:27.240 --> 00:29.430
is a way to rename it true

00:29.700 --> 00:30.700
or false

00:32.340 --> 00:33.720
answer is true.

00:34.710 --> 00:36.327
If you were watching the previous

00:36.450 --> 00:38.570
video, you learn from the wouldn't

00:38.880 --> 00:40.979
the Linux commands excuse me that

00:41.130 --> 00:43.229
the move command is also

00:43.230 --> 00:44.230
used to rename files

00:45.240 --> 00:46.459
in the special kind of way.

00:46.830 --> 00:48.869
So it's the same deal with Windows,

00:48.870 --> 00:50.291
the same kind of ideas behind

00:50.820 --> 00:51.849
it, where if you move

00:52.710 --> 00:53.837
a file, it makes a copy

00:54.840 --> 00:56.669
of it at the new location and

00:56.670 --> 00:58.042
then it deletes the original

00:58.560 --> 00:59.560
copy of it.

01:01.020 --> 01:02.939
All right. So reading text files

01:02.970 --> 01:04.809
from the Windows Command, we

01:04.810 --> 01:06.269
got two commands we can use.

01:06.420 --> 01:07.890
We have the type command which

01:08.400 --> 01:10.200
displays the contents of a file,

01:10.650 --> 01:12.316
and we also have the more command,

01:12.840 --> 01:14.819
which is very similar to the

01:14.820 --> 01:16.080
Linux, more command.

01:16.920 --> 01:19.040
And this displays the file

01:19.050 --> 01:20.329
one screen at a time.

01:20.820 --> 01:21.996
So if there is too much,

01:22.770 --> 01:24.930
too much text on the screen at once,

01:25.170 --> 01:26.819
more will allow you to read it.

01:26.970 --> 01:28.919
And then you can choose to go

01:28.920 --> 01:30.779
either one line down with the enter

01:30.780 --> 01:31.780
key or go a page

01:32.790 --> 01:34.159
down with the spacebar.

01:34.800 --> 01:36.119
All right. And now I will give you a

01:36.120 --> 01:37.919
quick demonstration of these

01:37.920 --> 01:38.920
commands.

01:40.440 --> 01:42.155
So I'm going to open up the command

01:42.450 --> 01:44.400
prompt, I'm going to type

01:45.030 --> 01:46.139
to see what is inside of this

01:46.140 --> 01:47.140
directory and I need

01:48.030 --> 01:49.500
to get to my desktop folder so

01:50.040 --> 01:51.180
I could

01:52.080 --> 01:54.050
ask a tab on

01:54.090 --> 01:55.799
a complete and or

01:56.340 --> 01:58.319
another Dyax to see what's inside

01:58.320 --> 01:59.730
of my desktop directory.

02:00.720 --> 02:02.219
And I need to get into this

02:02.220 --> 02:03.360
resources folder.

02:03.450 --> 02:05.519
So I will do c, d, r, e

02:05.520 --> 02:06.359
s.

02:06.360 --> 02:07.732
And as you may know, Windows

02:08.610 --> 02:10.499
is not case sensitive like Linux

02:10.500 --> 02:12.599
is. So I can do a lower case r here

02:12.900 --> 02:13.900
push tab and it will

02:14.940 --> 02:16.361
automatically autocomplete it

02:16.770 --> 02:18.679
with a capital R and

02:18.890 --> 02:20.550
enter dargin

02:20.820 --> 02:22.388
and I have to text files another

02:22.560 --> 02:23.560
directory in here.

02:23.940 --> 02:25.949
So first I'm going to do the

02:26.010 --> 02:27.749
type command on words

02:29.820 --> 02:30.719
and this is great.

02:30.720 --> 02:31.847
It spits out all of the

02:32.580 --> 02:34.439
text inside of this text file

02:34.500 --> 02:36.299
so that we can read it from inside

02:36.300 --> 02:37.989
of the command prompt here.

02:38.730 --> 02:39.730
Now a limitation of

02:40.800 --> 02:42.564
the type command is that if you have

02:42.720 --> 02:43.860
a longer file,

02:44.970 --> 02:46.229
unless you have this kind of

02:46.230 --> 02:47.406
scrollbar, it's it's not

02:48.180 --> 02:49.709
going to be able to be read very

02:49.710 --> 02:50.710
easily.

02:50.840 --> 02:52.830
So I type there again,

02:53.200 --> 02:54.419
you can do type

02:55.530 --> 02:56.530
lunger file

02:57.510 --> 02:58.686
and liley that if we did

02:59.430 --> 03:01.079
not have this rollbar here, it would

03:01.080 --> 03:02.080
be very difficult to

03:03.030 --> 03:05.249
be able to read the first

03:05.250 --> 03:07.199
half of this file, among others.

03:08.160 --> 03:09.777
So that is where the more command

03:10.110 --> 03:10.919
comes in.

03:10.920 --> 03:12.684
And this is very similar to the more

03:12.780 --> 03:13.780
command on Linux

03:14.850 --> 03:16.620
type, more longer file.

03:17.380 --> 03:19.259
And this allows us to read from

03:19.260 --> 03:21.060
the first line up here at the top.

03:21.690 --> 03:22.719
And similarly, we can

03:23.580 --> 03:25.080
push enter to go down one line

03:25.740 --> 03:27.600
or we can push the spacebar to

03:27.760 --> 03:28.800
a full page at a time.

03:29.760 --> 03:31.199
So that is the type.

03:31.200 --> 03:32.579
And the more commands that you can

03:32.580 --> 03:33.580
read text from the

03:34.440 --> 03:35.440
command line.

03:37.460 --> 03:39.439
Aren't copying files, this

03:39.470 --> 03:41.038
can be very similar to the Linux

03:41.210 --> 03:42.210
commands as well.

03:42.920 --> 03:44.635
They are named differently, though,

03:44.870 --> 03:47.030
so instead of S.P., this is the full

03:47.120 --> 03:49.309
copy instead of MVE

03:49.490 --> 03:51.349
or R.M.

03:51.350 --> 03:53.029
for deleting. We have move

03:53.330 --> 03:55.159
and we have Dell

03:55.160 --> 03:56.160
for delete.

03:56.240 --> 03:57.240
So for copy we

03:58.130 --> 04:00.289
can copy files and folders, move,

04:00.290 --> 04:02.419
move files and folders and

04:02.420 --> 04:04.037
we actually have a rename command

04:04.550 --> 04:06.289
inside of Windows where we can

04:06.290 --> 04:07.290
actually change

04:08.240 --> 04:09.906
the name of file instead of having

04:10.220 --> 04:11.739
to use a move command to change

04:12.110 --> 04:13.110
it for us.

04:14.990 --> 04:16.360
Now deleting files,

04:16.850 --> 04:18.379
we have the Dell come in, this can

04:18.380 --> 04:20.059
be used to delete files

04:20.329 --> 04:21.505
and erase command is the

04:22.190 --> 04:23.570
same as the Dell Command.

04:24.230 --> 04:25.945
It is just what's known as an alias

04:26.240 --> 04:28.249
for it. So it's kind of like a

04:28.250 --> 04:30.230
secondary name for the same command.

04:30.860 --> 04:32.183
And if you find yourself in

04:32.750 --> 04:34.219
the position where you need to

04:34.220 --> 04:36.160
delete full directories,

04:36.500 --> 04:38.439
you can use the as

04:38.450 --> 04:40.639
a switch and then that will delete

04:40.640 --> 04:42.020
a full directory for you.

04:42.770 --> 04:44.749
So let's do a quick demonstration of

04:44.750 --> 04:45.750
that.

04:46.970 --> 04:48.470
I am going to

04:48.950 --> 04:49.950
copy

04:51.770 --> 04:53.269
words that

04:54.080 --> 04:55.669
and I'm going to name those words

04:55.970 --> 04:57.319
to the text

04:59.090 --> 05:00.168
and do another dyanne.

05:00.620 --> 05:02.269
And we have our words to file.

05:02.870 --> 05:04.459
And now I will delete

05:05.600 --> 05:07.040
words to

05:07.430 --> 05:08.430
press tab

05:10.310 --> 05:12.259
Durgan and it is gone.

05:12.270 --> 05:14.449
So we were able to successfully copy

05:14.450 --> 05:15.769
and delete that file.

05:17.030 --> 05:18.030
From the command line.

05:19.620 --> 05:20.809
All right, now, searching through

05:20.810 --> 05:22.525
files, we are going to use the find

05:22.850 --> 05:24.889
in the fine string, so find

05:24.890 --> 05:26.689
it searches for a string, which is

05:26.690 --> 05:28.190
just a fancy way of saying

05:29.300 --> 05:30.649
text inside of a file

05:31.310 --> 05:32.990
and the fine string that

05:33.230 --> 05:35.449
commanded a little more robust.

05:35.460 --> 05:37.849
And it can use regular expressions

05:37.850 --> 05:39.026
or regex, and that's for

05:40.100 --> 05:41.749
certain pattern based searching.

05:42.650 --> 05:44.959
So I will show you a quick example

05:44.960 --> 05:45.960
of that.

05:46.470 --> 05:48.529
Let me see. I believe I put another

05:48.530 --> 05:49.951
secret in the longer file for

05:50.360 --> 05:52.189
Windows, so let's see if

05:52.190 --> 05:54.529
we can find secrets

05:54.650 --> 05:56.290
in longer five.

05:57.600 --> 05:59.509
Oh, I need to do my

05:59.510 --> 06:00.949
help. So find

06:01.700 --> 06:02.700
questionmark.

06:03.650 --> 06:05.000
All right. So let's see.

06:06.260 --> 06:07.889
It looks like the string needs to be

06:07.890 --> 06:09.799
inside, quote, so

06:09.800 --> 06:11.970
let's to find secret

06:13.650 --> 06:14.939
and then long file final

06:16.110 --> 06:16.979
and there we go.

06:16.980 --> 06:18.689
Looks like it found something.

06:23.290 --> 06:24.290
Where is it?

06:32.770 --> 06:34.629
Secret, it was right in front

06:34.630 --> 06:36.059
of me the whole time and let me

06:36.070 --> 06:37.899
market we go.

06:38.890 --> 06:40.749
So that's how I use the the

06:40.750 --> 06:42.189
fine command. You have to use the

06:42.190 --> 06:44.079
quotes. And, you know,

06:44.110 --> 06:45.939
just like you, I'm going to have to

06:45.940 --> 06:47.759
use them as much as I can.

06:48.790 --> 06:50.889
I post assessment, which commands

06:50.890 --> 06:52.899
can be used to read text on Windows

06:53.080 --> 06:54.480
and this can be a multi answer

06:54.490 --> 06:56.439
question. Is it A more

06:56.920 --> 06:59.139
B less C

06:59.140 --> 07:01.290
text or D type.

07:01.720 --> 07:03.459
And there are two correct answers to

07:03.460 --> 07:04.460
this question.

07:05.730 --> 07:07.445
The correct answer is more tintype,

07:07.980 --> 07:09.509
those are the two commands, so we

07:09.510 --> 07:11.078
went over where we can read text

07:11.790 --> 07:13.709
from text file at the command

07:13.710 --> 07:15.710
line, the less command,

07:15.720 --> 07:17.337
while it is a very useful command

07:17.850 --> 07:19.889
in Linux, it is not natively

07:19.890 --> 07:21.060
supported in Windows.

07:21.390 --> 07:23.039
And the text command is not a real

07:23.040 --> 07:24.209
command for reading text.

07:25.560 --> 07:26.729
All right. So in this video, we

07:26.730 --> 07:28.347
learned how to read files, how to

07:28.410 --> 07:29.684
copy files, understood how

07:30.270 --> 07:31.740
to delete files and understood

07:32.100 --> 07:33.449
how to search through files.

07:33.960 --> 07:35.489
And I look forward to seeing you in

07:35.490 --> 07:36.149
the next video.

