1
00:00:00,000 --> 00:00:04,780
[MUSIC]

2
00:00:04,780 --> 00:00:09,845
As we understood from
the previous lesson building and

3
00:00:09,845 --> 00:00:14,960
deployment of websites
involves a lot of steps.

4
00:00:14,960 --> 00:00:19,070
And we looked at the use
of [INAUDIBLE] scripts for

5
00:00:19,070 --> 00:00:22,220
doing the building and deployment tasks.

6
00:00:22,220 --> 00:00:27,820
In this lesson,
we will concentrate on task renders.

7
00:00:27,820 --> 00:00:33,190
Two in particular, Grunt and
Gulp, and try to understand how

8
00:00:33,190 --> 00:00:39,669
they facilitate their automation of
the various web developement tasks.

9
00:00:41,640 --> 00:00:47,650
The primary task of a Task Runner is to
enable to us to configure the tasks and

10
00:00:47,650 --> 00:00:50,410
then rerun them automatically
as it when request.

11
00:00:51,640 --> 00:00:56,515
In the previous Lesson, we show
the user NPM scripts that we set up in

12
00:00:56,515 --> 00:01:02,325
the package.json file in order
to automate some of these tasks,

13
00:01:02,325 --> 00:01:07,945
including the use of the on
change to automatically

14
00:01:07,945 --> 00:01:14,245
run some of these tasks based upon
changes to files that are made.

15
00:01:15,805 --> 00:01:22,420
Now, thinking back, we realize
that we are in the Node ecosystem.

16
00:01:22,420 --> 00:01:30,440
And what Node enables us to do is
to run JavaScript on the desktop.

17
00:01:30,440 --> 00:01:34,460
Now, better luck than people,
the programmers as you know of them,

18
00:01:36,200 --> 00:01:42,070
took on the task of using
JavaScript itself to write

19
00:01:43,620 --> 00:01:48,970
applications that enable us to set up and
run these tasks automatically.

20
00:01:48,970 --> 00:01:52,305
So this is where the task
runners came into the picture.

21
00:01:52,305 --> 00:01:58,930
Grunt, Gulp, Cake, Brunch, Broccoli.

22
00:01:58,930 --> 00:02:00,640
What's this obsession with food?

23
00:02:01,760 --> 00:02:06,150
Well when you're sitting in a single
place for a long time, you develop a big

24
00:02:06,150 --> 00:02:12,260
appetite, Grunt and Gulp being
the two most successful in this field.

25
00:02:12,260 --> 00:02:15,730
We'll look at both of them in
more detail in this lesson.

26
00:02:17,070 --> 00:02:22,360
These enable us to double
up automated tasks for

27
00:02:22,360 --> 00:02:26,410
executing and building and
deploying our website.

28
00:02:27,620 --> 00:02:31,520
As I mentioned,
the JavaScript based task runners, the two

29
00:02:31,520 --> 00:02:36,980
of them in particular that we will deal
with in this lesson are Grunt and Gulp.

30
00:02:36,980 --> 00:02:41,391
Grunt operates based
on doing configuration

31
00:02:41,391 --> 00:02:45,800
whereas Gulp concentrates more on code.

32
00:02:45,800 --> 00:02:50,160
We'll look at the two of them
in more detail as we go along.

33
00:02:50,160 --> 00:02:58,120
But both of them pretty much enable us
to accomplish the same kind of tasks.

34
00:02:58,120 --> 00:02:59,970
Both are built around plugins.

35
00:02:59,970 --> 00:03:04,980
So, both Grunt and
Gulp provide a framework for which

36
00:03:04,980 --> 00:03:10,600
you write various plugins that enable
you to perform these kinds of tasks.

37
00:03:10,600 --> 00:03:15,810
So Grunt and Gulp together with their
plugins enable us to configure and

38
00:03:15,810 --> 00:03:18,380
execute various tasks.

39
00:03:18,380 --> 00:03:24,600
If you ask me, is Grunt better or is Gulp
better, that's a tough question to answer.

40
00:03:26,140 --> 00:03:27,850
The Grunt people are grunting all over,

41
00:03:29,010 --> 00:03:31,700
saying that theirs is
the best way of doing it.

42
00:03:33,050 --> 00:03:36,390
Which the Gulp community
finds hard to swallow.

43
00:03:38,730 --> 00:03:44,020
Both these communities can easily give
your televangelists a run for their money.

44
00:03:45,800 --> 00:03:48,160
But, from my perspective,

45
00:03:49,950 --> 00:03:54,880
I look at any of these tools as just
mechanisms to get my work done.

46
00:03:55,950 --> 00:03:59,410
So long as it gets my work done,
I'm happy with it.

47
00:03:59,410 --> 00:04:04,910
If one makes it easier to
accomplish a set of tasks that has,

48
00:04:04,910 --> 00:04:09,600
then I choose the one over the other for
that particular project.

49
00:04:10,760 --> 00:04:17,190
So my take is event VM scripts
satisfies you, stable them.

50
00:04:17,190 --> 00:04:20,460
If Grunt is the way to go, be my guest.

51
00:04:20,460 --> 00:04:26,710
If Gulp is worth satisfies you, take
you a big gulp and you'll be satisfied.

52
00:04:27,850 --> 00:04:32,486
So having said that,
let's take a look at both Grunt and Gulp.

53
00:04:32,486 --> 00:04:38,880
I will show you how you
perform the same set of tasks

54
00:04:38,880 --> 00:04:43,810
that I did with the npm scripts in
the previous lesson and the exercise.

55
00:04:45,730 --> 00:04:50,483
By showing you the Grunt and
the Gulp way of doing the same

56
00:04:50,483 --> 00:04:55,355
sort of tasks in the exercises
that follow this lecture.

57
00:04:55,355 --> 00:04:58,239
[MUSIC]