1
00:00:00,390 --> 00:00:06,689
All right, now let's take a look at how we can install a package globally and what would be some of

2
00:00:06,689 --> 00:00:07,580
the worst cases.

3
00:00:07,920 --> 00:00:10,260
And first, let's start with command.

4
00:00:10,450 --> 00:00:11,940
Let's jog your memory.

5
00:00:12,220 --> 00:00:17,400
Command was NPM install and then the ISG and the package name.

6
00:00:17,610 --> 00:00:20,010
And in Mac, they might ask you for permissions.

7
00:00:20,280 --> 00:00:22,230
So you'll have to start with Souto.

8
00:00:22,230 --> 00:00:25,510
And then again, same spiel, npm install, blah, blah, blah.

9
00:00:25,950 --> 00:00:31,080
And first, I want to showcase that I haven't installed no demand globally.

10
00:00:31,920 --> 00:00:41,460
And the easiest way for me to showcase that is by running node on an app Jayesh, so we'll try to install

11
00:00:41,790 --> 00:00:43,090
Nordman package globally.

12
00:00:43,110 --> 00:00:43,470
Why?

13
00:00:43,680 --> 00:00:47,490
Well, because then I could use Nordman in any of my projects.

14
00:00:47,490 --> 00:00:54,080
At the moment I have a local package and of course I can spin it up by running and rpm start.

15
00:00:54,090 --> 00:00:59,430
But let's imagine a scenario where I have, I don't know, 20 Knoedler applications and I'm constantly

16
00:00:59,430 --> 00:01:00,960
working on node applications.

17
00:01:01,320 --> 00:01:08,590
So to make my life easier, I will install Nordman globally and then I won't get this error because

18
00:01:08,590 --> 00:01:11,090
at the moment you can see command not from normal.

19
00:01:11,490 --> 00:01:11,960
All right.

20
00:01:12,210 --> 00:01:13,140
So how do we do that?

21
00:01:13,170 --> 00:01:19,280
Well, we can install it in our terminal or we can do it in the integrated terminal.

22
00:01:19,470 --> 00:01:22,020
It doesn't really matter when it comes to global packages.

23
00:01:22,030 --> 00:01:24,340
You can install it from anywhere.

24
00:01:24,540 --> 00:01:29,010
So in my case, I'm just going to navigate back to my terminal just so you don't think that I'm cheating

25
00:01:29,460 --> 00:01:32,040
and I'll zoom in and simply run.

26
00:01:32,790 --> 00:01:39,510
By the way, I need to start with pseudo and then npm install and half and G and of course, we're looking

27
00:01:39,510 --> 00:01:40,570
for an old man.

28
00:01:40,920 --> 00:01:49,320
So now of course, I'm prompted to enter my password and once I enter my passport, of course I'm going

29
00:01:49,320 --> 00:01:51,450
to install node one globally.

30
00:01:51,750 --> 00:02:01,280
And now in any of my projects I can simply go with command of Nortman and then whatever is the filename

31
00:02:01,500 --> 00:02:04,500
now to show you some of the use cases.

32
00:02:04,840 --> 00:02:11,910
If you work with Gadsby, you know that they have the global Gadsby Sellitto and that was one of the

33
00:02:11,910 --> 00:02:18,210
reasons why you installed something globally is because when we used one of the frameworks, for example,

34
00:02:18,210 --> 00:02:25,290
react or Gadsby in this case, and then of course, in order to set up the Gadsby project or Riak project,

35
00:02:25,410 --> 00:02:27,150
you needed to install this globally.

36
00:02:27,390 --> 00:02:30,780
Now, things have changed, though, with arrival off.

37
00:02:30,920 --> 00:02:34,460
And I'll talk about the Ampex at the end of the video.

38
00:02:34,860 --> 00:02:43,110
But notice, if you navigate your react box and if you look for create react app, which again was something

39
00:02:43,110 --> 00:02:45,570
that you needed to install globally.

40
00:02:45,900 --> 00:02:52,800
Now they suggest this Ampex road where essentially you go with an X and then again, whatever is the

41
00:02:52,800 --> 00:02:59,130
command name, for example, for create react app that would be create react app for satrapy.

42
00:02:59,310 --> 00:03:02,820
The Headless seems that would be create satrapy app.

43
00:03:02,820 --> 00:03:07,560
And hopefully you get the gist where for every resource that of course would be different.

44
00:03:07,920 --> 00:03:12,570
And with that command you don't have to install that tool globally.

45
00:03:13,230 --> 00:03:15,720
For example, again, in our case we're installing Gnomon.

46
00:03:15,730 --> 00:03:22,950
But normally prior to Ampex you would install this create react app globally and then you can spin up

47
00:03:23,160 --> 00:03:24,640
those Ariake projects.

48
00:03:24,930 --> 00:03:28,460
Now, I'm going to go back to my now, as you can see, I was successful.

49
00:03:28,740 --> 00:03:35,850
So what's going to happen if I go back to my project and if I run a node on an app just since I have

50
00:03:35,850 --> 00:03:43,560
installed that package globally, whereas I open up my app and if you don't believe me, I can change

51
00:03:43,560 --> 00:03:44,880
it back to whole world.

52
00:03:45,240 --> 00:03:47,080
And I have no issues.

53
00:03:47,100 --> 00:03:48,090
Hello world.

54
00:03:48,330 --> 00:03:49,470
And there it is now.

55
00:03:49,470 --> 00:03:52,800
Of course I have hello world in the console.

56
00:03:53,160 --> 00:03:57,750
So hopefully it is clear that yes, we can install packages globally.

57
00:03:58,020 --> 00:04:04,080
And yes, one of the biggest use cases was working with some type of front end library.

58
00:04:04,530 --> 00:04:12,900
But with an arrival of Ampex, things have shifted where now those libraries suggest using the Ampex

59
00:04:12,900 --> 00:04:14,160
route instead.

60
00:04:14,530 --> 00:04:16,110
As far as my personal preference.

61
00:04:17,029 --> 00:04:23,510
Since I'm recording a lot of courses and then some of the global packages usually introduce some kind

62
00:04:23,510 --> 00:04:29,930
of bugs to the students now, not for all the students, but there's always this one student who just

63
00:04:29,930 --> 00:04:32,940
has a lot of issues with the global package.

64
00:04:33,380 --> 00:04:36,320
Personally, I avoid them as much as possible.

65
00:04:36,320 --> 00:04:41,640
So I always either use the NPCs or I just set it up as a local dependency.

66
00:04:41,790 --> 00:04:43,160
Again, it's not a rule.

67
00:04:43,340 --> 00:04:45,110
You can do whatever you want.

68
00:04:45,110 --> 00:04:52,430
But I'm just telling you, what is my preferred option as far as what aspects it stands for execute

69
00:04:52,730 --> 00:04:55,960
an official name is the package runner.

70
00:04:56,360 --> 00:05:01,730
It is a feature that was introduced in AMPM five point two.

71
00:05:02,210 --> 00:05:08,780
And again, the main idea is following where you can run that Seelie tool, for example, in this case,

72
00:05:08,990 --> 00:05:13,220
create a react app without installing these globally.

73
00:05:13,490 --> 00:05:19,700
So as long as you have NPM with a version of five point two or greater, instead of doing this whole

74
00:05:19,700 --> 00:05:23,930
spiel of setting up the Sellitto globally, you just go with it.

75
00:05:24,570 --> 00:05:29,690
And then whatever years the total name and of course the last one is the folder name.

