Added: Stuff
This commit is contained in:
		
							
								
								
									
										21
									
								
								home/programs/browsers.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								home/programs/browsers.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,21 @@
 | 
			
		||||
{
 | 
			
		||||
  pkgs,
 | 
			
		||||
  config,
 | 
			
		||||
  username,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  programs = {
 | 
			
		||||
    chromium = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      commandLineArgs = ["--enable-features=TouchpadOverscrollHistoryNavigation"];
 | 
			
		||||
      extensions = [
 | 
			
		||||
        # {id = "";}  // extension id, query from chrome web store
 | 
			
		||||
      ];
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    firefox = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      profiles.${username} = {};
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										62
									
								
								home/programs/common.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										62
									
								
								home/programs/common.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,62 @@
 | 
			
		||||
{
 | 
			
		||||
  lib,
 | 
			
		||||
  pkgs,
 | 
			
		||||
  catppuccin-bat,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  home.packages = with pkgs; [
 | 
			
		||||
    # productivity
 | 
			
		||||
    obsidian
 | 
			
		||||
 | 
			
		||||
    # docker
 | 
			
		||||
    docker-compose
 | 
			
		||||
 | 
			
		||||
  ];
 | 
			
		||||
 | 
			
		||||
  programs = {
 | 
			
		||||
    tmux = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      clock24 = true;
 | 
			
		||||
      keyMode = "vi";
 | 
			
		||||
      extraConfig = "mouse on";
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    bat = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      config = {
 | 
			
		||||
        pager = "less -FR";
 | 
			
		||||
        theme = "catppuccin-mocha";
 | 
			
		||||
      };
 | 
			
		||||
      themes = {
 | 
			
		||||
        # https://raw.githubusercontent.com/catppuccin/bat/main/Catppuccin-mocha.tmTheme
 | 
			
		||||
        catppuccin-mocha = {
 | 
			
		||||
          src = catppuccin-bat;
 | 
			
		||||
          file = "Catppuccin-mocha.tmTheme";
 | 
			
		||||
        };
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    btop.enable = true; # replacement of htop/nmon
 | 
			
		||||
    eza.enable = true; # A modern replacement for ‘ls’
 | 
			
		||||
    jq.enable = true; # A lightweight and flexible command-line JSON processor
 | 
			
		||||
    ssh.enable = true;
 | 
			
		||||
    aria2.enable = true;
 | 
			
		||||
 | 
			
		||||
    skim = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      enableZshIntegration = true;
 | 
			
		||||
      defaultCommand = "rg --files --hidden";
 | 
			
		||||
      changeDirWidgetOptions = [
 | 
			
		||||
        "--preview 'exa --icons --git --color always -T -L 3 {} | head -200'"
 | 
			
		||||
        "--exact"
 | 
			
		||||
      ];
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  services = {
 | 
			
		||||
    #syncthing.enable = true;
 | 
			
		||||
 | 
			
		||||
    # auto mount usb drives
 | 
			
		||||
    udiskie.enable = true;
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										9
									
								
								home/programs/default.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								home/programs/default.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,9 @@
 | 
			
		||||
{
 | 
			
		||||
  imports = [
 | 
			
		||||
    ./browsers.nix
 | 
			
		||||
    ./common.nix
 | 
			
		||||
    ./git.nix
 | 
			
		||||
    ./media.nix
 | 
			
		||||
    ./xdg.nix
 | 
			
		||||
  ];
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										12
									
								
								home/programs/git.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								home/programs/git.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
			
		||||
{
 | 
			
		||||
  pkgs,
 | 
			
		||||
  ...
 | 
			
		||||
}: {
 | 
			
		||||
  home.packages = [pkgs.gh];
 | 
			
		||||
 | 
			
		||||
  programs.git = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
 | 
			
		||||
    # ... Other options ...
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										33
									
								
								home/programs/media.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								home/programs/media.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
			
		||||
{
 | 
			
		||||
  pkgs,
 | 
			
		||||
  config,
 | 
			
		||||
  ...
 | 
			
		||||
}:
 | 
			
		||||
# media - control and enjoy audio/video
 | 
			
		||||
{
 | 
			
		||||
  # imports = [
 | 
			
		||||
  # ];
 | 
			
		||||
 | 
			
		||||
  home.packages = with pkgs; [
 | 
			
		||||
    # audio control
 | 
			
		||||
    pavucontrol
 | 
			
		||||
    playerctl
 | 
			
		||||
    pulsemixer
 | 
			
		||||
    # images
 | 
			
		||||
    imv
 | 
			
		||||
  ];
 | 
			
		||||
 | 
			
		||||
  programs = {
 | 
			
		||||
    mpv = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      defaultProfiles = ["gpu-hq"];
 | 
			
		||||
      scripts = [pkgs.mpvScripts.mpris];
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    obs-studio.enable = true;
 | 
			
		||||
  };
 | 
			
		||||
 | 
			
		||||
  services = {
 | 
			
		||||
    playerctld.enable = true;
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										47
									
								
								home/programs/xdg.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										47
									
								
								home/programs/xdg.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,47 @@
 | 
			
		||||
{config, ...}: let
 | 
			
		||||
  browser = ["firefox.desktop"];
 | 
			
		||||
 | 
			
		||||
  # XDG MIME types
 | 
			
		||||
  associations = {
 | 
			
		||||
    "application/x-extension-htm" = browser;
 | 
			
		||||
    "application/x-extension-html" = browser;
 | 
			
		||||
    "application/x-extension-shtml" = browser;
 | 
			
		||||
    "application/x-extension-xht" = browser;
 | 
			
		||||
    "application/x-extension-xhtml" = browser;
 | 
			
		||||
    "application/xhtml+xml" = browser;
 | 
			
		||||
    "text/html" = browser;
 | 
			
		||||
    "x-scheme-handler/about" = browser;
 | 
			
		||||
    "x-scheme-handler/chrome" = ["chromium-browser.desktop"];
 | 
			
		||||
    "x-scheme-handler/ftp" = browser;
 | 
			
		||||
    "x-scheme-handler/http" = browser;
 | 
			
		||||
    "x-scheme-handler/https" = browser;
 | 
			
		||||
    "x-scheme-handler/unknown" = browser;
 | 
			
		||||
 | 
			
		||||
    "audio/*" = ["mpv.desktop"];
 | 
			
		||||
    "video/*" = ["mpv.dekstop"];
 | 
			
		||||
    "image/*" = ["imv.desktop"];
 | 
			
		||||
    "application/json" = browser;
 | 
			
		||||
    "application/pdf" = ["org.pwmt.zathura.desktop.desktop"];
 | 
			
		||||
    "x-scheme-handler/discord" = ["discordcanary.desktop"];
 | 
			
		||||
    "x-scheme-handler/spotify" = ["spotify.desktop"];
 | 
			
		||||
    "x-scheme-handler/tg" = ["telegramdesktop.desktop"];
 | 
			
		||||
  };
 | 
			
		||||
in {
 | 
			
		||||
  xdg = {
 | 
			
		||||
    enable = true;
 | 
			
		||||
    cacheHome = config.home.homeDirectory + "/.local/cache";
 | 
			
		||||
 | 
			
		||||
    mimeApps = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      defaultApplications = associations;
 | 
			
		||||
    };
 | 
			
		||||
 | 
			
		||||
    userDirs = {
 | 
			
		||||
      enable = true;
 | 
			
		||||
      createDirectories = true;
 | 
			
		||||
      extraConfig = {
 | 
			
		||||
        XDG_SCREENSHOTS_DIR = "${config.xdg.userDirs.pictures}/Screenshots";
 | 
			
		||||
      };
 | 
			
		||||
    };
 | 
			
		||||
  };
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user