nixosConfigurations.common: adapt nurofi
This commit is contained in:
parent
68e77c57bf
commit
bf93f6fdf4
1
nixosConfigurations/common/hm/nu/asd.nu
Normal file
1
nixosConfigurations/common/hm/nu/asd.nu
Normal file
@ -0,0 +1 @@
|
|||||||
|
print $env.FILE_PWD
|
1
nixosConfigurations/common/hm/nu/mod.nu
Normal file
1
nixosConfigurations/common/hm/nu/mod.nu
Normal file
@ -0,0 +1 @@
|
|||||||
|
export use nurofi;
|
@ -50,7 +50,7 @@ mainbox {
|
|||||||
imagebox {
|
imagebox {
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
background-image: url("assets/knight.gif", width);
|
background-image: url("~/.config/nushell/modules/nurofi/assets/knight.gif", width);
|
||||||
orientation: vertical;
|
orientation: vertical;
|
||||||
children: [ "inputbar", "dummy", "mode-switcher" ];
|
children: [ "inputbar", "dummy", "mode-switcher" ];
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
const base_directory = "~/.config/nushell/modules/nurofi";
|
||||||
|
|
||||||
def is-installed [ app: string ] {
|
def is-installed [ app: string ] {
|
||||||
((which $app | length) > 0)
|
((which $app | length) > 0)
|
||||||
@ -19,7 +20,7 @@ export def powermenu []: nothing -> nothing {
|
|||||||
let action = [lock suspend logout reboot shutdown];
|
let action = [lock suspend logout reboot shutdown];
|
||||||
mut selected = null;
|
mut selected = null;
|
||||||
|
|
||||||
$selected = $action | to text | rofi -dmenu -p (date now | format date "%Y-%m-%d %H:%M:%S") -mesg $"Uptime: ($uptime)" -theme powermenu.rasi;
|
$selected = $action | to text | rofi -dmenu -p (date now | format date "%Y-%m-%d %H:%M:%S") -mesg $"Uptime: ($uptime)" -theme ($base_directory | path join powermenu.rasi);
|
||||||
|
|
||||||
match $selected {
|
match $selected {
|
||||||
"lock" => { hyprlock --immediate; }
|
"lock" => { hyprlock --immediate; }
|
||||||
@ -32,5 +33,5 @@ export def powermenu []: nothing -> nothing {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export def apps []: nothing -> nothing {
|
export def apps []: nothing -> nothing {
|
||||||
rofi -show drun window -theme apps.rasi;
|
rofi -show drun window -theme ($base_directory | path join apps.rasi);
|
||||||
}
|
}
|
||||||
|
@ -44,7 +44,7 @@ mainbox {
|
|||||||
border-radius: 0px;
|
border-radius: 0px;
|
||||||
border-color: @selected;
|
border-color: @selected;
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
background-image: url("assets/solair.gif", width);
|
background-image: url("~/.config/nushell/modules/nurofi/assets/solair.gif", width);
|
||||||
children: [ "inputbar", "message", "listview", dummy ];
|
children: [ "inputbar", "message", "listview", dummy ];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -29,6 +29,10 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$env.NU_LIB_DIRS = ["${./nu}"];
|
||||||
|
|
||||||
|
# use nurofi;
|
||||||
'';
|
'';
|
||||||
|
|
||||||
environmentVariables = {
|
environmentVariables = {
|
||||||
@ -36,7 +40,6 @@
|
|||||||
SSH_AUTH_SOCK = "/run/user/1000/ssh-agent";
|
SSH_AUTH_SOCK = "/run/user/1000/ssh-agent";
|
||||||
EDITOR = "${lib.getExe' hmConfig.programs.helix.package "hx"}";
|
EDITOR = "${lib.getExe' hmConfig.programs.helix.package "hx"}";
|
||||||
SHELL = "${lib.getExe' hmConfig.programs.nushell.package "nu"}";
|
SHELL = "${lib.getExe' hmConfig.programs.nushell.package "nu"}";
|
||||||
NU_LIB_DIRS = "${lib.hm.nushell.toNushell (lib.concatStringsSep ":" [./nu])}";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -100,8 +100,11 @@
|
|||||||
networkmanager-l2tp
|
networkmanager-l2tp
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
hostName = "nixos";
|
hostName = "vinheim";
|
||||||
extraHosts = ''192.168.130.211 gitlab'';
|
hosts = {
|
||||||
|
"192.168.130.211" = ["gitlab"];
|
||||||
|
"192.168.130.210" = ["vault.local" "youtrack.local"];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
time.timeZone = "Asia/Yekaterinburg";
|
time.timeZone = "Asia/Yekaterinburg";
|
||||||
|
@ -106,8 +106,17 @@ in {
|
|||||||
rainfrog
|
rainfrog
|
||||||
|
|
||||||
networkmanagerapplet
|
networkmanagerapplet
|
||||||
|
|
||||||
|
rofi-wayland
|
||||||
];
|
];
|
||||||
|
|
||||||
|
home.file = {
|
||||||
|
".config/nushell/modules" = {
|
||||||
|
source = "${../common/hm/nu}";
|
||||||
|
recursive = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
configPackages = with pkgs; [
|
configPackages = with pkgs; [
|
||||||
@ -311,7 +320,8 @@ in {
|
|||||||
bind = [
|
bind = [
|
||||||
"SUPER, Q, exec, $terminal"
|
"SUPER, Q, exec, $terminal"
|
||||||
"SUPER, N, exec, $fileManager"
|
"SUPER, N, exec, $fileManager"
|
||||||
"SUPER, R, exec, $menu"
|
"SUPER, R, exec, nu -c 'use ~/.config/nushell/modules/mod.nu *; nurofi apps'"
|
||||||
|
"SUPER, P, exec, nu -c 'use ~/.config/nushell/modules/mod.nu *; nurofi powermenu'"
|
||||||
# "SUPER, X, exec, ags -t clock"
|
# "SUPER, X, exec, ags -t clock"
|
||||||
# "SUPER, X, exec, ags -t control"
|
# "SUPER, X, exec, ags -t control"
|
||||||
# "SUPER, X, exec, ags -t systray"
|
# "SUPER, X, exec, ags -t systray"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user