refactor(flake-parts): initial flake-parts configuration
This commit is contained in:
		
							parent
							
								
									8f67be9e68
								
							
						
					
					
						commit
						5603001d65
					
				
					 230 changed files with 380 additions and 717 deletions
				
			
		
							
								
								
									
										45
									
								
								inputs/home/profile/base/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										45
									
								
								inputs/home/profile/base/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,45 @@ | |||
| { lib, config, ... }: | ||||
| let | ||||
|   cfg = config.profiles.base; | ||||
|   inherit (lib) mkDefault; | ||||
| in | ||||
| { | ||||
|   imports = [ | ||||
|     ../../modules | ||||
|   ]; | ||||
| 
 | ||||
|   config = lib.mkIf cfg.enable { | ||||
| 
 | ||||
|     systemd.user.startServices = mkDefault "sd-switch"; | ||||
| 
 | ||||
|     homeModules = { | ||||
|       config = { | ||||
|         # nix.enable = true; | ||||
|         # nixColors.enable = true; | ||||
|         home.enable = true; | ||||
|         userDirs.enable = true; | ||||
|         mimeApps.enable = true; | ||||
|       }; | ||||
| 
 | ||||
|       console = { | ||||
|         editor.helix = { | ||||
|           enable = true; | ||||
|           default = true; | ||||
|         }; | ||||
|         prompt.starship.enable = true; | ||||
|         shell = { | ||||
|           fish.enable = true; | ||||
|           bash.enable = true; | ||||
|         }; | ||||
|         multiplexer.zellij.enable = true; | ||||
|         utility = { | ||||
|           ssh.enable = true; | ||||
|           nixIndex.enable = true; | ||||
|           git.enable = true; | ||||
|           tools.enable = true; | ||||
|           transientServices.enable = true; | ||||
|         }; | ||||
|       }; | ||||
|     };   | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										0
									
								
								inputs/home/profile/creative/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										0
									
								
								inputs/home/profile/creative/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
								
								
									
										42
									
								
								inputs/home/profile/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										42
									
								
								inputs/home/profile/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,42 @@ | |||
| { lib, config, ... }: | ||||
| 
 | ||||
| let | ||||
|   profileEnabler = let | ||||
|     reducer = l: r: {"${r}".enable = true;} // l; | ||||
|   in | ||||
|     builtins.foldl' reducer {} config.activeProfiles; | ||||
| in | ||||
| { | ||||
|   imports = [ | ||||
|     ./base | ||||
|     ./hyprland | ||||
|     #./creative | ||||
|     ./productivity | ||||
|     ./gaming | ||||
|     ./themes | ||||
|   ]; | ||||
| 
 | ||||
|   options = { | ||||
|     activeProfiles = lib.mkOption { | ||||
|       type = lib.types.listOf lib.types.str; | ||||
|       default = []; | ||||
|     }; | ||||
|      | ||||
|     profiles = { | ||||
|       base = { | ||||
|         enable = lib.mkEnableOption "Enable the base profile"; | ||||
|       }; | ||||
|       hyprland = { | ||||
|         enable = lib.mkEnableOption "Enable the hyprland profile"; | ||||
|       }; | ||||
|       gaming = { | ||||
|         enable = lib.mkEnableOption "Enable the gaming profile"; | ||||
|       }; | ||||
|       productivity = { | ||||
|         enable = lib.mkEnableOption "Enable the productivity profile"; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
|    | ||||
|   config.profiles = profileEnabler; | ||||
| } | ||||
							
								
								
									
										18
									
								
								inputs/home/profile/gaming/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								inputs/home/profile/gaming/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,18 @@ | |||
| { config, lib, ... }: | ||||
| let | ||||
|   cfg = config.profiles.gaming; | ||||
| in | ||||
| { | ||||
| 
 | ||||
|   imports = [ | ||||
|     ../../modules | ||||
|   ]; | ||||
|    | ||||
|   config = lib.mkIf cfg.enable { | ||||
|     homeModules.desktop = { | ||||
|       gaming = { | ||||
|         lutris.enable = true; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										69
									
								
								inputs/home/profile/hyprland/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										69
									
								
								inputs/home/profile/hyprland/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,69 @@ | |||
| { config, lib, ... }: | ||||
| let | ||||
|   cfg = config.profiles.hyprland; | ||||
| in | ||||
| { | ||||
| 
 | ||||
|   imports = [ | ||||
|     ../../modules | ||||
|   ]; | ||||
|    | ||||
|   config = lib.mkIf cfg.enable { | ||||
|     homeModules.desktop = { | ||||
| 
 | ||||
|       wayland = { | ||||
|         enable = true; | ||||
|         windowManager.hyprland = { | ||||
|           enable = true; | ||||
|           extras = { | ||||
|             hyprcapture.enable = true; | ||||
|             hyprshade.enable = true; | ||||
|           }; | ||||
|         }; | ||||
|         lockscreen.hyprlock.enable = true; | ||||
|         notification.mako.enable = true; | ||||
|         bar.waybar.enable = true; | ||||
|         launcher.rofi.enable = true; | ||||
|         utility = { | ||||
|           tools.enable = true; | ||||
|           gammastep.enable = true; | ||||
|         }; | ||||
|       }; | ||||
| 
 | ||||
|       security.polkit = "pantheon"; | ||||
| 
 | ||||
|       communication = { | ||||
|         discord.enable = true; | ||||
|       }; | ||||
| 
 | ||||
|       creative = { | ||||
|         audio = { | ||||
|           audacity.enable = true; | ||||
|         }; | ||||
|       }; | ||||
| 
 | ||||
|       browser.firefox= { | ||||
|         enable = true; | ||||
|         default = true; | ||||
|       }; | ||||
| 
 | ||||
|       terminal = { | ||||
|         foot = { | ||||
|           enable = true; | ||||
|           default = true; | ||||
|         }; | ||||
|       }; | ||||
| 
 | ||||
|       media = { | ||||
|         music.tui.enable = true; | ||||
|         music.easyeffects.enable = true; | ||||
|         image.imv.enable = true; | ||||
|         video = { | ||||
|           mpv.enable = true; | ||||
|           youtube.enable = true; | ||||
|           jellyfin.enable = true; | ||||
|         }; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										20
									
								
								inputs/home/profile/productivity/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										20
									
								
								inputs/home/profile/productivity/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,20 @@ | |||
| { config, lib, ... }: | ||||
| let | ||||
|   cfg = config.profiles.productivity; | ||||
| in | ||||
| { | ||||
| 
 | ||||
|   imports = [ | ||||
|     ../../modules | ||||
|   ]; | ||||
|    | ||||
|   config = lib.mkIf cfg.enable { | ||||
|     homeModules.desktop = { | ||||
|       productivity = { | ||||
|         obsidian.enable = true; | ||||
|         zathura.enable = true; | ||||
|         office.enable = true; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										29
									
								
								inputs/home/profile/themes/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										29
									
								
								inputs/home/profile/themes/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,29 @@ | |||
| { lib, config, ... }: | ||||
| 
 | ||||
| # let | ||||
| #   cfg = config.theme; | ||||
| # in | ||||
| 
 | ||||
| { | ||||
|   imports = [ | ||||
|     ./minimal | ||||
|     ./phone | ||||
|   ]; | ||||
| 
 | ||||
|   options.theme = { | ||||
|     minimal.enable = lib.mkEnableOption "enable minimal theme"; | ||||
|     phone.enable = lib.mkEnableOption "Enable phone theme"; | ||||
|   }; | ||||
| 
 | ||||
|   # config = { | ||||
|   #   assertions = [ | ||||
|   #     { | ||||
|   #       assertion =  | ||||
|   #       (lib.length (lib.filter (x: x) [ | ||||
|   #         cfg.minimal or false | ||||
|   #         cfg.OTHERTHEMEHERE or false | ||||
|   #       ]) <= 1); | ||||
|   #     } | ||||
|   #   ]; | ||||
|   # }; | ||||
| } | ||||
							
								
								
									
										42
									
								
								inputs/home/profile/themes/minimal/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										42
									
								
								inputs/home/profile/themes/minimal/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,42 @@ | |||
| { lib, config, pkgs, inputs, ... }: | ||||
| 
 | ||||
| let | ||||
|   cfg = config.theme.minimal; | ||||
|   inherit (inputs.nix-colors) colorSchemes; | ||||
| in | ||||
| 
 | ||||
| { | ||||
|   imports = [ inputs.nix-colors.homeManagerModule ]; | ||||
|   config = lib.mkIf cfg.enable { | ||||
| 
 | ||||
|     colorscheme = colorSchemes.gruvbox-material-dark-soft; | ||||
|     home.file.".colorscheme".text = config.colorscheme.slug; | ||||
|     home.sessionVariables.COLOR_SCHEME = "${config.colorscheme.slug}"; | ||||
| 
 | ||||
|     homeModules.theme = { | ||||
|       fonts.enable = true; | ||||
|       fonts.regular = { | ||||
|         family = "Fira Sans"; | ||||
|         package = pkgs.fira; | ||||
|       }; | ||||
|       fonts.monospace = { | ||||
|         family = "JetBrainsMono Nerd Font"; | ||||
|         package = pkgs.nerdfonts.override { fonts = [ "JetBrainsMono" ]; }; | ||||
|       }; | ||||
| 
 | ||||
|       cursor.enable = true; | ||||
|       cursor = { | ||||
|         name = "Bibata-Modern-Ice"; | ||||
|         package = pkgs.bibata-cursors; | ||||
|         size = 22; | ||||
|       }; | ||||
| 
 | ||||
|       wallpaper = { | ||||
|         enable = true; | ||||
|       }; | ||||
|      | ||||
|       gtk.enable = true; | ||||
|       qt.enable = true; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										28
									
								
								inputs/home/profile/themes/phone/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										28
									
								
								inputs/home/profile/themes/phone/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,28 @@ | |||
| { lib, config, pkgs, inputs, ... }: | ||||
| 
 | ||||
| let | ||||
|   cfg = config.theme.phone; | ||||
|   inherit (inputs.nix-colors) colorSchemes; | ||||
| in | ||||
| 
 | ||||
| { | ||||
|   imports = [ inputs.nix-colors.homeManagerModule ]; | ||||
|   config = lib.mkIf cfg.enable { | ||||
| 
 | ||||
|     colorscheme = colorSchemes.gruvbox-material-dark-soft; | ||||
|     home.file.".colorscheme".text = config.colorscheme.slug; | ||||
|     home.sessionVariables.COLOR_SCHEME = "${config.colorscheme.slug}"; | ||||
| 
 | ||||
|     homeModules.theme = { | ||||
|       fonts.enable = true; | ||||
|       fonts.regular = { | ||||
|         family = "Fira Sans"; | ||||
|         package = pkgs.fira; | ||||
|       }; | ||||
|       fonts.monospace = { | ||||
|         family = "JetBrainsMono Nerd Font"; | ||||
|         package = pkgs.nerdfonts.override { fonts = [ "JetBrainsMono" ]; }; | ||||
|       }; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue