how to read git show command output

dkjain

I am just getting into VC and in particular git. I am aware of basic commands like git add/commit/remote but having a hard time understanding the output:

$ git show f27d852

commit f27d852fc750a9c3f71eaf0acf586164b76faddf
Author: myusername <[email protected]>
Date:   Tue Jun 28 22:59:35 2016 +0530

    changed color to a different color

diff --git a/css/business-casual.css b/css/business-casual.css
index bbd44d7..ee1765e 100644
--- a/css/business-casual.css
+++ b/css/business-casual.css
@@ -194,5 +194,5 @@ footer p {
 /* CUSTOM CSS - BY ME */

 .brand {
-       color: #ff0000;
-       }
\ No newline at end of file
+       color: #ffdd000;
+       }

What does each line mean? How to read it. can anyone explain?

Thanks dk

ElpieKay
commit f27d852fc750a9c3f71eaf0acf586164b76faddf

The sha1 of the commit.

Author: myusername <[email protected]>

The author's name and email, which might be different from the committer's name and email.

Date:   Tue Jun 28 22:59:35 2016 +0530

The author date, which might be different from the committer date.

changed color to a different color

The commit log message. It could be one line, or the first part + empty line(s) + the other part. The only line or the first part before the empty line(s) is subject, and the other part after the empty line(s) is body.

diff --git a/css/business-casual.css b/css/business-casual.css

The two files that have been compared.

index bbd44d7..ee1765e 100644

bbd44d7 is the sha1 of the blob before the change and ee1765e the sha1 of the blob after the change. You could run git show <blob-sha1> or git cat-file -p <blob-sha1> to see the blob's content.

--- a/css/business-casual.css

The file before the change.

+++ b/css/business-casual.css

The file after the change.

    @@ -194,5 +194,5 @@ footer p {
 /* CUSTOM CSS - BY ME */

 .brand {
-       color: #ff0000;
-       }
\ No newline at end of file
+       color: #ffdd000;
+       }

194 is the diff start line and 5 is the context lines. footer p { indicates where the diff part locates. The lines without prefixing + or - are unchanged lines. If you add one line, it's a +. If you delete a line, it's a -. If you modify a line, it's a - and a +.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

how to read git show command output

From Dev

How do I run a command but show no output?

From Dev

How to show properly accents in git diff output

From Dev

How to format the output of git show in python

From Dev

How to make git output usage for any command?

From Dev

How to make git output usage for any command?

From Dev

How to prepend lines to git command output

From Dev

How to show only java files diffs with 'git show' command?

From Dev

Output of git pull command

From Dev

how to read output of a command run using cmd.exe

From Dev

How to read parts of a command output (after a certain character) into a bash variable?

From Dev

how to read multiline output command line by line, in a shell script?

From Dev

how to read ssh output from 'last' and 'who' command

From Dev

How to read parts of a command output (after a certain character) into a bash variable?

From Dev

how to read certain lines of a file that is the output of fc command with a batch script

From Dev

Message box show output of command

From Dev

How do I store output of a git command in a Perl array or scalar?

From Dev

How to run command on git log output per commit using bash

From Dev

How to make a git command read settings from .gitconfig file?

From Dev

Read output of shell command in meteor

From Dev

Command Prompt read system output

From Dev

Show expanded version of Git command

From Dev

redirecting git command output to another

From Dev

Color output of specific git command

From Dev

Why does git show ++ and -- in the output of `git show' on a stash?

From Dev

How to show a at scheduled command?

From Dev

How to read nm output?

From Dev

How to read the complete output?

From Dev

Show output before Read-Host

Related Related

  1. 1

    how to read git show command output

  2. 2

    How do I run a command but show no output?

  3. 3

    How to show properly accents in git diff output

  4. 4

    How to format the output of git show in python

  5. 5

    How to make git output usage for any command?

  6. 6

    How to make git output usage for any command?

  7. 7

    How to prepend lines to git command output

  8. 8

    How to show only java files diffs with 'git show' command?

  9. 9

    Output of git pull command

  10. 10

    how to read output of a command run using cmd.exe

  11. 11

    How to read parts of a command output (after a certain character) into a bash variable?

  12. 12

    how to read multiline output command line by line, in a shell script?

  13. 13

    how to read ssh output from 'last' and 'who' command

  14. 14

    How to read parts of a command output (after a certain character) into a bash variable?

  15. 15

    how to read certain lines of a file that is the output of fc command with a batch script

  16. 16

    Message box show output of command

  17. 17

    How do I store output of a git command in a Perl array or scalar?

  18. 18

    How to run command on git log output per commit using bash

  19. 19

    How to make a git command read settings from .gitconfig file?

  20. 20

    Read output of shell command in meteor

  21. 21

    Command Prompt read system output

  22. 22

    Show expanded version of Git command

  23. 23

    redirecting git command output to another

  24. 24

    Color output of specific git command

  25. 25

    Why does git show ++ and -- in the output of `git show' on a stash?

  26. 26

    How to show a at scheduled command?

  27. 27

    How to read nm output?

  28. 28

    How to read the complete output?

  29. 29

    Show output before Read-Host

HotTag

Archive