File tree Expand file tree Collapse file tree 2 files changed +13
-3
lines changed Expand file tree Collapse file tree 2 files changed +13
-3
lines changed Original file line number Diff line number Diff line change 4
4
<!-- @doxie.inject start toc -->
5
5
<!-- Don’t remove or change the comment above – that can break automatic updates. -->
6
6
* [ Overwrite pull] ( https://github.com/git-tips/tips#overwrite-pull )
7
- * [ List of all the files changed in a commit] ( https://github.com/git-tips/tips#list-of-all-the-files-changed-in-a-commit )
7
+ * [ List of all files changed in a commit] ( https://github.com/git-tips/tips#list-of-all-files-changed-in-a-commit )
8
+ * [ List of all files till a commit] ( https://github.com/git-tips/tips#list-of-all-files-till-a-commit )
8
9
* [ Git reset first commit] ( https://github.com/git-tips/tips#git-reset-first-commit )
9
10
* [ List all the conflicted files] ( https://github.com/git-tips/tips#list-all-the-conflicted-files )
10
11
* [ List all branches that are already merged into master] ( https://github.com/git-tips/tips#list-all-branches-that-are-already-merged-into-master )
35
36
git fetch --all && git reset --hard origin/master
36
37
```
37
38
38
- ## List of all the files changed in a commit
39
+ ## List of all files changed in a commit
40
+ ``` sh
41
+ git diff-tree --no-commit-id --name-only -r < commit-ish>
42
+ ```
43
+
44
+ ## List of all files till a commit
39
45
``` sh
40
46
git ls-tree --name-only -r < commit-ish>
41
47
```
Original file line number Diff line number Diff line change 4
4
"tip" : " git fetch --all && git reset --hard origin/master"
5
5
},
6
6
{
7
- "title" : " List of all the files changed in a commit" ,
7
+ "title" : " List of all files changed in a commit" ,
8
+ "tip" : " git diff-tree --no-commit-id --name-only -r <commit-ish>"
9
+ },
10
+ {
11
+ "title" : " List of all files till a commit" ,
8
12
"tip" : " git ls-tree --name-only -r <commit-ish>"
9
13
},
10
14
{
You can’t perform that action at this time.
0 commit comments