Zip file for Credit Card Checker project

OK I feel really dumb, but I am trying to do the credit card checker project on my own computer, but I cannot even open the file. It’s a JavaScript file. The directions said I would need Node to run it. I followed the directions and downloaded Visual Studio Code, Git Bash, and Node. I still cannot open the file! HELP

which is it?

if it’s text, send it to node, if it’s an archive, extract it

ehh. what. are you getting permission denied, or do you mean that you don’t know what to do with the content of the file?

I don’t know. It’s a compressed folder but it’s JavaScript. I get an error message when I try to open it. I just thought if someone else has done it that they would know. If I could show someone they would probably figure it out in 2 seconds but I have no one to ask

If you have a file with javascript in it, what does such a file look like?

It’ll be a text file encoded as utf-8, what most would refer to as plain text, maybe they’d save it with a .txt file extension to say so. If you tell your editor to open this, it shows you code.

You have a zip archive. What can you do with those? You’d unzip it yes? You’d need a program that offers to carry out such an operation, maybe your operating system offers to do it for you or otherwise use something like 7zip

Ok, I figured it out. I feel a little redeemed, because it was not straight forward. I’ll leave this here in case anyone else has a similar issue.

Per the directions on Codecademy, I downloaded Git Mash, VSC, and Node. However, there are several other steps to get NodeJs running in VSC, which Codecademy does not address. This video explains it very clearly: https://youtu.be/31dRWcPcvhM.

After you get NodeJs running in VSC, then you can open the project folder with all the code.

Well uhm… vsc is a text editor and javascript is text, no node is required to edit text, not having node running under vsc will not prevent you from editing it.
And, node doesn’t need to run from a text editor to run code, you can ask node directly to run code.

Maybe you mean that you were clicking on the text file in hopes that node would pick it up? Because that’s not going to work. It’s a text file. Not a binary executable. The thing you would need to click on is node, or maybe you’d open a terminal and run node with a path to your javascript as an argument so that node knows what to run.

A text editor does things like … letting you type letters and saving what you typed to a file.
Node lets you run javascript
Those are separate things!

I don’t understand why at all, but many people seemingly insist on having their editor and executing environment be contained within an app. All this is really doing is treating that app as the operating system, the operating system already does things like file management and process management… windows management.
Maybe that’s convenient, or maybe their operating system is inconvenient (why else would there be a need for that) but it at the very least isn’t required to edit and run javascript

the directions for the project literally say that you need Node.js to open their file. You keep responding even though it doesn’t seem like you know what I am talking about. Maybe you should look at the project before you put me down.

Node is the program that executes javascript.
If open means run the code, then yes you need node. You could also ask your browser to do it, your browser also has the ability to execute javascript.

If open means editing, then no, it’s just text, no node required. But it’s kind of pointless to edit code and then not run it.

Here’s me downloading, extracting, editing, running the project
https://asciinema.org/a/JfNvmZeQmrMRjV7HZ4t1jT2yp

I extract it with an archive manager.
I edit it with a text editor.
I run it with node.

All of them are opening a file, but more to the point, I’m asking them to do specific things, not “open”
The archive manager opens the zip file and writes out the contents into new files
The text editor opens main.js for editing, so it is both reading and writing the file
node reads the file, parses it and executes what the file says