Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion lang/rust/repo.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,15 @@ next:
}

func GetDefaultLSP() (lang uniast.Language, name string) {
return uniast.Rust, "rust-analyzer"
if _, err := exec.LookPath("rust-analyzer"); err == nil {
return uniast.Rust, "rust-analyzer"
}
name, err := InstallLanguageServer()
if err != nil {
log.Error("Failed to install rust-analyzer: %v\n", err)
os.Exit(1)
}
return uniast.Rust, name
}

func GetLastCommitTime(repo string) time.Time {
Expand Down
2 changes: 1 addition & 1 deletion version.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@
package main

const (
Version = "0.2.0"
Version = "0.2.1"
)
Loading