Closed OptimumDev closed 2 years ago
Hi! This is a bug in RecentCommitTokenProvider
I'm re-implementing the handling of recent tokens, so you can expect this issue to be solved in the next release, next week!
Also, I'm planning on adding new providers for GitHub/Jira issue trackers. I'm still trying to define how to deliver them. I'd like to have the core plugin (this one) always open-source, while the additional providers as another "product".
Wow, great news, thanks!
Wow, great news, thanks!
You can see an example for GitHub here. The concept is the same for any other issue trackers. https://github.com/lppedd/idea-conventional-commit-github/issues/1#issue-715540797
Quick update relating to this issue, and #73.
I've cleaned up the exposed API, along with simplifying the handling of completion tokens. So it will be one big commit. Probably the update will be ready by the end of the week.
Futher update.
What I'm doing now is re-evaluating the PSI layer. Basically this is the what happens when you invoke completion:
CommitTokenProvider
is calledLookupElement
is createdLookupElement
, an associated FakePsiElement
is created, which contains the original CommitToken
from step 1FakePsiElement
is used to provide the CommitToken
to the DocumentationProvider
Now, this makes sense up to a certain point. ConventionalCommit isn't a language yet, so it doesn't need to have a PSI layer. What I'm trying to do instead is:
CommitTokenProvider
is calledLookupElement
is created, which contains the original CommitToken
from step 1DocumentationProvider
is called, the LookupElement
is asked for the CommitToken
, and a FakePsiElement
is created on-the-fly.Less code, better distribution of responsibilities.
New settings' option "Prioritize recently used tokens".
Now the token's documentation is always displayed.
For me after updating to 0.21.0, recently used tokens in autocompletion still don't preserve their case. Could it be that this bug is still there?
@Humorloos hi! If I may ask, could you post a couple screenshot to show the issue? It's purely to understand better which tokens you're using.
@lppedd Hi! Thanks for fast reply! Of course, here is a screenshot of my git log (see last commit message where I used scope "runConfigurations"):
And here is a screenshot of my commit window, where I want to use this scope again and conventional commit autocompletes with all lowercase:
@Humorloos yep, there was still the issue with the VCS provider. See commit 3a334d20f693664d624f964fc19f04ce77cea607
Hi! Great plugin, I love it)
I'm experimenting on what to use in scope field and currently using either couple of words (written in camel case) describing task's subject (for example "EntityFramework" or "MissedCalls") or JIRA's task number (capital letters + numbers, for example "ABS-123" or "CORS-2284"). But when I's trying to use autocompletion for scope, everything there is in lowercase.
Is it possible to preserve case there?