mirror of
https://github.com/sst/opencode.git
synced 2025-07-08 00:25:00 +00:00
fix(tui): slower startup due to file.status
This commit is contained in:
parent
163e23a68b
commit
891ed6ebc0
1 changed files with 5 additions and 5 deletions
|
@ -16,12 +16,11 @@ import (
|
||||||
|
|
||||||
type filesAndFoldersContextGroup struct {
|
type filesAndFoldersContextGroup struct {
|
||||||
app *app.App
|
app *app.App
|
||||||
prefix string
|
|
||||||
gitFiles []dialog.CompletionItemI
|
gitFiles []dialog.CompletionItemI
|
||||||
}
|
}
|
||||||
|
|
||||||
func (cg *filesAndFoldersContextGroup) GetId() string {
|
func (cg *filesAndFoldersContextGroup) GetId() string {
|
||||||
return cg.prefix
|
return "files"
|
||||||
}
|
}
|
||||||
|
|
||||||
func (cg *filesAndFoldersContextGroup) GetEmptyMessage() string {
|
func (cg *filesAndFoldersContextGroup) GetEmptyMessage() string {
|
||||||
|
@ -107,9 +106,10 @@ func (cg *filesAndFoldersContextGroup) GetChildEntries(
|
||||||
|
|
||||||
func NewFileAndFolderContextGroup(app *app.App) dialog.CompletionProvider {
|
func NewFileAndFolderContextGroup(app *app.App) dialog.CompletionProvider {
|
||||||
cg := &filesAndFoldersContextGroup{
|
cg := &filesAndFoldersContextGroup{
|
||||||
app: app,
|
app: app,
|
||||||
prefix: "file",
|
|
||||||
}
|
}
|
||||||
cg.gitFiles = cg.getGitFiles()
|
go func() {
|
||||||
|
cg.gitFiles = cg.getGitFiles()
|
||||||
|
}()
|
||||||
return cg
|
return cg
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue