feat: add support for absolute paths to LSP and formatter binaries
Also, refactor binary resolving functions into the bin_path module. closes #474
This commit is contained in:
parent
d24f335465
commit
4847a1f584
4 changed files with 26 additions and 18 deletions
|
|
@ -1137,9 +1137,7 @@ pub fn get_theme_file_name(theme_name: []const u8) ![]const u8 {
|
|||
}
|
||||
|
||||
fn resolve_executable(executable: [:0]const u8) [:0]const u8 {
|
||||
return for (executable) |char| {
|
||||
if (std.fs.path.isSep(char)) break executable;
|
||||
} else bin_path.find_binary_in_path(std.heap.c_allocator, executable) catch executable orelse executable;
|
||||
return bin_path.resolve_executable(std.heap.c_allocator, executable);
|
||||
}
|
||||
|
||||
fn restart() noreturn {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue