Add blank line before user role#1225
Merged
olimorris merged 1 commit intoolimorris:mainfrom Apr 30, 2025
Merged
Conversation
Owner
|
I notice that this causes a blank line to be inserted if there's only a user role in a chat buffer. If we can add a check for that this will be good to merge. |
Contributor
Author
|
Hi! Sorry for the late reply. Added a guard for your request (assuming I understood correctly) |
Contributor
Author
|
@olimorris I used a simple user role only prompt like the following to test this out: ['Test'] = {
strategy = 'chat',
description = 'Act as an test developer.',
opts = {
short_name = 'test_role',
is_slash_cmd = true,
auto_submit = false,
ignore_system_prompt = true,
},
prompts = {
{
role = 'user',
content = [[Foo]],
},
},
} |
Contributor
Author
|
Hi @olimorris. Sorry for the ping ,but do you want me to make further changes to this PR? |
Owner
|
Hey thanks for this. I'm fully tied up with another PR so will try and take a look in the week. There were a few additional scenarios I wanted to test. |
Contributor
Author
|
Makes sense. Thanks for the reply |
Owner
|
Thanks for this @petobens! Fixes a stupid UI annoyance really nicely. |
Contributor
Author
|
Thanks for an awesome plugin and kudos on the function tools work :) |
cleong14
pushed a commit
to cleong14/codecompanion.nvim
that referenced
this pull request
May 21, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This addresses my second comment #959 (comment) by adding a blank line between the system role content and the user role heading.