I can execute various Git commands from Visual Studio Code, however I couldn't find a way to visualize the history.
-
strangely, it hides in the Explorer tab under Timeline, rather than in the Git tab... :-) – user3043860 May 02 '21 at 10:06
9 Answers
I recommend you this repository, https://github.com/DonJayamanne/gitHistoryVSCode
Git History
It does exactly what you need and has these features:
- View the details of a commit, such as author name, email, date, committer name, email, date and comments.
- View a previous copy of the file or compare it against the local workspace version or a previous version.
- View the changes to the active line in the editor (Git Blame).
- Configure the information displayed in the list
- Use keyboard shortcuts to view history of a file or line
- View the Git log (along with details of a commit, such as author name, email, comments and file changes).
![](../../users/profiles/63550.webp)
- 28,342
- 21
- 95
- 123
![](../../users/profiles/5960454.webp)
- 2,047
- 1
- 8
- 5
-
18
-
7Git History for VS Code in marketplace https://marketplace.visualstudio.com/items?itemName=donjayamanne.githistory – naXa Jul 03 '18 at 23:22
-
-
1Does this show the history only after you've installed it? Or would you be able to see commands executed before installing it as well (perhaps VS Code stores it somewhere inaccessible)? – Magne Aug 06 '18 at 07:49
-
1No, I installed it and cannot see the previous history. It shows the history only after its installed – Sathwik Gangisetty Jan 29 '19 at 14:50
-
3I was using GitLens but found it extremely overwhelming. The interface has just too many options. This, on the other hand, is quite straightforward. Liking it so far. – Marc.2377 Oct 24 '19 at 06:01
GitLens has a nice Git history browser. Install GitLens from the extensions marketplace, and then run "Show GitLens Explorer" from the command palette.
![](../../users/profiles/63550.webp)
- 28,342
- 21
- 95
- 123
![](../../users/profiles/958118.webp)
- 5,326
- 2
- 26
- 29
-
The latest version of GitLens is really good. It adds a handy sidebar button and allows you to much better visualize changes across multiple branches. – cham Oct 29 '18 at 21:10
-
yes, i used that, and i highly recommended that extension because it can show in realtime when i click on some link , ref: https://academy.byidmore.com/post/Find-Out-Who-Working-on-This-Line-Via-GitLens-5bd710931bde484c8fbedd33 – yussan Oct 30 '18 at 02:58
-
@JosephSheedy, `GitLens` seams most popular (downloads) extension for reason. – prosti Jun 12 '19 at 06:42
-
Good plugin. Did too much overlaying for me. stackoverflow.com/a/60013101/229906 built in vscode was exactly what I was looking for. – 0llie Sep 22 '20 at 08:36
You won't need a plugin to see commit history with Visual Studio Code 1.42 or more.
Timeline view
In this milestone, we've made progress on the new Timeline view, and have an early preview to share.
This is a unified view for visualizing time-series events (e.g. commits, saves, test runs, etc.) for a resource (file, folder, etc.).
To enable the Timeline view, you must be using
the Insiders Edition(VSCode 1.44 March 2020) and then add the following setting:
"timeline.showView": true
![](../../users/profiles/6309.webp)
- 1,042,979
- 435
- 3,649
- 4,283
-
3
-
@Vimes No, for now it is a time-series events (here, Git commits) for a resource (file, folder). – VonC Mar 10 '20 at 16:59
-
@VonC is there a way in timeline to bring up diff details for then entire commit that the timeline view is showing for a specific file? Is there a way to render "git show
" view in vsc vs command line vi editor experience? – myusrn Aug 24 '20 at 18:50 -
-
@VonC okay thanks for clarification. While the [git history](https://marketplace.visualstudio.com/items?itemName=donjayamanne.githistory) extension mentioned earlier in this thread does provide a way to use ide for view and diff contents of all aspects of a commit in the history log i assumed an oob story would exist for this given timeline is sort of doing this already but at a file scope level. As suggested i created a new SO question for just that issue [here](https://stackoverflow.com/questions/63586751/does-visual-studio-code-have-ide-story-for-reviewing-git-commit-history-and-doin). – myusrn Aug 25 '20 at 20:40
-
This view is available in VS Code 1.44 (March 2020). It's not limited to insiders edition anymore. – zgorawski Oct 13 '20 at 07:29
-
-
It does not seem to show history for a folder, only for a single specific file. – PeteH32 Apr 09 '21 at 22:05
It is evident to me that GitLens is the most popular extension for Git history.
What I like the most it can provide you side annotations when some line has been changed the last time and by whom.
![](../../users/profiles/63550.webp)
- 28,342
- 21
- 95
- 123
![](../../users/profiles/5884955.webp)
- 27,149
- 7
- 127
- 118
Git Graph seems like a decent extension. After installing, you can open the graph view from the bottom status bar.
![](../../users/profiles/63550.webp)
- 28,342
- 21
- 95
- 123
![](../../users/profiles/20471.webp)
- 44,686
- 25
- 93
- 148
You will find the right icon to click, when you open a file or the welcome page, in the upper right corner.
And you can add a keyboard shortcut:
![](../../users/profiles/63550.webp)
- 28,342
- 21
- 95
- 123
![](../../users/profiles/6643833.webp)
- 1,512
- 10
- 18
-
17JIC: ... before to see this option, you need to have **Git History** extension previously installed. – Jhegs Nov 11 '18 at 23:31
-
1Can you update your answer with the prerequisites (after testing it is actually the case)? – Peter Mortensen May 03 '20 at 20:34
-
Thanks @Jhegs, somehow I forgot about reinstalling that extension and was looking for this feature everywhere in the settings ♂️ – neojp Feb 19 '21 at 12:58
If you need to know the Commit history only, So don't use much Meshed up and bulky plugins,
I will recommend you a Basic simple plugin like "Git Commits"
I use it too :
https://marketplace.visualstudio.com/items?itemName=exelord.git-commits
Enjoy
![](../../users/profiles/7189206.webp)
- 161
- 2
- 5