You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a Kotlin Compose project and all source files are always displayed like this on /add which is cumbersome to use.
This means, I always have to arrow through the candidates to find the matching one. Works, but not too great.
Roo Code, as a comparison, displays the file names like this (just the end) which is often far more useful:
Version and model info
Aider v0.78.0
Model: openrouter/deepseek/deepseek-chat:free with diff edit format, prompt cache, infinite output
Git repo: .git with 272 files
Repo-map: using 4096 tokens, auto refresh
Added memory-bank/techContext.md to the chat.
The text was updated successfully, but these errors were encountered:
Turns out that it is not that easy since that functionality is from the prompt_toolkit library. Locally, if I patch its menus.py with this function:
def_trim_formatted_text(
formatted_text: StyleAndTextTuples, max_width: int
) ->tuple[StyleAndTextTuples, int]:
""" Trim the text to `max_width`, prepend dots when the text is too long. Returns (text, width) tuple. """width=fragment_list_width(formatted_text)
# When the text is too wide, trim it.ifwidth>max_width:
result= [] # Text fragments.remaining_width=max_width-3# Reserve space for "..."fragments=list(explode_text_fragments(formatted_text))
# Start from the end and work backwardsforstyle_and_chinreversed(fragments):
ch_width=get_cwidth(style_and_ch[1])
ifch_width<=remaining_width:
result.insert(0, style_and_ch) # Insert at start to maintain orderremaining_width-=ch_widthelse:
breakresult.insert(0, ("", "...")) # Prepend the dotsreturnresult, max_width-remaining_widthelse:
returnformatted_text, width
I get this display, which is exactly what I like. One can also patch column width to be a bit nicer when the paths are so long (maybe maxing out at 2 columns), but this is good for the start.
Issue
I have a Kotlin Compose project and all source files are always displayed like this on
/add
which is cumbersome to use.This means, I always have to arrow through the candidates to find the matching one. Works, but not too great.
Roo Code, as a comparison, displays the file names like this (just the end) which is often far more useful:
Version and model info
Aider v0.78.0
Model: openrouter/deepseek/deepseek-chat:free with diff edit format, prompt cache, infinite output
Git repo: .git with 272 files
Repo-map: using 4096 tokens, auto refresh
Added memory-bank/techContext.md to the chat.
The text was updated successfully, but these errors were encountered: