Adding Git and NPM Start

Dear Sciaku Learner you are not logged in or not enrolled in this course.

Please Click on login or enroll now button.

If you have any query feel free to chat us!

Happy Coding! Happy Learning!

Lecture 284:- Adding Git and NPM Start

To add Git to your project, follow these steps:

  1. Open a terminal or command prompt and navigate to the root directory of your project.
  2. Initialize a new Git repository by running the command git init.
  3. Create a new file called .gitignore in the root directory of your project. This file should contain a list of files and directories that you want Git to ignore. For example, you can add the following lines to ignore the node_modules directory:

Copy code

node_modules/

  1. Add all files in your project to the Git repository by running the command git add ..
  2. Commit the changes by running the command git commit -m "Initial commit".

To add an npm start script to your package.json file, follow these steps:

  1. Open your package.json file.
  2. Find the scripts section and add a new line with the following code:

jsonCopy code

"start": "node app.js"

Replace app.js with the name of your main server file if it is different.

  1. Save the package.json file. You can now start your server by running the command npm start in your terminal or command prompt.
32. Beginning The Major Project 1

Comments: 2

profile
@niteshguptav63
17-Nov-2024, 01:39 PM

I am not able to access videos from second class and further. I have already completed first class

profile
@niteshguptav63
16-Nov-2024, 10:56 AM

When will I get my course?

profile
@admin79
17-Nov-2024, 01:29 PM

Now, Your query was resolved.

Frequently Asked Questions (FAQs)

How do I register on Sciaku.com?
How can I enroll in a course on Sciaku.com?
Are there free courses available on Sciaku.com?
How do I purchase a paid course on Sciaku.com?
What payment methods are accepted on Sciaku.com?
How will I access the course content after purchasing a course?
How long do I have access to a purchased course on Sciaku.com?
How do I contact the admin for assistance or support?
Can I get a refund for a course I've purchased?
How does the admin grant access to a course after payment?