VSCode: Git changes not highlighted with badges or gutter indicators - visual-studio-code

Changed lines were not highlighted with gutter indicators near the line number (e.g., orange and green) as normal. The changed/new file was not labeld with a "M" or "U" badge in the file tree (Explorer). The file was displayed as a modified file in the source contral panel though.
Old repositories do not have this issue, but newly cloned repos have this issue.
This issue is the same as the one reported in this Github issue, but the solution there did not work for me.

Related

Github Code displaying wrong indentation issue

I realized that when I push my code to my GitHub repo, the indentation is being displayed as 8..? but In my VSCODE, I have set my indentation as 2.
Is there a permanent fix to this issue? I am aware that I can go into my code and press the pen icon and view my code in 2 spaces, 4 spaces or 8 spaces using the options but this doesn't change my code being displayed in 2 spaces permanently.
Below is the image comparison
Double-check first your GitHub account settings "Tab Size Preference" (new since Sept. 2021)
Those should apply to all of your repositories.

Inconsistent Tab Size in GitHub PR UI

Recently, I made a PR to a newly started open source repo in GitHub, where a collaborator pointed out that the tab size I used for tabs does not match the other PRs in that repo. I was confused because I preserved the orginal indentation as it'd been and furthermore, the indent style was not spaces but tabs.
Because the Files changed tab in my PR really had its data-tab-size attribute set to 8, while 3 other PRs had its data-tab-size set to 4, I thought there must be some reason behind it; I searched online and found that .editorconfig of the repo is responsible for the shown tab size; however, I did not modify that file; moreover, the files in my PR and the other PRs were of the same file type(markdown), in the same directory, and using tabs for the indentation for the code blocks.
I wonder what causes the peculiar inconsistency in the tab size in the PR UI.

How to find the workspace where the file is checked out in P4v

I have a file checked out. So, when I tried to check out the file, it says "the file is checked out by another user and cannot checkout multiple versions of it". I tried seeing the "checked out by" tab in P4V and it shows my P4V id.
But the file is not shown in any of pending lists in any of the work spaces I have.
I need to find the workspace where the file is checked out so that I can revert it.
You can hover your mouse over the item showing the blue checkmark in P4V, and it will show you who has it checked out and in what workspace. In this image, the workspace name is in the red box (but I've blurred it because the name is unimportant).

detect white space difference between two files

We are using git. I am using eclipse. Some of the committers may not be using eclipse. Here's what is happening.
I make a small change in an existing file (properties/xml/java) and save it and commit it.
gitk (without ignore space change) and eclipse thinks the whole file changed. The commit shows ## -1,354 +1,354 ## which means the entire file changed.
When I check for code change difference, with ignore white space, then I can see the text difference. But I don't know what white space change is causing this.
How do I detect what white space difference is there between two files? It could be new line character, carriage return, tab, or something else.
This is how eclipse compare editor works. Unlike other file compare tools(kdiff3 or winmerge or Beyond compare) it shows entire file instead of showing only the difference.
But you can jump to individual changes by clicking on the change book markers as highlighted below.
You can integrate other compare tools(Ex: Beyond compare, winmerge) in eclipse.
Refer these links
Beyond Compare with git
Winmerge with git
Edit:
White space changes are shown in GREY background color

Any Eclipse plugin to show Mercurial diff of file in editor?

Plugins like vim-signify for Vim show the diff status of the file being edited, if the file belongs to a Mercurial or Git repository. It displays this information by showing indicators for the lines which have changed since last commit, along the left gutter of the editor window.
Is there any similar plugin for Eclipse which works with Mercurial? That is, while editing a file which belongs to a Mercurial repository, the lines which have changed are highlighted or indicated by some means.
The one and only one worth it :) : https://bitbucket.org/mercurialeclipse/main/wiki/Home