Git commands to check diff locally and commit to repository

Diff

To see complete changes: git diff

To see just changed files: git diff –name-only

Commit and push:

git add <changed file>

git commit -m “comment” <changed file>

git push origin master

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s