Lock menu option not appearing in TortoiseGit->LFS menu - locking

I'm using the following version of TortoiseGit for Windows:
TortoiseGit 2.12.0.0
git version 2.34.1.windows.1
I have included a .gitattributes file in the folder with the following info:
. filter=lfs diff=lfs merge=lfs -text lockable
The context menu for TortoiseGit contains the menu option for LFS but that menu only contains the option "Show locked files" - it does not have a menu option for "Lock" though the TortoiseGit documentation states:
In order to edit a lockable file you need to lock it using context menu via TortoiseGit → LFS → Lock.
Can someone please help with this?
Thanks.

As far as I can tell the context menu entry TortoiseGit → LFS → Lock appears only when you right-click a file.
The context menu entry TortoiseGit → LFS → Show locked files appears only when you right-click a folder.
Found in TortoiseGit 2.13.0.1

Related

IntelliJ - cannot commit file

In IntelliJ, I cannot commit file (right click -> Subversion -> Commit File), the option is grayed out; however - it is possible to Update File.
As a workaround, I am able to commit the file through TortoiseSVN:
Could you help me to find out why is this happening?
I tried to configure project Settings -> Version Control:
And also, according to: Intellij Annotate Option Grayed Out
I tried to uncheck 'Use non-modal commit interface' but it didn't work.
It's not the best, but I found a solution to this problem, if I find anything else, I will definitely update.
From 'Version control -> Directory Mappings' I had to remove the Git repository, and leave only Subversion, then 'Commit File' works, but I can't in turn do anything (e.g. change branch) on the Git project (which is logical).
Then I cleared VCS log caches and indexes.
After that I re-added the Git project to 'Dependency Mappings'.
The problem is, I can't clear VCS log caches and indexes now, because 'Commit File' will stop working again (so again I'd have to remove Git, clear VCS, and add Git after that).
I'm guessing IntelliJ doesn't know which repository this 'Commit File' is for, so this option is greyed out. However, all options are now available.

How to get rid of 'Unversioned Files' in Intellij

Is it possible to hide/get rid of 'Unversioned Files' in a default view of 'Local Changes'?
I found 'Show unversioned files' checkbox in Settings -> Version Control -> Commit but there is no difference.
You should add files to the .gitignore file you don't want to add them to the git history.
IntelliJ provides a context action for it

Can't find Git local changes in Intellij Idea 2020.1

I can't seem to find my local changes in Intellij Idea's latest version (2020.1), as you can see in the image below. What am I missing here? The "Git" tab only shows the Git log.
To see the Local Changes tab you just need to uncheck the option "Use non-modal commit interface"
Local changes can be found under "Commit" tab.
Please read more on new features:
https://www.jetbrains.com/idea/whatsnew/2020-1/#version-control
The alternative solution is: just a global search for Local Changes on IntelliJ Idea.
to bring the editor back to a close version of the previous (better) layout
view -> tool windows -> commit
on the git window that appears click the gear / settings icon
move to -> bottom left.

Intellij Annotate Option Grayed Out

I am trying to look at who changed a line in Intellij 15. I know I can use git blame but I want to learn how to do it correctly in intellij. I am right clicking on the line numbers on the file but when I get the context menu the annotate option is grayed out. What setting am I missing?
I looked at this page and couldn't find an answer. What am I missing?
If you check File > Settings > Version Control and see that your current project is listed under "Unregistered Roots", go to (on the menubar) VCS > Enable Version Control Integration. It will ask you to select the VCS tool you use, then click ok and you'll have all the integrations working (including the annotate feature which uses git blame).
The answer by #activedecay let me in the right direction. In my case, I have a multi-module project - each has a separate git repo - but we're all in the same workspace.
In my case, Intellij IDEA 2017.2, the Preferences -> Version Control (update from 2022: or Preferences > Version Control > Directory Mappings) panel shows a listing of all the project roots. The module with the disabled "Annotate" option was in the "Unregistered Roots" section.
To fix the problem, I selected the module and pressed the "+" icon in the lower toolbar to register the module root with Intellij VCS. The change is immediate and the "Annotate" options becomes available.
Looks like its a fresh project. First configure the Version Control like Git and than commit at least once. After first commit Annotate option will not be grayed out.
Also update git for any new version.
Your VCS is not enabled, hence the issue. Below is the solution for that:
Click on the VCS option in the menu bar
Enable VCS
Select your version control
Done, you should be able to use the annotate option.
Make sure the file is tracked by version control
Add the project to "Version Control" settings
I had the same issue with the Annotate being greyed out however VCS was already set up. Editing the current VCS Directory Mapping fixed the issue for me.
Go to
Settings -> Version Control
Click on the current entry for your
your application listed under projects.
Click the pen icon to edit it
Hit Ok, then ok to close the main dialog
Under the version control setting, make sure to remove any unregistered roots, I had a similar issue where there was a Unregistered roots entry was found, after removing this unwanted entry, I was able to annotate on file.
I the following two screen short will solve your problem:
1.
I hope after those steps you will be able to see who changed a line.
Here are the steps i followed :
Go to VCS -> Checkout from Version Control -> Git -> give the URL for your repository.
The annotate option will be enabled now.
I had exactly the same issue and managed to solve it by updating git.
The reason for that is that I have recent InteliJ Idea and an old 2.1.x git installed.
For Mac:
brew upgrade git
brew link git
followed by IDE restart.
Perhaps you did not check Git Integration while setting up a fresh installation of IntelliJ. It happened to me when I updated to a major release. When I was setting up the new program, I might have unchecked the Git Integration on the wizard installation.
In order to solve this for IntelliJ Community 2019.1, access File > Settings > Plugins, go to the tab Installed and make sure the plugin Git Integration is checked. You should restart the IDE in order to make the Annotate action work.
I had the same issue, but my VCS settings were all configured properly. It turns out that git itself was considering the file as a brand new file and therefore didn't have any history for it. The file was actually not new, but simply renamed. While my rename changes were unstaged, git understood it as two separate files: a deletion of the old file and creation of a new file. However, once I git added the "deleted" file and the "new" file, git understood that it was actually a rename and IntelliJ was able to annotate on the file as expected.
I'm not sure why git didn't understand the rename when it was unstaged, but hopefully this helps someone!

How to highlight the edited file using git in intellij?

Eclipse will highlight the files that I have made changes in git repository, but looks like intellij don't highlight that. Is there any preference that I can configure ?
Go to Settings -> Version Control then edit your project for setting git root. After that IDEA will show all changes in your files.