Selaa lähdekoodia

git-show: add example for showing file contents (#3600)

Waldir Pimenta 5 vuotta sitten
vanhempi
commit
c5a8569ece
1 muutettua tiedostoa jossa 4 lisäystä ja 0 poistoa
  1. 4 0
      pages/common/git-show.md

+ 4 - 0
pages/common/git-show.md

@@ -22,3 +22,7 @@
 - Show a commit's hash and message in a single line, suppressing the diff output:
 
 `git show --oneline -s {{commit}}`
+
+- Show the contents of a file as it was at a given revision (e.g. branch, tag or commit):
+
+`git show {{revision}}:{{path/to/file}}`