-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathashutosh.txt
More file actions
38 lines (28 loc) · 2.57 KB
/
Copy pathashutosh.txt
File metadata and controls
38 lines (28 loc) · 2.57 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
1. Difference between Git and GitHub-
Git and GitHub are related but distinct technologies.
Git is a version control system. It is a software tool that helps you manage the different versions of your code files and track changes. With Git, you can keep a
history of changes, revert to previous versions, and collaborate with other developers by sharing changes with one another.
GitHub, on the other hand, is a platform that provides hosting for Git repositories, as well as tools for bug tracking, project management, and collaboration.
It makes it easier for developers to store and share their code, as well as track issues, manage pull requests, and build software. In other words,
GitHub is a web-based platform that provides an interface for Git repositories and allows for easy collaboration and code sharing.
So, to summarize: Git is a version control system, and GitHub is a web-based platform that provides hosting for Git repositories and adds extra features
to help with collaboration and project management.
2.Here are five basic Git commands:
1. git init: This command is used to initialize a new Git repository. It creates a new directory with all the necessary Git files to track changes in your code.
2. git clone: This command is used to copy an existing Git repository from a remote source to your local machine. For example, you can use git clone
to download a repository from GitHub.
3. git add: This command is used to add files to the staging area, which is a temporary holding place for changes that you want to commit.
4. git commit: This command is used to save changes to the local Git repository. When you run git commit, Git creates a new "commit" with a message
that describes the changes you made.
5. git push: This command is used to upload your local Git repository to a remote repository, such as a server on GitHub. When you run git push,
your changes are sent to the remote repository and made available to other collaborators.
These five commands are just the beginning, and there are many more Git commands you can use to manage your code and collaborate with others.
3. A pull request is a way to propose changes to a project that is hosted on a remote repository, such as on GitHub. Here is a basic process
1. for making a pull request:
2. Fork the repository on GitHub.
3. Clone the forked repository to your local machine.
4. Create a new branch for your changes.
5. Make the changes to the code.
6. Commit and push the changes to the forked repository.
7. Open a pull request on the original repository.
8. Wait for the repository maintainers to review and accept your changes.