home: zed and lazygit config
This commit is contained in:
@@ -123,6 +123,12 @@ in
|
||||
buffer_font_size = 16;
|
||||
ui_font_size = 17;
|
||||
relative_line_numbers = true;
|
||||
file_types = {
|
||||
JSONC = [
|
||||
"tsconfig.json"
|
||||
"tsconfig.*.json"
|
||||
];
|
||||
};
|
||||
};
|
||||
userKeymaps = [
|
||||
{
|
||||
@@ -176,10 +182,20 @@ in
|
||||
}
|
||||
];
|
||||
|
||||
userTasks = with pkgs; [
|
||||
userTasks = [
|
||||
{
|
||||
label = "lazygit";
|
||||
command = "${lib.getExe lazygit} -p $ZED_WORKTREE_ROOT";
|
||||
command = lib.getExe config.programs.lazygit.package;
|
||||
env = {
|
||||
EDITOR = lib.getExe cfg.package;
|
||||
};
|
||||
args = [
|
||||
"-p"
|
||||
"$ZED_WORKTREE_ROOT"
|
||||
];
|
||||
reveal = "always";
|
||||
allow_concurrent_runs = true;
|
||||
use_new_terminal = false;
|
||||
hide = "on_success";
|
||||
}
|
||||
];
|
||||
@@ -188,7 +204,7 @@ in
|
||||
xdg.configFile."zed/tasks.json".text = builtins.toJSON cfg.userTasks;
|
||||
|
||||
home.sessionVariables = lib.mkIf cfg.defaultEditor {
|
||||
EDITOR = lib.getExe pkgs.zed-editor;
|
||||
EDITOR = lib.getExe cfg.package;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user