Transpilation Project Problems


#1

I am having a bit of a problem with the short transpilation project.

This Lesson

After having entered “npm init” when I enter “npm install package-name -D” the terminal gets stuck at “fetchMetadata: . . .”

Please enlighten me.


#2

Were you really trying to install a package named “package-name”?


#3

That is what is said I thought, however if I am being stupendously dumb I would not be surprised…


#4

I was… OK its supposed to be package-babel something isn’t it


#5

When you write instructions (such as into a commandline) you have a whole lot of freedom in what you describe, and nothing will ever snap into place or be understood as what you meant, won’t in any way be corrected. It’ll do what you say. That’s great.

In contrast, buttons tend to have some form of pre-programmed sane behaviour. Bad for describing things, good for offering a small amount of correct options.

The point here - be very deliberate about what you write. There’s really no checking afterwards whether it’s right, that’s backwards. Decide what you want and figure out how to do it, make it so. Anything you’ve written is something you can argue for, and probably therefore also fix if you make a mistake.

…which also ends up involving a whole lot of manuals and other documentation. Google often has something to suggest for describing an action

As for what you’re doing that’s not something I’m familiar with. Mostly pointing out that it would be an incredibly cleverly named package and that you need to figure out commands in a way that would have let you notice that

But yeah. They say babel right, so your command would certainly need to mention that, exactly which package that would be is something to figure out by considering your intentions and whatever other information you have


#6

Thank you, I am actually very new to coding and just figuring it all out. I am learning it with codecademy so that I can use it for whatever I may need it for in the future. If I may ask you a rather foolish question: what exactly is the terminal shown in the lessons and what does it represent in “real life” so to speak, I mean if I were writing my own code for some project or other?


#7

The program printing out "$ " as its default prompt is bash.

It (or something equivalent), together with the programs usually also installed with it, are together an operating system, usually sitting on top of linux to deal with hardware. Most modern operating system’s other than windows use this (though a whole lot of them with an other kernel than linux, which isn’t an operating system, not by itself anyway)

You might think of it as an interface to a computer, from which you’d do everything else.


#8

This makes sense. Thanks again for your help. I shall put your advice into practice.


#9

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.