Git diff
git diff shows the lines that changed. Lines starting with + were added, lines starting with - were removed.
Plain git diff shows changes you have not staged yet. git diff --staged shows what is staged for the next commit.
See unstaged changes
git diff
diff --git a/index.html b/index.html
index 36b9c86..8bd4318 100644
--- a/index.html
+++ b/index.html
@@ -8,3 +8,4 @@
<p>This is the first file in my new Git Repo.</p>
</body>
</html>
+<p>A new line in my file.</p>
See staged changes
After git add, plain git diff shows nothing, so use --staged:
git add index.html
git diff
git diff --staged
diff --git a/index.html b/index.html
index 36b9c86..8bd4318 100644
--- a/index.html
+++ b/index.html
...