Git Commands

+1 vote

What does this command exactly do? - 

git commit -a -m "message"
Apr 26, 2018 in Git & GitHub by Atul
• 10,240 points
59 views

2 answers to this question.

0 votes
Best answer

This command basically adds all your changes and commits it to your github repo with a commit message. 

You can also do the same in two separate steps(which is preferable)

$git add .
$git commit -m "message"
answered Aug 14, 2018 by Kalgi
• 40,420 points
–1 vote

To answer this question the best way possible you need to understand two concepts -Indexing & Committing.

Indexing: After you have created a new file or made changes to it, you need to move it from the working directory to the index.

For that, we use git add <file name>

Or, git add -A (-A means add all files that are in the working directory)

Committing: After you have added them to the index, it is ready to get committed.

For that, we use git commit -m “message”

Or, git commit -a -m “message” (-a means add all modified files in the index)

answered Apr 26, 2018 by DragonLord999
• 8,380 points

Related Questions In Git & GitHub

0 votes
1 answer
0 votes
1 answer

Git origin not found

For this to work, you need to ...READ MORE

answered Apr 25, 2018 in Git & GitHub by DragonLord999
• 8,380 points
143 views
0 votes
1 answer

Configure Git and GitHub

In version control with Git, we deal ...READ MORE

answered Apr 26, 2018 in Git & GitHub by DragonLord999
• 8,380 points
30 views
0 votes
1 answer

Git pull vs Git Fetch

The objective of both these commands is ...READ MORE

answered Apr 26, 2018 in Git & GitHub by DragonLord999
• 8,380 points
246 views
+13 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,380 points
145 views
0 votes
1 answer
0 votes
2 answers

difference between git remote and git clone

git remote add just creates an entry in ...READ MORE

answered Aug 7, 2018 in Git & GitHub by Kalgi
• 40,420 points
618 views
+1 vote
4 answers

GIT plugin in jenkins not able to connect to GIT repository

This looks like a git configuration issue, ...READ MORE

answered Oct 25, 2018 in Git & GitHub by Alia
1,544 views