mirror of
https://gitlab.com/Zaney/zaneyos.git
synced 2024-11-21 22:23:09 +01:00
add waybar animation variable, add config files for starship and emoji selector, and add scripts back
This commit is contained in:
parent
66fdbea669
commit
796fa5fbaa
1630
config/emoji
Normal file
1630
config/emoji
Normal file
File diff suppressed because it is too large
Load Diff
148
config/starship.toml
Normal file
148
config/starship.toml
Normal file
@ -0,0 +1,148 @@
|
|||||||
|
## FIRST LINE/ROW: Info & Status
|
||||||
|
# First param ─┌
|
||||||
|
[username]
|
||||||
|
format = " [╭─$user]($style)@"
|
||||||
|
show_always = true
|
||||||
|
style_root = "bold red"
|
||||||
|
style_user = "bold red"
|
||||||
|
|
||||||
|
# Second param
|
||||||
|
[hostname]
|
||||||
|
disabled = false
|
||||||
|
format = "[$hostname]($style) in "
|
||||||
|
ssh_only = false
|
||||||
|
style = "bold dimmed red"
|
||||||
|
# If enabled hostnames with dashes will be cut off ##
|
||||||
|
#trim_at = "-"
|
||||||
|
|
||||||
|
# Third param
|
||||||
|
[directory]
|
||||||
|
style = "purple"
|
||||||
|
truncate_to_repo = true
|
||||||
|
truncation_length = 0
|
||||||
|
truncation_symbol = "repo: "
|
||||||
|
|
||||||
|
# Fourth param
|
||||||
|
[sudo]
|
||||||
|
disabled = false
|
||||||
|
|
||||||
|
# Before all the version info (python, nodejs, php, etc.)
|
||||||
|
[git_status]
|
||||||
|
ahead = "⇡${count}"
|
||||||
|
behind = "⇣${count}"
|
||||||
|
deleted = "x"
|
||||||
|
diverged = "⇕⇡${ahead_count}⇣${behind_count}"
|
||||||
|
style = "white"
|
||||||
|
|
||||||
|
# Last param in the first line/row
|
||||||
|
[cmd_duration]
|
||||||
|
disabled = true
|
||||||
|
format = "took [$duration]($style)"
|
||||||
|
min_time = 1
|
||||||
|
|
||||||
|
|
||||||
|
## SECOND LINE/ROW: Prompt
|
||||||
|
# Somethere at the beginning
|
||||||
|
[battery]
|
||||||
|
charging_symbol = ""
|
||||||
|
disabled = true
|
||||||
|
discharging_symbol = ""
|
||||||
|
full_symbol = ""
|
||||||
|
|
||||||
|
[[battery.display]] # "bold red" style when capacity is between 0% and 10%
|
||||||
|
disabled = false
|
||||||
|
style = "bold red"
|
||||||
|
threshold = 15
|
||||||
|
|
||||||
|
[[battery.display]] # "bold yellow" style when capacity is between 10% and 30%
|
||||||
|
disabled = true
|
||||||
|
style = "bold yellow"
|
||||||
|
threshold = 50
|
||||||
|
|
||||||
|
[[battery.display]] # "bold green" style when capacity is between 10% and 30%
|
||||||
|
disabled = true
|
||||||
|
style = "bold green"
|
||||||
|
threshold = 80
|
||||||
|
|
||||||
|
# Prompt: optional param 1
|
||||||
|
[time]
|
||||||
|
disabled = true
|
||||||
|
format = " 🕙 $time($style)\n"
|
||||||
|
style = "bright-white"
|
||||||
|
time_format = "%T"
|
||||||
|
|
||||||
|
# Prompt: param 2
|
||||||
|
[character]
|
||||||
|
error_symbol = " [×](bold red)"
|
||||||
|
success_symbol = " [╰─](bold red)"
|
||||||
|
|
||||||
|
# SYMBOLS
|
||||||
|
[status]
|
||||||
|
disabled = false
|
||||||
|
format = '[\[$symbol$status_common_meaning$status_signal_name$status_maybe_int\]]($style)'
|
||||||
|
map_symbol = true
|
||||||
|
pipestatus = true
|
||||||
|
symbol = "🔴"
|
||||||
|
|
||||||
|
[aws]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[conda]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[dart]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[docker_context]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[elixir]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[elm]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[git_branch]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[golang]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[hg_branch]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[java]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[julia]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[nim]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[nix_shell]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[nodejs]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[package]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[perl]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[php]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[python]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[ruby]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[rust]
|
||||||
|
symbol = " "
|
||||||
|
|
||||||
|
[swift]
|
||||||
|
symbol = "ﯣ "
|
@ -9,7 +9,7 @@
|
|||||||
let
|
let
|
||||||
palette = config.colorScheme.palette;
|
palette = config.colorScheme.palette;
|
||||||
betterTransition = "all 0.3s cubic-bezier(.55,-0.68,.48,1.682)";
|
betterTransition = "all 0.3s cubic-bezier(.55,-0.68,.48,1.682)";
|
||||||
inherit (import ../hosts/${host}/variables.nix) clock24h;
|
inherit (import ../hosts/${host}/variables.nix) clock24h waybarAnimations;
|
||||||
in
|
in
|
||||||
with lib;
|
with lib;
|
||||||
{
|
{
|
||||||
@ -217,7 +217,14 @@ with lib;
|
|||||||
color: #${palette.base00};
|
color: #${palette.base00};
|
||||||
background: linear-gradient(45deg, #${palette.base0E}, #${palette.base0F}, #${palette.base0D}, #${palette.base09});
|
background: linear-gradient(45deg, #${palette.base0E}, #${palette.base0F}, #${palette.base0D}, #${palette.base09});
|
||||||
background-size: 300% 300%;
|
background-size: 300% 300%;
|
||||||
animation: gradient_horizontal 15s ease infinite;
|
${
|
||||||
|
if waybarAnimations == true then
|
||||||
|
''
|
||||||
|
animation: gradient_horizontal 15s ease infinite;
|
||||||
|
''
|
||||||
|
else
|
||||||
|
''''
|
||||||
|
}
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
transition: ${betterTransition};
|
transition: ${betterTransition};
|
||||||
}
|
}
|
||||||
@ -229,7 +236,14 @@ with lib;
|
|||||||
color: #${palette.base00};
|
color: #${palette.base00};
|
||||||
background: linear-gradient(45deg, #${palette.base0E}, #${palette.base0F}, #${palette.base0D}, #${palette.base09});
|
background: linear-gradient(45deg, #${palette.base0E}, #${palette.base0F}, #${palette.base0D}, #${palette.base09});
|
||||||
background-size: 300% 300%;
|
background-size: 300% 300%;
|
||||||
animation: gradient_horizontal 15s ease infinite;
|
${
|
||||||
|
if waybarAnimations == true then
|
||||||
|
''
|
||||||
|
animation: gradient_horizontal 15s ease infinite;
|
||||||
|
''
|
||||||
|
else
|
||||||
|
''''
|
||||||
|
}
|
||||||
transition: ${betterTransition};
|
transition: ${betterTransition};
|
||||||
opacity: 1.0;
|
opacity: 1.0;
|
||||||
min-width: 40px;
|
min-width: 40px;
|
||||||
@ -239,7 +253,14 @@ with lib;
|
|||||||
color: #${palette.base00};
|
color: #${palette.base00};
|
||||||
background: linear-gradient(45deg, #${palette.base0E}, #${palette.base0F}, #${palette.base0D}, #${palette.base09});
|
background: linear-gradient(45deg, #${palette.base0E}, #${palette.base0F}, #${palette.base0D}, #${palette.base09});
|
||||||
background-size: 300% 300%;
|
background-size: 300% 300%;
|
||||||
animation: gradient_horizontal 15s ease infinite;
|
${
|
||||||
|
if waybarAnimations == true then
|
||||||
|
''
|
||||||
|
animation: gradient_horizontal 15s ease infinite;
|
||||||
|
''
|
||||||
|
else
|
||||||
|
''''
|
||||||
|
}
|
||||||
opacity: 0.8;
|
opacity: 0.8;
|
||||||
transition: ${betterTransition};
|
transition: ${betterTransition};
|
||||||
}
|
}
|
||||||
@ -288,7 +309,14 @@ with lib;
|
|||||||
color: #${palette.base01};
|
color: #${palette.base01};
|
||||||
background: linear-gradient(45deg, #${palette.base0C}, #${palette.base0F}, #${palette.base0B}, #${palette.base08});
|
background: linear-gradient(45deg, #${palette.base0C}, #${palette.base0F}, #${palette.base0B}, #${palette.base08});
|
||||||
background-size: 300% 300%;
|
background-size: 300% 300%;
|
||||||
animation: gradient_horizontal 15s ease infinite;
|
${
|
||||||
|
if waybarAnimations == true then
|
||||||
|
''
|
||||||
|
animation: gradient_horizontal 15s ease infinite;
|
||||||
|
''
|
||||||
|
else
|
||||||
|
''''
|
||||||
|
}
|
||||||
margin: 4px;
|
margin: 4px;
|
||||||
padding: 2px 10px;
|
padding: 2px 10px;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
@ -360,7 +388,14 @@ with lib;
|
|||||||
color: #${palette.base00};
|
color: #${palette.base00};
|
||||||
background: linear-gradient(45deg, #${palette.base09}, #${palette.base03}, #${palette.base0C}, #${palette.base07});
|
background: linear-gradient(45deg, #${palette.base09}, #${palette.base03}, #${palette.base0C}, #${palette.base07});
|
||||||
background-size: 300% 300%;
|
background-size: 300% 300%;
|
||||||
animation: gradient_horizontal 15s ease infinite;
|
${
|
||||||
|
if waybarAnimations == true then
|
||||||
|
''
|
||||||
|
animation: gradient_horizontal 15s ease infinite;
|
||||||
|
''
|
||||||
|
else
|
||||||
|
''''
|
||||||
|
}
|
||||||
margin: 4px;
|
margin: 4px;
|
||||||
padding: 2px 10px;
|
padding: 2px 10px;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
host,
|
host,
|
||||||
inputs,
|
inputs,
|
||||||
username,
|
username,
|
||||||
|
options,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
|
||||||
@ -22,6 +23,10 @@ in
|
|||||||
../../modules/local-hardware-clock.nix
|
../../modules/local-hardware-clock.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Kernel
|
||||||
|
boot.kernelPackages = pkgs.linuxPackages;
|
||||||
|
# boot.kernelPackages = pkgs.linuxPackages_zen;
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
@ -195,6 +200,7 @@ in
|
|||||||
};
|
};
|
||||||
libinput.enable = true;
|
libinput.enable = true;
|
||||||
openssh.enable = true;
|
openssh.enable = true;
|
||||||
|
flatpak.enable = false;
|
||||||
printing.enable = true;
|
printing.enable = true;
|
||||||
avahi = {
|
avahi = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@ -217,6 +223,13 @@ in
|
|||||||
rpcbind.enable = true;
|
rpcbind.enable = true;
|
||||||
nfs.server.enable = true;
|
nfs.server.enable = true;
|
||||||
};
|
};
|
||||||
|
systemd.services.flatpak-repo = {
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
path = [ pkgs.flatpak ];
|
||||||
|
script = ''
|
||||||
|
flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
|
||||||
|
'';
|
||||||
|
};
|
||||||
hardware.sane = {
|
hardware.sane = {
|
||||||
enable = true;
|
enable = true;
|
||||||
extraBackends = [ pkgs.sane-airscan ];
|
extraBackends = [ pkgs.sane-airscan ];
|
||||||
|
@ -46,6 +46,8 @@ in
|
|||||||
source = ../../config/fonts;
|
source = ../../config/fonts;
|
||||||
recursive = true;
|
recursive = true;
|
||||||
};
|
};
|
||||||
|
home.file.".config/starship.toml" = ../../config/starship.toml;
|
||||||
|
home.file.".emoji".source = .../../config/emoji;
|
||||||
|
|
||||||
# Install & Configure Git
|
# Install & Configure Git
|
||||||
programs.git = {
|
programs.git = {
|
||||||
@ -69,7 +71,84 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Scripts
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
(import ./../scripts/emopicker9000.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/task-waybar.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/squirtle.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/themechange.nix { inherit pkgs; inherit host; })
|
||||||
|
(import ./../scripts/theme-selector.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/nvidia-offload.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/web-search.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/rofi-launcher.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/screenshootin.nix { inherit pkgs; })
|
||||||
|
(import ./../scripts/list-hypr-bindings.nix { inherit pkgs; inherit host; })
|
||||||
|
];
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
|
gh.enable = true;
|
||||||
|
kitty = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.kitty;
|
||||||
|
font.name = "JetBrainsMono Nerd Font";
|
||||||
|
font.size = 16;
|
||||||
|
settings = {
|
||||||
|
scrollback_lines = 2000;
|
||||||
|
wheel_scroll_min_lines = 1;
|
||||||
|
window_padding_width = 4;
|
||||||
|
confirm_os_window_close = 0;
|
||||||
|
background_opacity = "0.85";
|
||||||
|
};
|
||||||
|
extraConfig = ''
|
||||||
|
foreground #${palette.base05}
|
||||||
|
background #${palette.base00}
|
||||||
|
color0 #${palette.base03}
|
||||||
|
color1 #${palette.base08}
|
||||||
|
color2 #${palette.base0B}
|
||||||
|
color3 #${palette.base09}
|
||||||
|
color4 #${palette.base0D}
|
||||||
|
color5 #${palette.base0E}
|
||||||
|
color6 #${palette.base0C}
|
||||||
|
color7 #${palette.base06}
|
||||||
|
color8 #${palette.base04}
|
||||||
|
color9 #${palette.base08}
|
||||||
|
color10 #${palette.base0B}
|
||||||
|
color11 #${palette.base0A}
|
||||||
|
color12 #${palette.base0C}
|
||||||
|
color13 #${palette.base0E}
|
||||||
|
color14 #${palette.base0C}
|
||||||
|
color15 #${palette.base07}
|
||||||
|
color16 #${palette.base00}
|
||||||
|
color17 #${palette.base0F}
|
||||||
|
color18 #${palette.base0B}
|
||||||
|
color19 #${palette.base09}
|
||||||
|
color20 #${palette.base0D}
|
||||||
|
color21 #${palette.base0E}
|
||||||
|
color22 #${palette.base0C}
|
||||||
|
color23 #${palette.base06}
|
||||||
|
cursor #${palette.base07}
|
||||||
|
cursor_text_color #${palette.base00}
|
||||||
|
selection_foreground #${palette.base01}
|
||||||
|
selection_background #${palette.base0D}
|
||||||
|
url_color #${palette.base0C}
|
||||||
|
active_border_color #${palette.base04}
|
||||||
|
inactive_border_color #${palette.base00}
|
||||||
|
bell_border_color #${palette.base03}
|
||||||
|
tab_bar_style fade
|
||||||
|
tab_fade 1
|
||||||
|
active_tab_foreground #${palette.base04}
|
||||||
|
active_tab_background #${palette.base00}
|
||||||
|
active_tab_font_style bold
|
||||||
|
inactive_tab_foreground #${palette.base07}
|
||||||
|
inactive_tab_background #${palette.base08}
|
||||||
|
inactive_tab_font_style bold
|
||||||
|
tab_bar_background #${palette.base00}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
starship = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.starship;
|
||||||
|
};
|
||||||
bash = {
|
bash = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableCompletion = true;
|
enableCompletion = true;
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
|
|
||||||
# Waybar Settings
|
# Waybar Settings
|
||||||
clock24h = false;
|
clock24h = false;
|
||||||
|
waybarAnimations = false;
|
||||||
|
|
||||||
# Program Options
|
# Program Options
|
||||||
browser = "firefox"; # Set Default Browser
|
browser = "firefox"; # Set Default Browser
|
||||||
|
18
scripts/emopicker9000.nix
Normal file
18
scripts/emopicker9000.nix
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "emopicker9000" ''
|
||||||
|
# Get user selection via wofi from emoji file.
|
||||||
|
chosen=$(cat $HOME/.emoji | ${pkgs.rofi-wayland}/bin/rofi -dmenu | awk '{print $1}')
|
||||||
|
|
||||||
|
# Exit if none chosen.
|
||||||
|
[ -z "$chosen" ] && exit
|
||||||
|
|
||||||
|
# If you run this command with an argument, it will automatically insert the
|
||||||
|
# character. Otherwise, show a message that the emoji has been copied.
|
||||||
|
if [ -n "$1" ]; then
|
||||||
|
${pkgs.ydotool}/bin/ydotool type "$chosen"
|
||||||
|
else
|
||||||
|
printf "$chosen" | ${pkgs.wl-clipboard}/bin/wl-copy
|
||||||
|
${pkgs.libnotify}/bin/notify-send "'$chosen' copied to clipboard." &
|
||||||
|
fi
|
||||||
|
''
|
61
scripts/list-hypr-bindings.nix
Executable file
61
scripts/list-hypr-bindings.nix
Executable file
@ -0,0 +1,61 @@
|
|||||||
|
{ pkgs, host, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
inherit ( import ../hosts/${host}/variables.nix ) terminal browser;
|
||||||
|
in
|
||||||
|
pkgs.writeShellScriptBin "list-hypr-bindings" ''
|
||||||
|
yad --width=800 --height=650 \
|
||||||
|
--center \
|
||||||
|
--fixed \
|
||||||
|
--title="Hyprland Keybindings" \
|
||||||
|
--no-buttons \
|
||||||
|
--list \
|
||||||
|
--column=Key: \
|
||||||
|
--column=Description: \
|
||||||
|
--column=Command: \
|
||||||
|
--timeout=90 \
|
||||||
|
--timeout-indicator=right \
|
||||||
|
" = Windows/Super/CAPS LOCK" "Modifier Key, used for keybindings" "Doesn't really execute anything by itself." \
|
||||||
|
" + ENTER" "Terminal" "${terminal}" \
|
||||||
|
" + SHIFT + ENTER" "Rofi App Launcher" "rofi -show drun" \
|
||||||
|
" + Q" "Kill Focused Window" "killactive" \
|
||||||
|
" + SHIFT + W" "Search Websites Like Nix Packages" "web-search" \
|
||||||
|
" + SHIFT + N" "Reload SwayNC Styling" "swaync-client -rs" \
|
||||||
|
" + W" "Launch Web Browser" "${browser}" \
|
||||||
|
" + E" "Launch Emoji Selector" "emopicker9000" \
|
||||||
|
" + S" "Take Screenshot" "screenshootin" \
|
||||||
|
" + D" "Launch Discord" "discord" \
|
||||||
|
" + O" "Launch OBS" "obs" \
|
||||||
|
" + G" "Launch GIMP" "gimp" \
|
||||||
|
" + N" "Launch New File Browser Window" "thunar" \
|
||||||
|
" + M" "Launch Spotify" "spotify" \
|
||||||
|
" + P" "Pseudo Tiling" "pseudo" \
|
||||||
|
" + SHIFT + I" "Toggle Split Direction" "togglesplit" \
|
||||||
|
" + F" "Toggle Focused Fullscreen" "fullscreen" \
|
||||||
|
" + SHIFT + F" "Toggle Focused Floating" "fullscreen" \
|
||||||
|
" + SHIFT + C" "Quit / Exit Hyprland" "exit" \
|
||||||
|
" + Left" "Move Focus To Window On The Left" "movefocus,l" \
|
||||||
|
" + Right" "Move Focus To Window On The Right" "movefocus,r" \
|
||||||
|
" + Up" "Move Focus To Window On The Up" "movefocus,u" \
|
||||||
|
" + Down" "Move Focus To Window On The Down" "movefocus,d" \
|
||||||
|
" + SHIFT + Left" "Move Focused Window Left" "movewindow,l" \
|
||||||
|
" + SHIFT + Right" "Move Focused Window Right" "movewindow,r" \
|
||||||
|
" + SHIFT + Up" "Move Focused Window Up" "movewindow,u" \
|
||||||
|
" + SHIFT + Down" "Move Focused Window Down" "movewindow,d" \
|
||||||
|
" + H" "Move Focus To Window On The Left" "movefocus,l" \
|
||||||
|
" + L" "Move Focus To Window On The Right" "movefocus,r" \
|
||||||
|
" + K" "Move Focus To Window On The Up" "movefocus,u" \
|
||||||
|
" + J" "Move Focus To Window On The Down" "movefocus,d" \
|
||||||
|
" + SHIFT + H" "Move Focused Window Left" "movewindow,l" \
|
||||||
|
" + SHIFT + L" "Move Focused Window Right" "movewindow,r" \
|
||||||
|
" + SHIFT + K" "Move Focused Window Up" "movewindow,u" \
|
||||||
|
" + SHIFT + J" "Move Focused Window Down" "movewindow,d" \
|
||||||
|
" + SPACE" "Toggle Special Workspace" "togglespecialworkspace" \
|
||||||
|
" + SHIFT + SPACE" "Send Focused Window To Special Workspace" "movetoworkspace,special" \
|
||||||
|
" + 1-0" "Move To Workspace 1 - 10" "workspace,X" \
|
||||||
|
" + SHIFT + 1-0" "Move Focused Window To Workspace 1 - 10" "movetoworkspace,X" \
|
||||||
|
" + MOUSE_LEFT" "Move/Drag Window" "movewindow" \
|
||||||
|
" + MOUSE_RIGHT" "Resize Window" "resizewindow" \
|
||||||
|
"ALT + TAB" "Cycle Window Focus + Bring To Front" "cyclenext & bringactivetotop" \
|
||||||
|
""
|
||||||
|
''
|
9
scripts/nvidia-offload.nix
Normal file
9
scripts/nvidia-offload.nix
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "nvidia-offload" ''
|
||||||
|
export __NV_PRIME_RENDER_OFFLOAD=1
|
||||||
|
export __NV_PRIME_RENDER_OFFLOAD_PROVIDER=NVIDIA-G0
|
||||||
|
export __GLX_VENDOR_LIBRARY_NAME=nvidia
|
||||||
|
export __VK_LAYER_NV_optimus=NVIDIA_only
|
||||||
|
exec "$@"
|
||||||
|
''
|
10
scripts/rofi-launcher.nix
Normal file
10
scripts/rofi-launcher.nix
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "rofi-launcher" ''
|
||||||
|
if pgrep -x "rofi" > /dev/null; then
|
||||||
|
# Rofi is running, kill it
|
||||||
|
pkill -x rofi
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
rofi -show drun
|
||||||
|
''
|
5
scripts/screenshootin.nix
Normal file
5
scripts/screenshootin.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "screenshootin" ''
|
||||||
|
grim -g "$(slurp)" - | swappy -f -
|
||||||
|
''
|
23
scripts/squirtle.nix
Normal file
23
scripts/squirtle.nix
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "squirtle" ''
|
||||||
|
echo "
|
||||||
|
[38;2;0;0;0m ████████ ██████
|
||||||
|
[38;2;0;0;0m ██[38;2;82;156;154m██[38;2;115;198;243m██████[38;2;0;0;0m████ ██[38;2;115;198;243m██████[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;115;200;243m████████████[38;2;85;137;157m██[38;2;8;0;0m██[38;2;0;0;0m██ ██[38;2;115;198;243m██████[38;2;79;159;151m████[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;115;200;243m████████████[38;2;123;206;235m██[38;2;46;69;78m██[38;2;189;107;37m██[38;2;0;0;0m████ ██[38;2;115;198;243m████[38;2;82;156;154m██[38;2;57;66;65m██[38;2;68;113;108m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m██[38;2;115;198;243m██[38;2;115;200;243m████[38;2;159;208;204m██[38;2;96;162;155m██[38;2;115;198;243m██████[38;2;82;156;154m██[38;2;66;61;66m██[38;2;214;132;38m██[38;2;198;119;38m██[38;2;0;0;0m██[38;2;86;146;154m██[38;2;107;214;243m██[38;2;82;156;154m██[38;2;66;66;66m██[38;2;82;156;154m████[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m██[38;2;115;198;243m██[38;2;115;200;243m████[38;2;33;115;105m██[38;2;222;255;254m██[38;2;0;0;0m██[38;2;115;198;243m████[38;2;82;156;154m██[38;2;66;61;66m██[38;2;140;96;52m██[38;2;198;119;38m████[38;2;66;78;66m██[38;2;86;146;154m██[38;2;82;156;154m██[38;2;66;66;66m██[38;2;82;156;154m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m██[38;2;115;198;243m██[38;2;115;200;243m████[38;2;77;144;162m██[38;2;0;4;0m██[38;2;41;8;1m██[38;2;123;214;235m██[38;2;82;156;154m████[38;2;66;66;66m██[38;2;255;255;255m██[38;2;140;82;44m██[38;2;214;140;46m██[38;2;90;103;88m██[38;2;49;111;121m██[38;2;85;159;151m██[38;2;46;80;76m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;115;200;243m████[38;2;115;214;243m██[38;2;0;4;0m██[38;2;68;77;79m██[38;2;96;145;157m██[38;2;82;156;154m██[38;2;66;66;66m██[38;2;192;192;192m██[38;2;255;255;255m██[38;2;140;82;44m██[38;2;214;140;46m██[38;2;173;86;21m██[38;2;90;103;88m██[38;2;85;159;151m██[38;2;8;0;0m██[38;2;0;0;0m
|
||||||
|
[38;2;0;0;0m [38;2;8;0;0m██[38;2;49;77;76m██[38;2;82;156;154m████[38;2;99;132;115m████[38;2;57;74;81m██[38;2;118;129;107m██[38;2;66;66;66m██[38;2;148;198;220m██[38;2;255;255;255m██[38;2;140;82;44m██[38;2;189;103;37m██[38;2;66;66;66m██[38;2;82;156;154m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m [38;2;8;0;0m██[38;2;91;154;152m██[38;2;66;66;66m████[38;2;49;103;113m██[38;2;198;189;118m██[38;2;239;239;159m██[38;2;57;74;81m██[38;2;148;198;220m██[38;2;66;66;66m██[38;2;255;255;255m██[38;2;140;82;44m██[38;2;148;91;47m██[38;2;66;66;66m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ████[38;2;247;231;143m██████[38;2;66;66;66m██[38;2;115;198;243m██████[38;2;66;66;66m██[38;2;140;82;44m██[38;2;189;107;37m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;206;173;94m████[38;2;66;66;66m██[38;2;115;198;243m████[38;2;82;156;154m██[38;2;66;66;66m██[38;2;140;82;44m██[38;2;189;107;37m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;57;115;105m██[38;2;80;85;69m██[38;2;239;239;159m██[38;2;255;231;127m██[38;2;74;66;58m██[38;2;82;156;154m██[38;2;66;66;66m██[38;2;58;69;71m██[38;2;173;198;197m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;57;115;105m██[38;2;80;85;69m██[38;2;0;8;24m██[38;2;195;176;104m████[38;2;66;66;66m████[38;2;115;133;134m██[38;2;58;69;71m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ████ ██[38;2;66;66;66m██[38;2;115;206;243m██[38;2;76;151;151m██[38;2;82;156;154m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██[38;2;76;151;151m██[38;2;57;123;105m██[38;2;82;156;154m██[38;2;0;0;0m██
|
||||||
|
[38;2;0;0;0m ██████ [0m
|
||||||
|
"
|
||||||
|
''
|
7
scripts/task-waybar.nix
Normal file
7
scripts/task-waybar.nix
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "task-waybar" ''
|
||||||
|
sleep 0.1
|
||||||
|
${pkgs.swaynotificationcenter}/bin/swaync-client -t &
|
||||||
|
''
|
||||||
|
|
17
scripts/theme-selector.nix
Normal file
17
scripts/theme-selector.nix
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "theme-selector" ''
|
||||||
|
# Get user selection for new theme from base16-themes file
|
||||||
|
chosen=$(cat $HOME/.base16-themes | ${pkgs.rofi-wayland}/bin/rofi -dmenu)
|
||||||
|
|
||||||
|
# Exit if none chosen.
|
||||||
|
[ -z "$chosen" ] && exit
|
||||||
|
|
||||||
|
if [ -n "$1" ]; then
|
||||||
|
themechange "$chosen"
|
||||||
|
else
|
||||||
|
${pkgs.libnotify}/bin/notify-send "$chosen is building please wait" &
|
||||||
|
themechange "$chosen"
|
||||||
|
${pkgs.libnotify}/bin/notify-send "Theme: $chosen has been applied." &
|
||||||
|
fi
|
||||||
|
''
|
11
scripts/themechange.nix
Normal file
11
scripts/themechange.nix
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
{ pkgs, host, username, ... }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "themechange" ''
|
||||||
|
if [[ ! $@ ]];then
|
||||||
|
echo "No Theme Given"
|
||||||
|
else
|
||||||
|
replacement="$1"
|
||||||
|
sed -i "/^\s*theme[[:space:]]*=[[:space:]]*\"/s/\"\(.*\)\"/\"$replacement\"/" /home/${username}/zaneyos/hosts/${host}/variables.nix
|
||||||
|
kitty -e pkexec nixos-rebuild switch --flake /home/${username}/zaneyos
|
||||||
|
fi
|
||||||
|
''
|
43
scripts/web-search.nix
Normal file
43
scripts/web-search.nix
Normal file
@ -0,0 +1,43 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
|
||||||
|
pkgs.writeShellScriptBin "web-search" ''
|
||||||
|
declare -A URLS
|
||||||
|
|
||||||
|
URLS=(
|
||||||
|
["🌎 Search"]="https://search.brave.com/search?q="
|
||||||
|
["❄️ Unstable Packages"]="https://search.nixos.org/packages?channel=unstable&from=0&size=50&sort=relevance&type=packages&query="
|
||||||
|
["🎞️ YouTube"]="https://www.youtube.com/results?search_query="
|
||||||
|
["🦥 Arch Wiki"]="https://wiki.archlinux.org/title/"
|
||||||
|
["🐃 Gentoo Wiki"]="https://wiki.gentoo.org/index.php?title="
|
||||||
|
)
|
||||||
|
|
||||||
|
# List for rofi
|
||||||
|
gen_list() {
|
||||||
|
for i in "''${!URLS[@]}"
|
||||||
|
do
|
||||||
|
echo "$i"
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
main() {
|
||||||
|
# Pass the list to rofi
|
||||||
|
platform=$( (gen_list) | ${pkgs.rofi-wayland}/bin/rofi -dmenu )
|
||||||
|
|
||||||
|
if [[ -n "$platform" ]]; then
|
||||||
|
query=$( (echo ) | ${pkgs.rofi-wayland}/bin/rofi -dmenu )
|
||||||
|
|
||||||
|
if [[ -n "$query" ]]; then
|
||||||
|
url=''${URLS[$platform]}$query
|
||||||
|
xdg-open "$url"
|
||||||
|
else
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
main
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
''
|
Loading…
Reference in New Issue
Block a user