chore: initial commit

This commit is contained in:
Alexandre Cavalheiro 2023-11-05 04:53:31 -03:00
commit d3948c7910
Signed by: wizardlink
GPG key ID: A5767B54367CFBDF
56 changed files with 8996 additions and 0 deletions

161
flake.lock Normal file
View file

@ -0,0 +1,161 @@
{
"nodes": {
"home-manager": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1698670511,
"narHash": "sha256-jQIu3UhBMPHXzVkHQO1O2gg8SVo5lqAVoC6mOaLQcLQ=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "8e5416b478e465985eec274bc3a018024435c106",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"hyprland": {
"inputs": {
"hyprland-protocols": "hyprland-protocols",
"nixpkgs": [
"nixpkgs"
],
"systems": "systems",
"wlroots": "wlroots",
"xdph": "xdph"
},
"locked": {
"lastModified": 1698694605,
"narHash": "sha256-hjWSt+oQzzd+EfCvQGNmE6m+qgnAESijI9q1OT+CRy8=",
"owner": "hyprwm",
"repo": "Hyprland",
"rev": "ab5497a0c9e9269b1036a0bede42cbd0bbfd94b9",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "Hyprland",
"type": "github"
}
},
"hyprland-protocols": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1691753796,
"narHash": "sha256-zOEwiWoXk3j3+EoF3ySUJmberFewWlagvewDRuWYAso=",
"owner": "hyprwm",
"repo": "hyprland-protocols",
"rev": "0c2ce70625cb30aef199cb388f99e19a61a6ce03",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprland-protocols",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1698318101,
"narHash": "sha256-gUihHt3yPD7bVqg+k/UVHgngyaJ3DMEBchbymBMvK1E=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "63678e9f3d3afecfeafa0acead6239cdb447574c",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"home-manager": "home-manager",
"hyprland": "hyprland",
"nixpkgs": "nixpkgs"
}
},
"systems": {
"locked": {
"lastModified": 1689347949,
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
"owner": "nix-systems",
"repo": "default-linux",
"rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default-linux",
"type": "github"
}
},
"wlroots": {
"flake": false,
"locked": {
"host": "gitlab.freedesktop.org",
"lastModified": 1697909146,
"narHash": "sha256-jU0I6FoCKnj4zIBL4daosFWh81U1fM719Z6cae8PxSY=",
"owner": "wlroots",
"repo": "wlroots",
"rev": "47bf87ade2bd32395615a385ebde1fefbcdf79a2",
"type": "gitlab"
},
"original": {
"host": "gitlab.freedesktop.org",
"owner": "wlroots",
"repo": "wlroots",
"rev": "47bf87ade2bd32395615a385ebde1fefbcdf79a2",
"type": "gitlab"
}
},
"xdph": {
"inputs": {
"hyprland-protocols": [
"hyprland",
"hyprland-protocols"
],
"nixpkgs": [
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1697981233,
"narHash": "sha256-y8q4XUwx+gVK7i2eLjfR32lVo7TYvEslyzrmzYEaPZU=",
"owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland",
"rev": "22e7a65ff9633e1dedfa5317fdffc49f68de2ff2",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "xdg-desktop-portal-hyprland",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

58
flake.nix Normal file
View file

@ -0,0 +1,58 @@
{
description = "NixOS System Flake";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
hyprland = {
url = "github:hyprwm/Hyprland";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = {
self,
nixpkgs,
home-manager,
hyprland,
...
}@inputs: {
nixosConfigurations.nixos =
let
system = "x86_64-linux";
modules = [
./nixos.nix
hyprland.nixosModules.default
{
programs.hyprland.enable = true;
}
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.wizardlink = import ./home-manager.nix;
}
];
in
nixpkgs.lib.nixosSystem { inherit system modules; };
homeConfigurations."wizardlink@nixos" = home-manager.lib.homeManagerConfiguration {
pkgs = nixpkgs.legacyPackages.x86_64-linux;
modules = [
hyprland.homeManagerModules.default
{
wayland.windowManager.hyprland.enable = true;
}
];
};
};
}

View file

@ -0,0 +1,53 @@
# Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{
imports =
[ (modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-amd" ];
boot.extraModulePackages = [ ];
fileSystems."/" =
{ device = "/dev/disk/by-uuid/65e4c115-aff0-4c0e-8799-7309a25ecab6";
fsType = "ext4";
};
fileSystems."/boot" =
{ device = "/dev/disk/by-uuid/2EFE-3A26";
fsType = "vfat";
};
fileSystems."/mnt/ssd" =
{ device = "/dev/disk/by-uuid/f27f2224-d351-46fd-89f5-991de36166ad";
fsType = "ext4";
};
fileSystems."/mnt/internal" =
{ device = "/dev/disk/by-uuid/b8541c0d-9146-4388-b217-431f196957cc";
fsType = "ext4";
};
fileSystems."/mnt/media" =
{ device = "/dev/disk/by-uuid/52c17b8b-46c1-4870-b86c-c3b9f4bd4434";
fsType = "ext4";
};
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.docker0.useDHCP = lib.mkDefault true;
# networking.interfaces.enp5s0.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
}

251
home-manager.nix Normal file
View file

@ -0,0 +1,251 @@
{ config, pkgs, ... }:
{
#
## HOME CONFIGURATION #
#
# Import configurations for better modularity.
imports = [
./programs/fish/config.nix
./programs/git.nix
./programs/hyprland/config.nix
./programs/mangohud.nix
./programs/obs-studio.nix
./programs/rofi/default.nix
./programs/waybar.nix
./programs/wezterm/config.nix
];
# Home Manager needs a bit of information about you and the paths it should
# manage.
home.username = "wizardlink";
home.homeDirectory = "/home/wizardlink";
# This value determines the Home Manager release that your configuration is
# compatible with. This helps avoid breakage when a new Home Manager release
# introduces backwards incompatible changes.
#
# You should not change this value, even if you update Home Manager. If you do
# want to update the value, then make sure to first check the Home Manager
# release notes.
home.stateVersion = "23.05"; # Please read the comment before changing.
# You can also manage environment variables but you will have to manually
# source
#
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
#
# or
#
# /etc/profiles/per-user/wizardlink/etc/profile.d/hm-session-vars.sh
# if you don't want to manage your shell through Home Manager.
home.sessionVariables = {
NNN_FIFO = "/tmp/nnn.fifo";
NNN_PLUG = "v:preview-tui";
WLR_NO_HARDWARE_CURSORS = "1";
};
##
## PACKAGES #
##
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# Configure NeoVim
programs.neovim = {
enable = true;
defaultEditor = true;
extraPackages = with pkgs; [
lua-language-server
stylua
];
};
# Configure fish
# The home.packages option allows you to install Nix packages into your
# environment.
home.packages = with pkgs; [
# # You can also create simple shell scripts directly inside your
# # configuration. For example, this adds a command 'my-hello' to your
# # environment:
# (pkgs.writeShellScriptBin "my-hello" ''
# echo "Hello, ${config.home.username}!"
# '')
## Tools
# Utilities
(callPackage ./programs/vesktop/default.nix {})
brightnessctl
discord
firefox
pavucontrol
pulseaudio
qbittorrent
tigervnc
vlc
yt-dlp
zathura
# Editing
shotcut
libreoffice
## Entertainment
jellyfin-media-player
spotify
# Gaming
dolphin-emu
path-of-building
## Libraries
(nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
rnnoise-plugin
## Development
lazygit
neofetch
## Desktop environment
eww-wayland
grim
mako
slurp
swww
wl-clipboard
# File management
atool
glow
imagemagick
nnn
poppler
];
#
## DOTFILES #
#
# Home Manager is pretty good at managing dotfiles. The primary way to manage
# plain files is through 'home.file'.
home.file = {
".config/fish/themes/Catppuccin-Frappe.theme" = {
source = ./programs/fish/Catppuccin-Frappe.theme;
};
".config/gamemode.ini" = {
source = ./programs/gamemode.ini;
};
".config/mako" = {
source = ./programs/mako;
};
".config/nvim" = {
source = ./programs/nvim;
};
".config/qt5ct/colors" = {
source = ./theming/qt5ct;
};
".config/pipewire/pipewire.conf.d/99-input-denoising.conf" = {
text = ''
context.modules = [
{ name = libpipewire-module-filter-chain
args = {
node.description = "Noise Canceling source"
media.name = "Noise Canceling source"
filter.graph = {
nodes = [
{
type = ladspa
name = rnnoise
plugin = ${rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so
label = noise_suppressor_mono
control = {
"VAD Threshold (%)" = 75.0
"VAD Grace Period (ms)" = 300
"Retroactive VAD Grace (ms)" = 0
}
}
]
}
capture.props = {
node.name = "capture.rnnoise_source"
node.passive = true
audio.rate = 48000
}
playback.props = {
node.name = "rnnoise_source"
media.class = Audio/Source
audio.rate = 48000
}
}
}
]
'';
};
".local/share/scripts" = {
source = ./scripts;
};
};
## Theming
home.pointerCursor = {
package = pkgs.catppuccin-cursors.frappeLavender;
name = "Catppuccin-Frappe-Lavender-Cursors";
gtk.enable = true;
x11 = {
enable = true;
defaultCursor = "Catppuccin-Frappe-Lavender-Cursors";
};
};
# Configure GTK.
gtk = {
enable = true;
theme = {
name = "Catppuccin-Frappe-Lavender";
package = pkgs.catppuccin-gtk.override {
accents = [ "lavender" ];
tweaks = [ "rimless" ];
variant = "frappe";
};
};
iconTheme = {
name = "Papirus";
package = pkgs.catppuccin-papirus-folders.override {
accent = "lavender";
flavor = "frappe";
};
};
};
# Configure QT
qt = {
enable = true;
platformTheme = "gtk";
style = {
name = "Catppuccin-Frappe-Lavender";
package = pkgs.catppuccin-gtk.override {
accents = [ "lavender" ];
tweaks = [ "rimless" ];
variant = "frappe";
};
};
};
}

358
nixos.nix Normal file
View file

@ -0,0 +1,358 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, pkgs, ... }:
{
##
## NIXOS ##
##
imports =
[ # Include the results of the hardware scan.
./hardware-configuration.nix
# Include service configuration
./services/caddy.nix
./services/jellyfin.nix
];
# Enable experimental features
nix.settings.experimental-features = [ "nix-command" "flakes" ];
# Enable automatic garbage collection.
nix.gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 1w";
};
# Optimize storage
nix.settings.auto-optimise-store = true;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "23.05"; # Did you read the comment?
##
## SYSTEM ##
##
# Kernel
boot.kernelPackages = pkgs.linuxPackages_xanmod;
# Add AMD drivers.
boot.initrd.kernelModules = [ "amdgpu" ];
# TODO: FIX IT BEING BEING OVERWRITTEN
boot.extraModulePackages = with config.boot.kernelPackages; [ v4l2loopback ];
# Bootloader.
boot.loader = {
systemd-boot = {
enable = true;
configurationLimit = 10;
};
efi.canTouchEfiVariables = true;
};
networking.hostName = "nixos"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
# Open ports in the firewall.
networking.firewall = {
allowedTCPPorts = [
80 # HTTP
443 # SSL
];
allowedUDPPorts = [
2626 # Dolphin emulator
27015
];
allowedTCPPortRanges = [
{ from = 1714; to = 1764; } # KDEConnect
];
allowedUDPPortRanges = [
{ from = 1714; to = 1764; } # KDEConnect
];
};
# Or disable the firewall altogether.
# networking.firewall.enable = false;
# Define system-wide variables.
environment.variables = {
AMD_VULKAN_ICD = "RADV";
EDITOR = "nvim";
NIXOS_OZONE_WL = "1";
};
# Define a user account. Don't forget to set a password with passwd.
users.users.wizardlink = {
createHome = true;
description = "Alexandre Cavalheiro";
extraGroups = [ "networkmanager" "wheel" "postgresql" "docker" ];
isNormalUser = true;
shell = pkgs.fish;
openssh.authorizedKeys.keys = [
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDdGOyRbu6IOw9yqotxE6m7wCif7oP/2D0tlREa5Q6uo Alexandre Cavalheiro S. Tiago da Silva <contact@thewizard.link>"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIISfCUsZrnCMZapdrvkUCrdRiX+1xuZBdGrynNRzDI2v" # SpaceEEC
];
};
# Set your time zone.
time.timeZone = "America/Sao_Paulo";
# Select internationalisation properties.
i18n = {
defaultLocale = "en_US.UTF-8";
extraLocaleSettings = {
LC_ADDRESS = "pt_BR.UTF-8";
LC_IDENTIFICATION = "pt_BR.UTF-8";
LC_MEASUREMENT = "pt_BR.UTF-8";
LC_MONETARY = "pt_BR.UTF-8";
LC_NAME = "pt_BR.UTF-8";
LC_NUMERIC = "pt_BR.UTF-8";
LC_PAPER = "pt_BR.UTF-8";
LC_TELEPHONE = "pt_BR.UTF-8";
LC_TIME = "pt_BR.UTF-8";
};
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable the OpenSSH daemon.
services.openssh = {
enable = true;
settings = {
PasswordAuthentication = false;
PermitRootLogin = "no";
};
};
##
## HARDWARE ##
##
# Enable Bluetooth
hardware.bluetooth = {
enable = true;
powerOnBoot = true;
};
services.blueman.enable = true;
# Enable openrazer for managing Razer products' configuration
hardware.openrazer = {
enable = true;
users = [ "wizardlink" ];
};
##
## DESKTOP ##
##
# Enable the X11 windowing system.
services.xserver.enable = true;
# Enable GDM.
services.xserver.displayManager.sddm = {
enable = true;
theme = "${import ./theming/sddm.nix { inherit pkgs; }}";
};
# Enable OpenGL.
hardware.opengl = {
enable = true;
driSupport = true;
driSupport32Bit = true;
extraPackages = with pkgs; [
rocm-opencl-icd # OpenGL hwa
rocm-opencl-runtime
];
};
# Enable XDG Desktop Portals.
xdg.portal = {
enable = true;
extraPortals = with pkgs; [
xdg-desktop-portal-gtk
#xdg-desktop-portal-hyprland
];
};
##
## INPUT ##
##
# Configure keymap in X11
services.xserver = {
layout = "us";
xkbVariant = "";
};
##
## SOUND #
##
# Enable sound with pipewire.
sound.enable = true;
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
services.pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
##
## PACKAGES ##
##
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# Enable GPG.
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
# Enable fish system-wide to integrate with nixpkgs.
programs.fish.enable = true;
# Enable Steam.
programs.steam = {
enable = true;
remotePlay.openFirewall = true;
};
# Enable and configure gamemode.
programs.gamemode = {
enable = true;
enableRenice = true;
};
# Enable KDEConnect
programs.kdeconnect.enable = true;
# Enable Docker.
virtualisation.docker.enable = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
## Tools
# Utilities
bat
broot
btop
docker-compose
duf
fzf
gping
killall
nmap
ripgrep
tree
unrar
unzip
wget
zip
zoxide
## Development
# C
gcc
gnumake
# Nim
nim
# NodeJS
nodejs
yarn
yarn2nix
# Python
python3
python3Packages.pip
rustup
## Libraries
libsForQt5.qt5.qtgraphicaleffects
libsForQt5.qt5.qtquickcontrols2
libsForQt5.qtstyleplugins
## Desktop environment
polkit-kde-agent
## Hardware specific
openrazer-daemon # Razor products back-end
polychromatic # and it's Front-end
];
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
# programs.gnupg.agent = {
# enable = true;
# enableSSHSupport = true;
# };
##
## SERVICES #
##
# Enable flatpak
services.flatpak.enable = true;
# Enable and configure PostgreSQL.
services.postgresql = {
enable = true;
identMap = ''
# MAP_NAME SYSTEM_USER DB_USER
superuser_map root postgres
superuser_map postgres postgres
superuser_map /^(.*)$ \1
'';
authentication = pkgs.lib.mkOverride 10 ''
# TYPE DATABASE USER ADDRESS METHOD MAP
local all all peer map=superuser_map
host all all 127.0.0.1/32 md5
host all all ::1/128 md5
local replication all peer map=superuser_map
host replication all 127.0.0.1/32 ident map=superuser_map
host replication all ::1/128 ident map=superuser_map
'';
initialScript = pkgs.writeText "backend-initScript" ''
CREATE ROLE wizardlink WITH LOGIN SUPERUSER PASSWORD 'wizardlink' CREATEDB CREATEROLE REPLICATION;
CREATE DATABASE wizardlink;
GRANT ALL PRIVILEGES ON DATABASE wizardlink TO wizardlink;
'';
};
}

View file

@ -0,0 +1,30 @@
# name: 'Catppuccin frappe'
# url: 'https://github.com/catppuccin/fish'
# preferred_background: 303446
fish_color_normal c6d0f5
fish_color_command 8caaee
fish_color_param eebebe
fish_color_keyword e78284
fish_color_quote a6d189
fish_color_redirection f4b8e4
fish_color_end ef9f76
fish_color_comment 838ba7
fish_color_error e78284
fish_color_gray 737994
fish_color_selection --background=414559
fish_color_search_match --background=414559
fish_color_option a6d189
fish_color_operator f4b8e4
fish_color_escape ea999c
fish_color_autosuggestion 737994
fish_color_cancel e78284
fish_color_cwd e5c890
fish_color_user 81c8be
fish_color_host 8caaee
fish_color_host_remote a6d189
fish_color_status e78284
fish_pager_color_progress 737994
fish_pager_color_prefix f4b8e4
fish_pager_color_completion c6d0f5
fish_pager_color_description 737994

39
programs/fish/config.nix Normal file
View file

@ -0,0 +1,39 @@
{ pkgs, ... }:
{
programs.fish = {
enable = true;
interactiveShellInit = ''
## Set vim mode
set -g fish_key_bindings fish_vi_key_bindings
# Configure FZF
set -x FZF_DEFAULT_OPTS '--color=fg:#f8f8f2,hl:#bd93f9 --color=fg+:#f8f8f2,bg+:#44475a,hl+:#bd93f9 --color=info:#ffb86c,prompt:#50fa7b,pointer:#ff79c6 --color=marker:#ff79c6,spinner:#ffb86c,header:#6272a4 --layout=reverse --height 50%'
# Remove welcome message
set -x fish_greeting ""
## Add directories to $PATH
fish_add_path /home/wizardlink/.local/share/scripts \
/home/wizardlink/.config/emacs/bin \
/home/wizardlink/.spicetify \
/home/wizardlink/.nimble/bin \
/home/wizardlink/.cargo/bin \
/home/wizardlink/.local/bin \
/lib/flatpak/exports/bin \
/home/wizardlink/.local/share/scripts/burrito
'';
functions = {
fish_prompt.body = ''
set_color CC241D
echo '&' (set_color normal)
'';
fzf_edit.body = ''
fzf --multi --bind 'enter:become(nvim {+})'
'';
};
};
}

76
programs/gamemode.ini Normal file
View file

@ -0,0 +1,76 @@
[general]
; The reaper thread will check every 5 seconds for exited clients, for config file changes, and for the CPU/iGPU power balance
reaper_freq=5
; The desired governor is used when entering GameMode instead of "performance"
desiredgov=performance
; The default governor is used when leaving GameMode instead of restoring the original value
;defaultgov=powersave
; GameMode can change the scheduler policy to SCHED_ISO on kernels which support it (currently
; not supported by upstream kernels). Can be set to "auto", "on" or "off". "auto" will enable
; with 4 or more CPU cores. "on" will always enable. Defaults to "off".
softrealtime=off
; GameMode can renice game processes. You can put any value between 0 and 20 here, the value
; will be negated and applied as a nice value (0 means no change). Defaults to 0.
renice=5
; By default, GameMode adjusts the iopriority of clients to BE/0, you can put any value
; between 0 and 7 here (with 0 being highest priority), or one of the special values
; "off" (to disable) or "reset" (to restore Linux default behavior based on CPU priority),
; currently, only the best-effort class is supported thus you cannot set it here
ioprio=2
; Sets whether gamemode will inhibit the screensaver when active
; Defaults to 1
inhibit_screensaver=0
[filter]
; If "whitelist" entry has a value(s)
; gamemode will reject anything not in the whitelist
;whitelist=RiseOfTheTombRaider
; Gamemode will always reject anything in the blacklist
;blacklist=HalfLife3
; glxgears
[gpu]
; Here Be Dragons!
; Warning: Use these settings at your own risk
; Any damage to hardware incurred due to this feature is your responsibility and yours alone
; It is also highly recommended you try these settings out first manually to find the sweet spots
; Setting this to the keyphrase "accept-responsibility" will allow gamemode to apply GPU optimisations such as overclocks
;apply_gpu_optimisations=accept-responsibility
; The DRM device number on the system (usually 0), ie. the number in /sys/class/drm/card0/
;gpu_device=0
; AMD specific settings
; Requires a relatively up to date AMDGPU kernel module
; See: https://dri.freedesktop.org/docs/drm/gpu/amdgpu.html#gpu-power-thermal-controls-and-monitoring
; It is also highly recommended you use lm-sensors (or other available tools) to verify card temperatures
; This corresponds to power_dpm_force_performance_level, "manual" is not supported for now
amd_performance_level=auto
[supervisor]
; This section controls the new gamemode functions gamemode_request_start_for and gamemode_request_end_for
; The whilelist and blacklist control which supervisor programs are allowed to make the above requests
;supervisor_whitelist=
;supervisor_blacklist=
; In case you want to allow a supervisor to take full control of gamemode, this option can be set
; This will only allow gamemode clients to be registered by using the above functions by a supervisor client
;require_supervisor=0
[custom]
; Custom scripts (executed using the shell) when gamemode starts and ends
;start=notify-send "GameMode started"
; /home/me/bin/stop_ethmining.sh
;end=notify-send "GameMode ended"
; /home/me/bin/start_ethmining.sh
; Timeout for scripts (seconds). Scripts will be killed if they do not complete within this time.
;script_timeout=10

95
programs/git.nix Normal file
View file

@ -0,0 +1,95 @@
{ ... }:
{
# Enable GIT.
programs.git = {
enable = true;
aliases = {
# List aliases
aliases = "config --get-regexp alias";
# List all the contributors with commit amount
contributors = "shortlog --summary --numbered";
# Output verbose info about branches and tags
branches = "branch -avv";
# List all tags
tags = "tag -l";
# Pretty logs
plog = "log --graph --decorate --all";
# Pretty grep
gcommit = "log --graph --decorate --grep";
};
extraConfig = {
core = {
# Set the editor to be used by GIT
editor = "nvim";
# Custom .gitignore
excludesfile = "~/.gitignore";
# Treat trailing whitespaces and spaces before tabs as an error
whitespace = "space-before-tab,-indent-with-non-tab,trailing-space";
};
color = {
# Use colors in GIT commmands.
ui = "auto";
};
commit = {
# https://help.github.com/articles/signing-commits-using-gpg/
gpgsign = true;
};
tag = {
gpgsign = true;
};
difftool = {
prompt = true;
};
mergetool = {
# https://www.git-scm.com/docs/git-mergetool#Documentation/git-mergetool.txt---no-prompt
prompt = false;
};
merge = {
# https://git-scm.com/docs/git-merge#_how_conflicts_are_presented
conflictstyle = "diff3";
};
push = {
# https://stackoverflow.com/questions/21839651/git-what-is-the-difference-between-push-default-matching-and-simple
default = "simple";
# git-push pushes relevant annotated tags when pushing branches out
followTags = true;
};
user = {
name = "Alexandre Cavalheiro S. Tiago da Silva";
email = "contact@thewizard.link";
signingkey = "A1D3A2B4E14BD7C0445BB749A5767B54367CFBDF";
};
pull = {
ff = "only";
};
init = {
defaultBranch = "main";
};
credential = {
helper = "/usr/libexec/git-core/git-credential-libsecret";
};
};
};
}

View file

@ -0,0 +1,8 @@
{ ... }:
{
wayland.windowManager.hyprland = {
enable = true;
extraConfig = builtins.readFile ./hyprland.conf;
};
}

View file

@ -0,0 +1,254 @@
########################################################################################
AUTOGENERATED HYPR CONFIG.
PLEASE USE THE CONFIG PROVIDED IN THE GIT REPO /examples/hypr.conf AND EDIT IT,
OR EDIT THIS ONE ACCORDING TO THE WIKI INSTRUCTIONS.
########################################################################################
# Catppuccin Macchiato - https://github.com/catppuccin/hyprland
$rosewaterAlpha = f4dbd6
$flamingoAlpha = f0c6c6
$pinkAlpha = f5bde6
$mauveAlpha = c6a0f6
$redAlpha = ed8796
$maroonAlpha = ee99a0
$peachAlpha = f5a97f
$yellowAlpha = eed49f
$greenAlpha = a6da95
$tealAlpha = 8bd5ca
$skyAlpha = 91d7e3
$sapphireAlpha = 7dc4e4
$blueAlpha = 8aadf4
$lavenderAlpha = b7bdf8
$textAlpha = cad3f5
$subtext1Alpha = b8c0e0
$subtext0Alpha = a5adcb
$overlay2Alpha = 939ab7
$overlay1Alpha = 8087a2
$overlay0Alpha = 6e738d
$surface2Alpha = 5b6078
$surface1Alpha = 494d64
$surface0Alpha = 363a4f
$baseAlpha = 24273a
$mantleAlpha = 1e2030
$crustAlpha = 181926
$rosewater = 0xfff5e0dc
$flamingo = 0xfff2cdcd
$pink = 0xfff5c2e7
$mauve = 0xffcba6f7
$red = 0xfff38ba8
$maroon = 0xffeba0ac
$peach = 0xfffab387
$yellow = 0xfff9e2af
$green = 0xffa6e3a1
$teal = 0xff94e2d5
$sky = 0xff89dceb
$sapphire = 0xff74c7ec
$blue = 0xff89b4fa
$lavender = 0xffb4befe
$text = 0xffcdd6f4
$subtext1 = 0xffbac2de
$subtext0 = 0xffa6adc8
$overlay2 = 0xff9399b2
$overlay1 = 0xff7f849c
$overlay0 = 0xff6c7086
$surface2 = 0xff585b70
$surface1 = 0xff45475a
$surface0 = 0xff313244
$base = 0xff1e1e2e
$mantle = 0xff181825
$crust = 0xff11111b
#
# Please note not all available settings / options are set here.
# For a full list, see the wiki
#
autogenerated = 0 # remove this line to remove the warning
# See https://wiki.hyprland.org/Configuring/Monitors/
monitor = DP-2, 1920x1080@75, 2560x0, 1
monitor = DP-3, 2560x1440@165, 0x0, 1
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
# Execute your favorite apps at launch
exec-once = ~/.local/share/scripts/hyprland/start_services.sh
exec-once = xrandr --output DP-3 --primary
# Source a file (multi-file configs)
# source = ~/.config/hypr/myColors.conf
# Some default env vars.
env = XCURSOR_SIZE,36
env = QT_QPA_PLATFORM,wayland
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
input {
kb_layout = us
kb_variant =
kb_model =
kb_options =
kb_rules =
follow_mouse = 1
float_switch_override_focus = 0
accel_profile = flat
force_no_accel = true
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
}
general {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
gaps_in = 5
gaps_out = 20
border_size = 2
col.active_border = $lavender
col.inactive_border = $crust
layout = dwindle
}
decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
rounding = 8
# FIXME: Check these deprecations.
#blur = yes
#blur_size = 3
#blur_passes = 1
#blur_new_optimizations = on
drop_shadow = yes
shadow_range = 4
shadow_render_power = 3
col.shadow = rgba(1a1a1aee)
}
animations {
enabled = yes
# Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
animation = windows, 1, 7, myBezier
animation = windowsOut, 1, 7, default, popin 80%
animation = border, 1, 10, default
animation = borderangle, 1, 8, default
animation = fade, 1, 7, default
animation = workspaces, 1, 6, default
}
dwindle {
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
preserve_split = yes # you probably want this
}
master {
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
new_is_master = true
}
gestures {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
workspace_swipe = off
}
# Example per-device config
# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more
device:epic-mouse-v1 {
sensitivity = -0.5
}
# Example windowrule v1
# windowrule = float, ^(kitty)$
# Example windowrule v2
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
# Bind workspaces to specific monitors
workspace = 1, monitor:DP-3
workspace = 2, monitor:DP-2
workspace = 3, monitor:DP-3
workspace = 4, monitor:DP-2
workspace = 5, monitor:DP-3
workspace = 6, monitor:DP-2
workspace = 7, monitor:DP-3
workspace = 8, monitor:DP-2
workspace = 9, monitor:DP-3
workspace = 0, monitor:DP-2
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
$mainMod = SUPER
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
bind = $mainMod, Q, exec, wezterm
bind = $mainMod, C, killactive
bind = $mainMod, M, exit
bind = $mainMod, E, exec, dolphin
bind = $mainMod, V, togglefloating
bind = $mainMod CTRL, V, pin
bind = $mainMod, R, exec, rofi -show drun
bind = $mainMod, P, pseudo # dwindle
bind = $mainMod SHIFT, P, exec, ~/.local/share/scripts/hyprland/screenshot.sh
bind = $mainMod CTRL, P, exec, ~/.local/share/scripts/hyprland/screenshot_area.sh
bind = $mainMod, O, togglesplit # dwindle
bind = $mainMod, F, fullscreen
bind = $mainMod SHIFT, F, fullscreen, 1
bind = $mainMod CTRL, F, fakefullscreen
# Move focus with mainMod + arrow keys
bind = $mainMod, H, movefocus, l
bind = $mainMod, L, movefocus, r
bind = $mainMod, K, movefocus, u
bind = $mainMod, J, movefocus, d
# Switch workspaces with mainMod + [0-9]
bind = $mainMod, 1, workspace, 1
bind = $mainMod, 2, workspace, 2
bind = $mainMod, 3, workspace, 3
bind = $mainMod, 4, workspace, 4
bind = $mainMod, 5, workspace, 5
bind = $mainMod, 6, workspace, 6
bind = $mainMod, 7, workspace, 7
bind = $mainMod, 8, workspace, 8
#bind = $mainMod, 9, workspace, 9
#bind = $mainMod, 0, workspace, 10
# Move active window to a workspace with mainMod + SHIFT + [0-9]
bind = $mainMod SHIFT, 1, movetoworkspace, 1
bind = $mainMod SHIFT, 2, movetoworkspace, 2
bind = $mainMod SHIFT, 3, movetoworkspace, 3
bind = $mainMod SHIFT, 4, movetoworkspace, 4
bind = $mainMod SHIFT, 5, movetoworkspace, 5
bind = $mainMod SHIFT, 6, movetoworkspace, 6
bind = $mainMod SHIFT, 7, movetoworkspace, 7
bind = $mainMod SHIFT, 8, movetoworkspace, 8
bind = $mainMod SHIFT, 9, movetoworkspace, 9
bind = $mainMod SHIFT, 0, movetoworkspace, 10
# Scroll through existing workspaces with mainMod + scroll
bind = $mainMod, mouse_down, workspace, e+1
bind = $mainMod, mouse_up, workspace, e-1
# Move/resize windows with mainMod + LMB/RMB and dragging
bind = $mainMod SHIFT, H, movewindow, l
bind = $mainMod SHIFT, L, movewindow, r
bind = $mainMod SHIFT, K, movewindow, u
bind = $mainMod SHIFT, J, movewindow, d
bindm = $mainMod, mouse:272, movewindow
bindm = $mainMod, mouse:273, resizewindow

32
programs/mako/config Normal file
View file

@ -0,0 +1,32 @@
anchor=bottom-right
background-color=#282a36
border-color=#282a36
border-radius=20
border-size=2
default-timeout=10000
format=<span font="FantasqueSansMono NF weight=325 Italic" size="12288">%s</span>\n<span font="FantasqueSansMono NF weight=325" size="12288">%b</span>
group-by=summary
height=125
icon-location=right
layer=top
margin=0,20,15
markup=1
max-icon-size=48
padding=10,5,10
text-color=#44475a
width=300
[grouped]
format=<span font="FantasqueSansMono NF weight=325 Italic" size="12288">%s</span>\n<span font="FantasqueSansMono NF weight=325" size="12288">%b</span>
[mode=do-not-disturb]
invisible=1
[urgency=low]
border-color=#282a36
[urgency=normal]
border-color=#f1fa8c
[urgency=high]
border-color=#ff5555

63
programs/mangohud.nix Normal file
View file

@ -0,0 +1,63 @@
{ ... }:
{
programs.mangohud = {
enable = true;
settings = {
# Limitations
fps_limit = 165;
vsync = 1;
gl_vsync = 0;
# GPU Statistics
gpu_stats = true;
gpu_temp = true;
gpu_core_clock = true;
gpu_mem_clock = true;
gpu_power = true;
gpu_load_change = true;
gpu_load_value = [ 60 90 ];
gpu_load_color = [ "39F900" "FDFD09" "B22222" ];
# CPU Statistics
cpu_stats = true;
cpu_temp = true;
cpu_power = true;
cpu_mhz = true;
cpu_load_change = true;
cpu_load_value = [ 60 90 ];
cpu_load_color= [ "39F900" "FDFD09" "B22222" ];
# IO Statistics
io_stats = true;
io_read = true;
io_write = true;
# RAM Statistics
vram = true;
ram = true;
swap = true;
# FPS Statistics
fps = true;
fps_color_change = true;
fps_value = [ 60 90 ];
fps_color = [ "B22222" "FDFD09" "39F900" ];
frametime = true;
frame_timing = true; # Display graphs
histogram = true; # ^
# Show whether gamemode is enabled for the application.
gamemode = true;
# Make so MangoHud starts hidden.
no_display = true;
# Where to output log files.
output_folder=/home/wizardlink/.config/MangoHud;
};
};
}

8
programs/nvim/.gitignore vendored Normal file
View file

@ -0,0 +1,8 @@
tt.*
.tests
doc/tags
debug
.repro
foo.*
*.log
data

View file

@ -0,0 +1,15 @@
{
"neodev": {
"library": {
"enabled": true,
"plugins": true
}
},
"neoconf": {
"plugins": {
"lua_ls": {
"enabled": true
}
}
}
}

2
programs/nvim/init.lua Normal file
View file

@ -0,0 +1,2 @@
-- bootstrap lazy.nvim, LazyVim and your plugins
require("config.lazy")

View file

@ -0,0 +1,56 @@
{
"LazyVim": { "branch": "main", "commit": "68ff818a5bb7549f90b05e412b76fe448f605ffb" },
"LuaSnip": { "branch": "master", "commit": "a4de64570b9620875c8ea04175cd07ed8e32ac99" },
"bufferline.nvim": { "branch": "main", "commit": "9e8d2f695dd50ab6821a6a53a840c32d2067a78a" },
"catppuccin": { "branch": "main", "commit": "d7521f6050b94cb0e23067f63829d86886f870fe" },
"cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" },
"cmp-emoji": { "branch": "main", "commit": "19075c36d5820253d32e2478b6aaf3734aeaafa0" },
"cmp-nvim-lsp": { "branch": "main", "commit": "44b16d11215dce86f253ce0c30949813c0a90765" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
"conform.nvim": { "branch": "master", "commit": "0bbe83830be5a07a1161bb1a23d7280310656177" },
"crates.nvim": { "branch": "main", "commit": "aac57ef84cf4fecf7907114b22e875f84a6128ee" },
"dashboard-nvim": { "branch": "master", "commit": "c71cab740e2add248c54c458b5ca9d6e77c30fa6" },
"dressing.nvim": { "branch": "master", "commit": "1f2d1206a03bd3add8aedf6251e4534611de577f" },
"flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" },
"friendly-snippets": { "branch": "main", "commit": "43727c2ff84240e55d4069ec3e6158d74cb534b6" },
"gitsigns.nvim": { "branch": "main", "commit": "af0f583cd35286dd6f0e3ed52622728703237e50" },
"indent-blankline.nvim": { "branch": "master", "commit": "29be0919b91fb59eca9e90690d76014233392bef" },
"lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" },
"lualine.nvim": { "branch": "master", "commit": "2248ef254d0a1488a72041cfb45ca9caada6d994" },
"mini.ai": { "branch": "main", "commit": "4a2e387b121352dfb478f440c9a5313a9d97006c" },
"mini.bufremove": { "branch": "main", "commit": "f53c7f27e36009fe61563c11cde154b94a0e5b94" },
"mini.comment": { "branch": "main", "commit": "3d9c8009615857e982f09bc5357fc95f2a2175f3" },
"mini.indentscope": { "branch": "main", "commit": "c8fdafa7bf603d758986a27eb546c55a5c73b1a3" },
"mini.pairs": { "branch": "main", "commit": "71f117fd57f930da6ef4126b24f594dd398bac26" },
"mini.surround": { "branch": "main", "commit": "af8129efcabe95fc08a233e9f91569829bed031f" },
"neo-tree.nvim": { "branch": "v3.x", "commit": "1236db954ce502eb5b340bcdb69aa057cc372e8d" },
"neoconf.nvim": { "branch": "main", "commit": "64437787dba70fce50dad7bfbb97d184c5bc340f" },
"neodev.nvim": { "branch": "main", "commit": "80487e4f7bfa11c2ef2a1b461963db019aad6a73" },
"noice.nvim": { "branch": "main", "commit": "92433164e2f7118d4122c7674c3834d9511722ba" },
"nui.nvim": { "branch": "main", "commit": "c0c8e347ceac53030f5c1ece1c5a5b6a17a25b32" },
"nvim-base16": { "branch": "master", "commit": "7e2243aef1b62cde443fc10f8baf018f672e2a85" },
"nvim-cmp": { "branch": "main", "commit": "51260c02a8ffded8e16162dcf41a23ec90cfba62" },
"nvim-lint": { "branch": "master", "commit": "7746f952827dabfb70194518c99c93d5651b8f19" },
"nvim-lspconfig": { "branch": "master", "commit": "b44737605807023d32e6310b87ba69f4dbf10e0e" },
"nvim-notify": { "branch": "master", "commit": "e4a2022f4fec2d5ebc79afa612f96d8b11c627b3" },
"nvim-spectre": { "branch": "master", "commit": "5c3474fbe1028844cfe5a9c238366da04c2e7551" },
"nvim-treesitter": { "branch": "master", "commit": "bef2c24e23d0da62a8542b1f08b1ac87ec43e93f" },
"nvim-treesitter-context": { "branch": "master", "commit": "2806d83e3965017382ce08792ee527e708fa1bd4" },
"nvim-treesitter-textobjects": { "branch": "master", "commit": "e69a504baf2951d52e1f1fbb05145d43f236cbf1" },
"nvim-ts-autotag": { "branch": "main", "commit": "6be1192965df35f94b8ea6d323354f7dc7a557e4" },
"nvim-ts-context-commentstring": { "branch": "main", "commit": "92e688f013c69f90c9bbd596019ec10235bc51de" },
"nvim-web-devicons": { "branch": "master", "commit": "5de460ca7595806044eced31e3c36c159a493857" },
"persistence.nvim": { "branch": "main", "commit": "ad538bfd5336f1335cdb6fd4e0b0eebfa6e12f32" },
"plenary.nvim": { "branch": "master", "commit": "50012918b2fc8357b87cff2a7f7f0446e47da174" },
"rust-tools.nvim": { "branch": "master", "commit": "0cc8adab23117783a0292a0c8a2fbed1005dc645" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" },
"telescope.nvim": { "branch": "master", "commit": "4522d7e3ea75ffddabdc39957168a8a7060b5df0" },
"todo-comments.nvim": { "branch": "main", "commit": "4a6737a8d70fe1ac55c64dfa47fcb189ca431872" },
"tokyonight.nvim": { "branch": "main", "commit": "f247ee700b569ed43f39320413a13ba9b0aef0db" },
"transparent.nvim": { "branch": "main", "commit": "3af6232c8d39d51062702e875ff6407c1eeb0391" },
"trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" },
"vim-illuminate": { "branch": "master", "commit": "3bd2ab64b5d63b29e05691e624927e5ebbf0fb86" },
"vim-startuptime": { "branch": "master", "commit": "454b3de856b7bd298700de33d79774ca9b9e3875" },
"which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" }
}

View file

@ -0,0 +1,3 @@
-- Autocmds are automatically loaded on the VeryLazy event
-- Default autocmds that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/autocmds.lua
-- Add any additional autocmds here

View file

@ -0,0 +1,3 @@
-- Keymaps are automatically loaded on the VeryLazy event
-- Default keymaps that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/keymaps.lua
-- Add any additional keymaps here

View file

@ -0,0 +1,48 @@
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
-- bootstrap lazy.nvim
-- stylua: ignore
vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", "--branch=stable", lazypath })
end
vim.opt.rtp:prepend(vim.env.LAZY or lazypath)
require("lazy").setup({
spec = {
-- add LazyVim and import its plugins
{ "LazyVim/LazyVim", import = "lazyvim.plugins" },
-- import any extras modules here
-- { import = "lazyvim.plugins.extras.lang.typescript" },
-- { import = "lazyvim.plugins.extras.lang.json" },
-- { import = "lazyvim.plugins.extras.ui.mini-animate" },
-- import/override with your plugins
{ import = "lazyvim.plugins.extras.lang.rust" },
{ import = "plugins" },
},
lockfile = "~/.system/programs/nvim/lazy-lock.json",
defaults = {
-- By default, only LazyVim plugins will be lazy-loaded. Your custom plugins will load during startup.
-- If you know what you're doing, you can set this to `true` to have all your custom plugins lazy-loaded by default.
lazy = false,
-- It's recommended to leave version=false for now, since a lot the plugin that support versioning,
-- have outdated releases, which may break your Neovim install.
version = false, -- always use the latest git commit
-- version = "*", -- try installing the latest stable version for plugins that support semver
},
install = { colorscheme = { "tokyonight", "habamax" } },
checker = { enabled = true }, -- automatically check for plugin updates
performance = {
rtp = {
-- disable some rtp plugins
disabled_plugins = {
"gzip",
-- "matchit",
-- "matchparen",
-- "netrwPlugin",
"tarPlugin",
"tohtml",
"tutor",
"zipPlugin",
},
},
},
})

View file

@ -0,0 +1,3 @@
-- Options are automatically loaded before lazy.nvim startup
-- Default options that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/options.lua
-- Add any additional options here

View file

@ -0,0 +1,16 @@
return {
{
"RRethy/nvim-base16",
},
{
"https://github.com/xiyaowong/transparent.nvim",
},
{
"LazyVim/LazyVim",
opts = {
--colorscheme = "base16-gruvbox-dark-soft",
colorscheme = "base16-catppuccin-frappe",
},
},
}

View file

@ -0,0 +1,266 @@
-- since this is just an example spec, don't actually load anything here and return an empty spec
-- stylua: ignore
if true then return {} end
-- every spec file under the "plugins" directory will be loaded automatically by lazy.nvim
--
-- In your plugin files, you can:
-- * add extra plugins
-- * disable/enabled LazyVim plugins
-- * override the configuration of LazyVim plugins
return {
-- add gruvbox
{ "ellisonleao/gruvbox.nvim" },
-- Configure LazyVim to load gruvbox
{
"LazyVim/LazyVim",
opts = {
colorscheme = "gruvbox",
},
},
-- change trouble config
{
"folke/trouble.nvim",
-- opts will be merged with the parent spec
opts = { use_diagnostic_signs = true },
},
-- disable trouble
{ "folke/trouble.nvim", enabled = false },
-- add symbols-outline
{
"simrat39/symbols-outline.nvim",
cmd = "SymbolsOutline",
keys = { { "<leader>cs", "<cmd>SymbolsOutline<cr>", desc = "Symbols Outline" } },
config = true,
},
-- override nvim-cmp and add cmp-emoji
{
"hrsh7th/nvim-cmp",
dependencies = { "hrsh7th/cmp-emoji" },
---@param opts cmp.ConfigSchema
opts = function(_, opts)
local cmp = require("cmp")
opts.sources = cmp.config.sources(vim.list_extend(opts.sources, { { name = "emoji" } }))
end,
},
-- change some telescope options and a keymap to browse plugin files
{
"nvim-telescope/telescope.nvim",
keys = {
-- add a keymap to browse plugin files
-- stylua: ignore
{
"<leader>fp",
function() require("telescope.builtin").find_files({ cwd = require("lazy.core.config").options.root }) end,
desc = "Find Plugin File",
},
},
-- change some options
opts = {
defaults = {
layout_strategy = "horizontal",
layout_config = { prompt_position = "top" },
sorting_strategy = "ascending",
winblend = 0,
},
},
},
-- add telescope-fzf-native
{
"telescope.nvim",
dependencies = {
"nvim-telescope/telescope-fzf-native.nvim",
build = "make",
config = function()
require("telescope").load_extension("fzf")
end,
},
},
-- add pyright to lspconfig
{
"neovim/nvim-lspconfig",
---@class PluginLspOpts
opts = {
---@type lspconfig.options
servers = {
-- pyright will be automatically installed with mason and loaded with lspconfig
pyright = {},
},
},
},
-- add tsserver and setup with typescript.nvim instead of lspconfig
{
"neovim/nvim-lspconfig",
dependencies = {
"jose-elias-alvarez/typescript.nvim",
init = function()
require("lazyvim.util").on_attach(function(_, buffer)
-- stylua: ignore
vim.keymap.set( "n", "<leader>co", "TypescriptOrganizeImports", { buffer = buffer, desc = "Organize Imports" })
vim.keymap.set("n", "<leader>cR", "TypescriptRenameFile", { desc = "Rename File", buffer = buffer })
end)
end,
},
---@class PluginLspOpts
opts = {
---@type lspconfig.options
servers = {
-- tsserver will be automatically installed with mason and loaded with lspconfig
tsserver = {},
},
-- you can do any additional lsp server setup here
-- return true if you don't want this server to be setup with lspconfig
---@type table<string, fun(server:string, opts:_.lspconfig.options):boolean?>
setup = {
-- example to setup with typescript.nvim
tsserver = function(_, opts)
require("typescript").setup({ server = opts })
return true
end,
-- Specify * to use this function as a fallback for any server
-- ["*"] = function(server, opts) end,
},
},
},
-- for typescript, LazyVim also includes extra specs to properly setup lspconfig,
-- treesitter, mason and typescript.nvim. So instead of the above, you can use:
{ import = "lazyvim.plugins.extras.lang.typescript" },
-- add more treesitter parsers
{
"nvim-treesitter/nvim-treesitter",
opts = {
ensure_installed = {
"bash",
"html",
"javascript",
"json",
"lua",
"markdown",
"markdown_inline",
"python",
"query",
"regex",
"tsx",
"typescript",
"vim",
"yaml",
},
},
},
-- since `vim.tbl_deep_extend`, can only merge tables and not lists, the code above
-- would overwrite `ensure_installed` with the new value.
-- If you'd rather extend the default config, use the code below instead:
{
"nvim-treesitter/nvim-treesitter",
opts = function(_, opts)
-- add tsx and treesitter
vim.list_extend(opts.ensure_installed, {
"tsx",
"typescript",
})
end,
},
-- the opts function can also be used to change the default opts:
{
"nvim-lualine/lualine.nvim",
event = "VeryLazy",
opts = function(_, opts)
table.insert(opts.sections.lualine_x, "😄")
end,
},
-- or you can return new options to override all the defaults
{
"nvim-lualine/lualine.nvim",
event = "VeryLazy",
opts = function()
return {
--[[add your custom lualine config here]]
}
end,
},
-- use mini.starter instead of alpha
{ import = "lazyvim.plugins.extras.ui.mini-starter" },
-- add jsonls and schemastore packages, and setup treesitter for json, json5 and jsonc
{ import = "lazyvim.plugins.extras.lang.json" },
-- add any tools you want to have installed below
{
"williamboman/mason.nvim",
opts = {
ensure_installed = {
"stylua",
"shellcheck",
"shfmt",
"flake8",
},
},
},
-- Use <tab> for completion and snippets (supertab)
-- first: disable default <tab> and <s-tab> behavior in LuaSnip
{
"L3MON4D3/LuaSnip",
keys = function()
return {}
end,
},
-- then: setup supertab in cmp
{
"hrsh7th/nvim-cmp",
dependencies = {
"hrsh7th/cmp-emoji",
},
---@param opts cmp.ConfigSchema
opts = function(_, opts)
local has_words_before = function()
unpack = unpack or table.unpack
local line, col = unpack(vim.api.nvim_win_get_cursor(0))
return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil
end
local luasnip = require("luasnip")
local cmp = require("cmp")
opts.mapping = vim.tbl_extend("force", opts.mapping, {
["<Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_next_item()
-- You could replace the expand_or_jumpable() calls with expand_or_locally_jumpable()
-- this way you will only jump inside the snippet region
elseif luasnip.expand_or_jumpable() then
luasnip.expand_or_jump()
elseif has_words_before() then
cmp.complete()
else
fallback()
end
end, { "i", "s" }),
["<S-Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_prev_item()
elseif luasnip.jumpable(-1) then
luasnip.jump(-1)
else
fallback()
end
end, { "i", "s" }),
})
end,
},
}

View file

@ -0,0 +1,4 @@
return {
{ "williamboman/mason-lspconfig.nvim", enabled = false },
{ "williamboman/mason.nvim", enabled = false },
}

View file

@ -0,0 +1,14 @@
return {
{
"nvim-neo-tree/neo-tree.nvim",
opts = {
filesystem = {
filtered_items = {
visible = true,
hide_dotfiles = false,
hide_gitignored = true,
},
},
}
}
}

View file

@ -0,0 +1,8 @@
return {
{
"rcarriga/nvim-notify",
opts = {
background_colour = "#000000",
},
},
}

View file

@ -0,0 +1,38 @@
return {
{
"nvim-treesitter/nvim-treesitter",
opts = {
ensure_installed = {
"c",
"javascript",
"json",
"lua",
"typescript",
"css",
"rust",
"yaml",
},
-- Install parsers synchronously (only applied to `ensure_installed`)
sync_install = false,
-- Automatically install missing parsers when entering buffer
-- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally
auto_install = true,
highlight = {
enable = true,
-- Setting this to true will run `:h syntax` and tree-sitter at the same time.
-- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).
-- Using this option may slow down your editor, and you may see some duplicate highlights.
-- Instead of true it can also be a list of languages
additional_vim_regex_highlighting = false,
},
indent = {
enable = true,
},
},
},
}

View file

@ -0,0 +1,52 @@
return {
{
"L3MON4D3/LuaSnip",
keys = function()
return {}
end,
},
{
"hrsh7th/nvim-cmp",
dependencies = {
"hrsh7th/cmp-emoji",
},
---@param opts cmp.ConfigSchema
opts = function(_, opts)
local has_words_before = function()
unpack = unpack or table.unpack
local line, col = unpack(vim.api.nvim_win_get_cursor(0))
return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil
end
local luasnip = require("luasnip")
local cmp = require("cmp")
opts.mapping = vim.tbl_extend("force", opts.mapping, {
["<Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
-- You could replace select_next_item() with confirm({ select = true }) to get VS Code autocompletion behavior
cmp.select_next_item()
-- You could replace the expand_or_jumpable() calls with expand_or_locally_jumpable()
-- this way you will only jump inside the snippet region
elseif luasnip.expand_or_jumpable() then
luasnip.expand_or_jump()
elseif has_words_before() then
cmp.complete()
else
fallback()
end
end, { "i", "s" }),
["<S-Tab>"] = cmp.mapping(function(fallback)
if cmp.visible() then
cmp.select_prev_item()
elseif luasnip.jumpable(-1) then
luasnip.jump(-1)
else
fallback()
end
end, { "i", "s" }),
})
end,
}
}

View file

@ -0,0 +1,12 @@
return {
{
"telescope.nvim",
dependencies = {
"nvim-telescope/telescope-fzf-native.nvim",
build = "make",
config = function()
require("telescope").load_extension("fzf")
end,
},
}
}

View file

@ -0,0 +1,3 @@
indent_type = "Spaces"
indent_width = 2
column_width = 120

16
programs/obs-studio.nix Normal file
View file

@ -0,0 +1,16 @@
{ pkgs, ... }:
{
programs.obs-studio =
{
enable = true;
plugins = with pkgs.obs-studio-plugins; [
input-overlay
obs-backgroundremoval
obs-pipewire-audio-capture
obs-vaapi
obs-vkcapture
wlrobs
];
};
}

View file

@ -0,0 +1,111 @@
* {
bg-col: #303446;
bg-col-light: #303446;
border-col: #303446;
selected-col: #303446;
blue: #8caaee;
fg-col: #c6d0f5;
fg-col2: #e78284;
grey: #737994;
width: 600;
font: "FantasqueSansM Nerd Font 14";
}
element-text, element-icon , mode-switcher {
background-color: inherit;
text-color: inherit;
}
window {
height: 360px;
border: 3px;
border-color: @border-col;
background-color: @bg-col;
}
mainbox {
background-color: @bg-col;
}
inputbar {
children: [prompt,entry];
background-color: @bg-col;
border-radius: 5px;
padding: 2px;
}
prompt {
background-color: @blue;
padding: 6px;
text-color: @bg-col;
border-radius: 3px;
margin: 20px 0px 0px 20px;
}
textbox-prompt-colon {
expand: false;
str: ":";
}
entry {
padding: 6px;
margin: 20px 0px 0px 10px;
text-color: @fg-col;
background-color: @bg-col;
}
listview {
border: 0px 0px 0px;
padding: 6px 0px 0px;
margin: 10px 0px 0px 20px;
columns: 2;
lines: 5;
background-color: @bg-col;
}
element {
padding: 5px;
background-color: @bg-col;
text-color: @fg-col ;
}
element-icon {
size: 25px;
}
element selected {
background-color: @selected-col ;
text-color: @fg-col2 ;
}
mode-switcher {
spacing: 0;
}
button {
padding: 10px;
background-color: @bg-col-light;
text-color: @grey;
vertical-align: 0.5;
horizontal-align: 0.5;
}
button selected {
background-color: @bg-col;
text-color: @blue;
}
message {
background-color: @bg-col-light;
margin: 2px;
padding: 2px;
border-radius: 5px;
}
textbox {
padding: 6px;
margin: 20px 0px 0px 20px;
text-color: @blue;
background-color: @bg-col-light;
}

28
programs/rofi/default.nix Normal file
View file

@ -0,0 +1,28 @@
{ pkgs, ... }:
{
programs.rofi = {
enable = true;
package = pkgs.rofi-wayland;
font = "FantasqueSansM Nerd Font";
extraConfig = {
disable-history = false;
display-Network = " 󰤨 Network";
display-drun = " Apps ";
display-run = " Run ";
display-window = " Window";
drun-display-format = "{icon} {name}";
hide-scrollbar = true;
icon-theme = "Oranchelo";
location = 0;
modi = "run,drun,window";
show-icons = true;
sidebar-mode = true;
terminal = "alacritty";
};
theme = ./catppuccin-frappe.rasi;
};
}

View file

@ -0,0 +1,149 @@
{ lib
, stdenv
, stdenvNoCC
, gcc13Stdenv
, fetchFromGitHub
, substituteAll
, makeWrapper
, makeDesktopItem
, copyDesktopItems
, electron
, pipewire
, libpulseaudio
, libicns
, jq
, moreutils
, nodePackages
, callPackage
}:
let
vencord = callPackage ./vencord-updated.nix {};
in
stdenv.mkDerivation rec {
pname = "vesktop";
version = "0.4.1";
src = fetchFromGitHub {
owner = "Vencord";
repo = "Vesktop";
rev = "v${version}";
hash = "sha256-jSGad3qMhAdiGdwomQO6BIyHIbKrGLRGniGrJN97gN8=";
};
pnpm-deps = stdenvNoCC.mkDerivation {
pname = "${pname}-pnpm-deps";
inherit src version patches ELECTRON_SKIP_BINARY_DOWNLOAD;
nativeBuildInputs = [
jq
moreutils
nodePackages.pnpm
];
# https://github.com/NixOS/nixpkgs/blob/763e59ffedb5c25774387bf99bc725df5df82d10/pkgs/applications/misc/pot/default.nix#L56
installPhase = ''
export HOME=$(mktemp -d)
pnpm config set store-dir $out
pnpm install --frozen-lockfile --ignore-script
rm -rf $out/v3/tmp
for f in $(find $out -name "*.json"); do
sed -i -E -e 's/"checkedAt":[0-9]+,//g' $f
jq --sort-keys . $f | sponge $f
done
'';
dontFixup = true;
outputHashMode = "recursive";
outputHash = "sha256-lTeL+8QujWzx4ys2T+G55NUP51c8i5lB1vAkUtzkJlA=";
};
nativeBuildInputs = [
copyDesktopItems
nodePackages.pnpm
nodePackages.nodejs
makeWrapper
];
patches = [
(substituteAll { inherit vencord; src = ./use_system_vencord.patch; })
];
ELECTRON_SKIP_BINARY_DOWNLOAD = 1;
preBuild = ''
export HOME=$(mktemp -d)
export STORE_PATH=$(mktemp -d)
cp -r ${pnpm-deps}/* "$STORE_PATH"
chmod -R +w "$STORE_PATH"
pnpm config set store-dir "$STORE_PATH"
pnpm install --offline --frozen-lockfile --ignore-script
patchShebangs node_modules/{*,.*}
'';
postBuild = ''
pnpm build
# using `pnpm exec` here apparently makes it ignore ELECTRON_SKIP_BINARY_DOWNLOAD
./node_modules/.bin/electron-builder \
--dir \
-c.electronDist=${electron}/libexec/electron \
-c.electronVersion=${electron.version}
'';
# this is consistent with other nixpkgs electron packages and upstream, as far as I am aware
# yes, upstream really packages it as "vesktop" but uses "vencorddesktop" file names
installPhase =
let
# this is mainly required for venmic
libPath = lib.makeLibraryPath [
libpulseaudio
pipewire
gcc13Stdenv.cc.cc.lib
];
in
''
runHook preInstall
mkdir -p $out/opt/Vesktop/resources
cp dist/linux-unpacked/resources/app.asar $out/opt/Vesktop/resources
pushd build
${libicns}/bin/icns2png -x icon.icns
for file in icon_*x32.png; do
file_suffix=''${file//icon_}
install -Dm0644 $file $out/share/icons/hicolor/''${file_suffix//x32.png}/apps/vencorddesktop.png
done
makeWrapper ${electron}/bin/electron $out/bin/vencorddesktop \
--prefix LD_LIBRARY_PATH : ${libPath} \
--add-flags $out/opt/Vesktop/resources/app.asar \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
runHook postInstall
'';
desktopItems = [
(makeDesktopItem {
name = "vencorddesktop";
desktopName = "Vesktop";
exec = "vencorddesktop %U";
icon = "vencorddesktop";
startupWMClass = "VencordDesktop";
genericName = "Internet Messenger";
keywords = [ "discord" "vencord" "electron" "chat" ];
})
];
meta = with lib; {
description = "An alternate client for Discord with Vencord built-in";
homepage = "https://github.com/Vencord/Vesktop";
license = licenses.gpl3Only;
maintainers = with maintainers; [ getchoo Scrumplex vgskye ];
platforms = [ "x86_64-linux" "aarch64-linux" ];
mainProgram = "vencorddesktop";
broken = stdenv.hostPlatform.isAarch64;
};
}

5863
programs/vesktop/package-lock.json generated Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,14 @@
diff --git a/src/main/constants.ts b/src/main/constants.ts
index d5c5fa6..a1b32f1 100644
--- a/src/main/constants.ts
+++ b/src/main/constants.ts
@@ -16,7 +16,7 @@ export const VENCORD_THEMES_DIR = join(DATA_DIR, "themes");
// needs to be inline require because of circular dependency
// as otherwise "DATA_DIR" (which is used by ./settings) will be uninitialised
export const VENCORD_FILES_DIR =
- (require("./settings") as typeof import("./settings")).Settings.store.vencordDir || join(DATA_DIR, "vencordDist");
+ (require("./settings") as typeof import("./settings")).Settings.store.vencordDir || "@vencord@";
export const USER_AGENT = `Vesktop/${app.getVersion()} (https://github.com/Vencord/Vesktop)`;

View file

@ -0,0 +1,65 @@
{ buildNpmPackage
, fetchFromGitHub
, lib
, esbuild
, buildWebExtension ? false
}:
let
version = "1.6.0";
gitHash = "ffe6bb1";
in
buildNpmPackage rec {
pname = "vencord";
inherit version;
src = fetchFromGitHub {
owner = "Vendicated";
repo = "Vencord";
rev = "v${version}";
hash = "sha256-t4+8ybPzqcCtTSukBBgvbD7HiKG4K51WPVnJg0RQbs8=";
};
ESBUILD_BINARY_PATH = lib.getExe (esbuild.overrideAttrs (final: _: {
version = "0.15.18";
src = fetchFromGitHub {
owner = "evanw";
repo = "esbuild";
rev = "v${final.version}";
hash = "sha256-b9R1ML+pgRg9j2yrkQmBulPuLHYLUQvW+WTyR/Cq6zE=";
};
vendorHash = "sha256-+BfxCyg0KkDQpHt/wycy/8CTG6YBA/VJvJFhhzUnSiQ=";
}));
# Supresses an error about esbuild's version.
npmRebuildFlags = [ "|| true" ];
makeCacheWritable = true;
npmDepsHash = "sha256-H2f6xdAa7fNETbQhIv+InCB7+O4nq0bx+RILjGjqXdY=";
npmFlags = [ "--legacy-peer-deps" ];
npmBuildScript = if buildWebExtension then "buildWeb" else "build";
npmBuildFlags = [ "--" "--standalone" "--disable-updater" ];
prePatch = ''
cp ${./package-lock.json} ./package-lock.json
chmod +w ./package-lock.json
'';
VENCORD_HASH = gitHash;
VENCORD_REMOTE = "${src.owner}/${src.repo}";
installPhase =
if buildWebExtension then ''
cp -r dist/chromium-unpacked/ $out
'' else ''
cp -r dist/ $out
'';
passthru.updateScript = ./update.sh;
meta = with lib; {
description = "Vencord web extension";
homepage = "https://github.com/Vendicated/Vencord";
license = licenses.gpl3Only;
maintainers = with maintainers; [ FlafyDev fwam NotAShelf Scrumplex ];
};
}

485
programs/waybar.nix Normal file
View file

@ -0,0 +1,485 @@
{ pkgs, ... }:
{
programs.waybar = {
enable = true;
package = (pkgs.waybar.overrideAttrs (oldAttrs: {
mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ];
})
);
settings = {
mainBar = {
layer = "top";
position = "top";
modules-left = [
"hyprland/submap"
"hyprland/workspaces"
"custom/arrow10"
"hyprland/window"
];
modules-right = [
"custom/arrow9"
"pulseaudio"
"custom/arrow8"
"network"
"custom/arrow7"
"memory"
"custom/arrow6"
"cpu"
"custom/arrow5"
"temperature"
"custom/arrow4"
"battery"
"custom/arrow3"
"hyprland/language"
"custom/arrow2"
"tray"
"clock#date"
"custom/arrow1"
"clock#time"
];
# Module configuration
battery = {
interval = 10;
states = {
warning = 30;
critical = 15;
};
format-time = "{H}:{M:02}";
format = "{icon} {capacity}% ({time})";
format-charging = " {capacity}% ({time})";
format-charging-full = " {capacity}%";
format-full = "{icon} {capacity}%";
format-alt = "{icon} {power}W";
format-icons = [
""
""
""
""
""
];
tooltip = false;
};
"clock#time" = {
interval = 10;
format = "{:%H:%M}";
tooltip = false;
};
"clock#date" = {
interval = 20;
format = "{:%e %b %Y}";
tooltip = false;
#"tooltip-format" = "{:%e %B %Y}"
};
"cpu" = {
interval = 5;
tooltip = false;
format = " {usage}%";
format-alt = " {load}";
states = {
warning = 70;
critical = 90;
};
};
"hyprland/language" = {
format = " {}";
min-length = 5;
#"on-click" = "swaymsg 'input * xkb_switch_layout next'";
tooltip = false;
};
memory = {
interval = 5;
format = "🧠 {used:0.1f}G/{total:0.1f}G";
states = {
"warning" = 70;
"critical" = 90;
};
tooltip = false;
};
network = {
interval = 5;
format-wifi = " {essid} ({signalStrength}%)";
format-ethernet = " {ifname}";
format-disconnected = "No connection";
format-alt = " {ipaddr}/{cidr}";
tooltip = false;
};
"hyprland/submap" = {
format = "{}";
tooltip = false;
};
"hyprland/window" = {
format = "{}";
max-length = 30;
tooltip = false;
};
pulseaudio = {
format = "{icon} {volume}%";
format-bluetooth = "{icon} {volume}%";
format-muted = "";
format-icons = {
headphone = "";
hands-free = "";
headset = "";
phone = "";
portable = "";
car = "";
default = [
""
""
];
};
scroll-step = 1;
on-click = "pactl set-sink-mute @DEFAULT_SINK@ toggle";
tooltip = false;
};
temperature = {
critical-threshold = 90;
interval = 5;
format = "{icon} {temperatureC}°";
format-icons = [
""
""
""
""
""
];
tooltip = false;
};
tray = {
icon-size = 18;
#"spacing" = 10
};
"custom/arrow1" = {
format = "";
tooltip = false;
};
"custom/arrow2" = {
format = "";
tooltip = false;
};
"custom/arrow3" = {
format = "";
tooltip = false;
};
"custom/arrow4" = {
format = "";
tooltip = false;
};
"custom/arrow5" = {
format = "";
tooltip = false;
};
"custom/arrow6" = {
format = "";
tooltip = false;
};
"custom/arrow7" = {
format = "";
tooltip = false;
};
"custom/arrow8" = {
format = "";
tooltip = false;
};
"custom/arrow9" = {
format = "";
tooltip = false;
};
"custom/arrow10" = {
format = "";
tooltip = false;
};
};
};
style = ''
/* Keyframes */
@keyframes blink-critical {
to {
/*color: @white;*/
background-color: @critical;
}
}
/* Styles */
/* Colors (gruvbox) */
@define-color black #282828;
@define-color red #cc241d;
@define-color green #98971a;
@define-color yellow #d79921;
@define-color blue #458588;
@define-color purple #b16286;
@define-color aqua #689d6a;
@define-color gray #a89984;
@define-color brgray #928374;
@define-color brred #fb4934;
@define-color brgreen #b8bb26;
@define-color bryellow #fabd2f;
@define-color brblue #83a598;
@define-color brpurple #d3869b;
@define-color braqua #8ec07c;
@define-color white #ebdbb2;
@define-color bg2 #504945;
@define-color warning @bryellow;
@define-color critical @red;
@define-color mode @black;
@define-color unfocused @bg2;
@define-color focused @braqua;
@define-color inactive @purple;
@define-color sound @brpurple;
@define-color network @purple;
@define-color memory @braqua;
@define-color cpu @green;
@define-color temp @brgreen;
@define-color layout @bryellow;
@define-color battery @aqua;
@define-color date @black;
@define-color time @white;
/* Reset all styles */
* {
border: none;
border-radius: 0;
min-height: 0;
margin: 0;
padding: 0;
box-shadow: none;
text-shadow: none;
icon-shadow: none;
}
/* The whole bar */
#waybar {
background: rgba(40, 40, 40, 0.8784313725); /* #282828e0 */
color: @white;
font-family: JetBrains Mono, Siji;
font-size: 10pt;
/*font-weight: bold;*/
}
/* Each module */
#battery,
#clock,
#cpu,
#language,
#memory,
#mode,
#network,
#pulseaudio,
#temperature,
#tray,
#backlight,
#idle_inhibitor,
#disk,
#user,
#mpris {
padding-left: 8pt;
padding-right: 8pt;
}
/* Each critical module */
#mode,
#memory.critical,
#cpu.critical,
#temperature.critical,
#battery.critical.discharging {
animation-timing-function: linear;
animation-iteration-count: infinite;
animation-direction: alternate;
animation-name: blink-critical;
animation-duration: 1s;
}
/* Each warning */
#network.disconnected,
#memory.warning,
#cpu.warning,
#temperature.warning,
#battery.warning.discharging {
color: @warning;
}
/* And now modules themselves in their respective order */
/* Current sway mode (resize etc) */
#mode {
color: @white;
background: @mode;
}
/* Workspaces stuff */
#workspaces button {
/*font-weight: bold;*/
padding-left: 2pt;
padding-right: 2pt;
color: @white;
background: @unfocused;
}
/* Inactive (on unfocused output) */
#workspaces button.visible {
color: @white;
background: @inactive;
}
/* Active (on focused output) */
#workspaces button.focused {
color: @black;
background: @focused;
}
/* Contains an urgent window */
#workspaces button.urgent {
color: @black;
background: @warning;
}
/* Style when cursor is on the button */
#workspaces button:hover {
background: @black;
color: @white;
}
#window {
margin-right: 35pt;
margin-left: 35pt;
}
#pulseaudio {
background: @sound;
color: @black;
}
#network {
background: @network;
color: @white;
}
#memory {
background: @memory;
color: @black;
}
#cpu {
background: @cpu;
color: @white;
}
#temperature {
background: @temp;
color: @black;
}
#language {
background: @layout;
color: @black;
}
#battery {
background: @battery;
color: @white;
}
#tray {
background: @date;
}
#clock.date {
background: @date;
color: @white;
}
#clock.time {
background: @time;
color: @black;
}
#custom-arrow1 {
font-size: 11pt;
color: @time;
background: @date;
}
#custom-arrow2 {
font-size: 11pt;
color: @date;
background: @layout;
}
#custom-arrow3 {
font-size: 11pt;
color: @layout;
background: @battery;
}
#custom-arrow4 {
font-size: 11pt;
color: @battery;
background: @temp;
}
#custom-arrow5 {
font-size: 11pt;
color: @temp;
background: @cpu;
}
#custom-arrow6 {
font-size: 11pt;
color: @cpu;
background: @memory;
}
#custom-arrow7 {
font-size: 11pt;
color: @memory;
background: @network;
}
#custom-arrow8 {
font-size: 11pt;
color: @network;
background: @sound;
}
#custom-arrow9 {
font-size: 11pt;
color: @sound;
background: transparent;
}
#custom-arrow10 {
font-size: 11pt;
color: @unfocused;
background: transparent;
}
'';
};
}

View file

@ -0,0 +1,8 @@
{ ... }:
{
programs.wezterm = {
enable = true;
extraConfig = builtins.readFile ./wezterm.lua;
};
}

View file

@ -0,0 +1,16 @@
local wezterm = require("wezterm")
return {
color_scheme = "Catppuccin Frappe",
font = wezterm.font("FantasqueSansM Nerd Font"),
font_size = 13,
hide_tab_bar_if_only_one_tab = true,
hide_mouse_cursor_when_typing = false,
window_background_opacity = 0.88,
window_padding = {
left = 18,
right = 18,
top = 18,
bottom = 18,
},
}

18
scripts/create_feedback_sink.sh Executable file
View file

@ -0,0 +1,18 @@
#!/bin/sh
#
# Load sinks
#
pactl load-module module-null-sink formats=pcm,float32le sink_name=output sink_properties=device.description="Output"
pactl load-module module-null-sink formats=pcm,float32le sink_name=applications sink_properties=device.description="Applications"
#
# Loopback audio to the correct places
#
# Application audio forwarded to microphone
pactl load-module module-loopback latency_msec=25 source=applications.monitor sink=output
# Microphone
pactl load-module module-loopback latency_msec=25 source=rnnoise_source sink=output
# Application audio forwarded to me
pactl load-module module-loopback latency_msec=25 source=applications.monitor sink=alsa_output.usb-Burr-Brown_from_TI_USB_Audio_CODEC-00.pro-output-0

View file

@ -0,0 +1,4 @@
#!/bin/sh
pactl unload-module module-loopback
pactl unload-module module-null-sink

6
scripts/hyprland/screenshot.sh Executable file
View file

@ -0,0 +1,6 @@
#!/bin/sh
FILE_PATH="/mnt/internal/personal/screenshots/$(date +'%Y-%m-%d_%H-%M-%S').png"
grim -t png $FILE_PATH
wl-copy <$FILE_PATH

View file

@ -0,0 +1,6 @@
#!/bin/sh
FILE_PATH="/mnt/internal/personal/screenshots/$(date +'%Y-%m-%d_%H-%M-%S').png"
grim -t png -g "$(slurp)" $FILE_PATH
wl-copy <$FILE_PATH

View file

@ -0,0 +1,37 @@
#!/bin/sh
#
# Start waybar.
#
waybar &
#
## Start wallpaper daemon and set one.
#
OUTPUT_1="DP-3"
IMAGE_1="/mnt/internal/personal/wallpapers/wallhaven-g71xoe.jpg"
OUTPUT_2="DP-2"
IMAGE_2="/mnt/internal/personal/wallpapers/wallhaven-3zjexv.jpg"
function load_wallpapers() {
swww img -t any --transition-bezier 0.0,0.0,1.0,1.0 --transition-duration .8 --transition-step 255 --transition-fps 60 -o $OUTPUT_1 $IMAGE_1;
swww img -t any --transition-bezier 0.0,0.0,1.0,1.0 --transition-duration .8 --transition-step 255 --transition-fps 60 -o $OUTPUT_2 $IMAGE_2
}
if ! swww query; then
swww init &
fi
load_wallpapers &
#
# Start notification daemon.
#
mako &
#
# Start authentication polkit.
#
/nix/store/$(ls -la /nix/store | rg '^d.*polkit-kde-agent.*\d$' | awk '{print $9}')/libexec/polkit-kde-authentication-agent-1 &

8
scripts/steam/launch.sh Executable file
View file

@ -0,0 +1,8 @@
#!/bin/sh
export AMD_VULKAN_ICD="RADV"
export DXVK_ASYNC=1
export DXVK_STATE_CACHE=1
export MANGOHUD=1
export RADV_PERFTEST="gpl"
gamemoderun "$@"

View file

@ -0,0 +1,8 @@
#!/bin/sh
export AMD_VULKAN_ICD="RADV"
export DXVK_ASYNC=1
export DXVK_STATE_CACHE=1
export MANGOHUD=1
export RADV_PERFTEST="gpl"
gamescope -w 1280 -h 720 -W 1920 -H 1080 -f -- gamemoderun "$@"

View file

@ -0,0 +1,10 @@
#!/bin/sh
export AMD_VULKAN_ICD="RADV"
export DXVK_ASYNC=1
export DXVK_STATE_CACHE=1
export MANGOHUD=1
export RADV_PERFTEST="rt,gpl"
export VKD3D_CONFIG="dxr11"
export __GL_SHADER_DISK_CACHE_SKIP_CLEANUP=1
gamemoderun "$@" -dx12

18
services/caddy.nix Normal file
View file

@ -0,0 +1,18 @@
{ ... }:
{
services.caddy = {
enable = true;
virtualHosts."thewizard.link".extraConfig = ''
redir https://github.com/wizardlink/
header Strict-Transport-Security "max-age=63072000; includeSubDomains"
'';
virtualHosts."jellyfin.thewizard.link".extraConfig = ''
encode gzip
reverse_proxy 127.0.0.1:8096 {
flush_interval -1
}
'';
};
}

18
services/jellyfin.nix Normal file
View file

@ -0,0 +1,18 @@
{ pkgs, ... }:
{
services.jellyfin = {
enable = true;
openFirewall = true;
package = pkgs.jellyfin.override {
jellyfin-web = pkgs.jellyfin-web.overrideAttrs (oldAttrs: {
patches = [
(pkgs.fetchpatch {
url = "https://github.com/jellyfin/jellyfin-web/compare/v${oldAttrs.version}...ConfusedPolarBear:jellyfin-web:intros.diff";
hash = "sha256-qm4N4wMUFc4I53oQJUK1Six0cahVYz3J+FgO2vvSvXM=";
})
];
});
};
};
}

View file

@ -0,0 +1,37 @@
{
fetchFromGitHub,
flavor ? "Mocha",
lib,
stdenvNoCC
}: let
validFlavors = ["Frappe" "Latte" "Macchiato" "Mocha"];
pname = "catppucin-qt5ct";
in
lib.checkListOfEnum "${pname}: flavors" validFlavors [ flavor ]
stdenvNoCC.mkDerivation {
inherit pname;
version = "unstable-2023-10-24";
src = fetchFromGitHub {
owner = "catppuccin";
repo = "qt5ct";
rev = "89ee948e72386b816c7dad72099855fb0d46d41e";
sha256 = "sha256-t/uyK0X7qt6qxrScmkTU2TvcVJH97hSQuF0yyvSO/qQ=";
};
nativeBuildInputs = [ ];
buildInputs = [ ];
postPatch = ''
export HOME=$(mktemp -d)
cp -r themes/* $HOME/.config/qt5ct/colors/
'';
meta = with lib; {
description = "Catppuccin for qt5ct";
homepage = "https://github.com/catppuccin/qt5ct";
license = licenses.mit;
maintainers = with maintainers; [ ];
};
}

View file

@ -0,0 +1,4 @@
[ColorScheme]
active_colors=#ffc6d0f5, #ff292c3c, #ffa5adce, #ff949cbb, #ff51576d, #ff737994, #ffc6d0f5, #ffc6d0f5, #ffc6d0f5, #ff303446, #ff292c3c, #ff838ba7, #ff8caaee, #ff303446, #ff8caaee, #ffe78284, #ff303446, #ffc6d0f5, #ff232634, #ffc6d0f5, #80838ba7
disabled_colors=#ffa5adce, #ff292c3c, #ffa5adce, #ff949cbb, #ff51576d, #ff737994, #ffa5adce, #ffa5adce, #ffa5adce, #ff303446, #ff292c3c, #ff838ba7, #ff626880, #ffb5bfe2, #ff8caaee, #ffe78284, #ff303446, #ffc6d0f5, #ff232634, #ffc6d0f5, #80838ba7
inactive_colors=#ffc6d0f5, #ff292c3c, #ffa5adce, #ff949cbb, #ff51576d, #ff737994, #ffc6d0f5, #ffc6d0f5, #ffc6d0f5, #ff303446, #ff292c3c, #ff838ba7, #ff414559, #ffa5adcb, #ff8caaee, #ffe78284, #ff303446, #ffc6d0f5, #ff232634, #ffc6d0f5, #80838ba7

View file

@ -0,0 +1,4 @@
[ColorScheme]
active_colors=#ff4c4f69, #ffe6e9ef, #ff6c6f85, #ff7c7f93, #ffbcc0cc, #ff9ca0b0, #ff4c4f69, #ff4c4f69, #ff4c4f69, #ffeff1f5, #ffe6e9ef, #ff8c8fa1, #ff1e66f5, #ffeff1f5, #ff7287fd, #ffe64553, #ffeff1f5, #ff4c4f69, #ffdce0e8, #ff4c4f69, #808c8fa1
disabled_colors=#ff6c6f85, #ffe6e9ef, #ff6c6f85, #ff7c7f93, #ffbcc0cc, #ff9ca0b0, #ff6c6f85, #ff6c6f85, #ff6c6f85, #ffeff1f5, #ffe6e9ef, #ff8c8fa1, #ff9ca0b0, #ff5c5f77, #ff7287fd, #ffe64553, #ffeff1f5, #ff4c4f69, #ffdce0e8, #ff4c4f69, #808c8fa1
inactive_colors=#ff4c4f69, #ffe6e9ef, #ff6c6f85, #ff7c7f93, #ffbcc0cc, #ff9ca0b0, #ff4c4f69, #ff4c4f69, #ff4c4f69, #ffeff1f5, #ffe6e9ef, #ff8c8fa1, #ffccd0da, #ff6c6f85, #ff7287fd, #ffe64553, #ffeff1f5, #ff4c4f69, #ffdce0e8, #ff4c4f69, #808c8fa1

View file

@ -0,0 +1,4 @@
[ColorScheme]
active_colors=#ffcad3f5, #ff1e2030, #ffa5adcb, #ff939ab7, #ff494d64, #ff6e738d, #ffcad3f5, #ffcad3f5, #ffcad3f5, #ff24273a, #ff1e2030, #ff8087a2, #ff8aadf4, #ff24273a, #ff8aadf4, #ffed8796, #ff24273a, #ffcad3f5, #ff181926, #ffcad3f5, #808087a2
disabled_colors=#ffa5adcb, #ff1e2030, #ffa5adcb, #ff939ab7, #ff494d64, #ff6e738d, #ffa5adcb, #ffa5adcb, #ffa5adcb, #ff24273a, #ff1e2030, #ff8087a2, #ff8aadf4, #ff494d64, #ff8aadf4, #ffed8796, #ff24273a, #ffcad3f5, #ff181926, #ffcad3f5, #808087a2
inactive_colors=#ffcdd6f4, #ff1e2030, #ffa5adcb, #ff939ab7, #ff494d64, #ff6e738d, #ffcad3f5, #ffcad3f5, #ffcad3f5, #ff24273a, #ff1e2030, #ff8087a2, #ff8aadf4, #ffa5adcb, #ff8aadf4, #ffed8796, #ff24273a, #ffcad3f5, #ff181926, #ffcad3f5, #808087a2

View file

@ -0,0 +1,4 @@
[ColorScheme]
active_colors=#ffcdd6f4, #ff1e1e2e, #ffa6adc8, #ff9399b2, #ff45475a, #ff6c7086, #ffcdd6f4, #ffcdd6f4, #ffcdd6f4, #ff1e1e2e, #ff181825, #ff7f849c, #ff89b4fa, #ff1e1e2e, #ff89b4fa, #fff38ba8, #ff1e1e2e, #ffcdd6f4, #ff11111b, #ffcdd6f4, #807f849c
disabled_colors=#ffa6adc8, #ff1e1e2e, #ffa6adc8, #ff9399b2, #ff45475a, #ff6c7086, #ffa6adc8, #ffa6adc8, #ffa6adc8, #ff1e1e2e, #ff11111b, #ff7f849c, #ff89b4fa, #ff45475a, #ff89b4fa, #fff38ba8, #ff1e1e2e, #ffcdd6f4, #ff11111b, #ffcdd6f4, #807f849c
inactive_colors=#ffcdd6f4, #ff1e1e2e, #ffa6adc8, #ff9399b2, #ff45475a, #ff6c7086, #ffcdd6f4, #ffcdd6f4, #ffcdd6f4, #ff1e1e2e, #ff181825, #ff7f849c, #ff89b4fa, #ffa6adc8, #ff89b4fa, #fff38ba8, #ff1e1e2e, #ffcdd6f4, #ff11111b, #ffcdd6f4, #807f849c

26
theming/sddm.nix Normal file
View file

@ -0,0 +1,26 @@
{ pkgs }:
let
imgLink = "https://w.wallhaven.cc/full/1p/wallhaven-1p398w.jpg";
image = pkgs.fetchurl {
url = imgLink;
sha256 = "5347bc5a114db8afe9d189682a75565e8d0bc46e003f714879d6957729224335";
};
in
pkgs.stdenv.mkDerivation {
name = "sddm-theme";
src = pkgs.fetchFromGitHub {
owner = "MarianArlt";
repo = "sddm-sugar-dark";
rev = "ceb2c455663429be03ba62d9f898c571650ef7fe";
sha256 = "0153z1kylbhc9d12nxy9vpn0spxgrhgy36wy37pk6ysq7akaqlvy";
};
installPhase = ''
mkdir -p $out
cp -R ./* $out/
cd $out/
rm Background.jpg
cp -r ${image} $out/Background.jpg
'';
}