Satellite dev module (+ other changes probably, including eww install)
This commit is contained in:
parent
5e696cf9d0
commit
da817da3b9
|
@ -50,7 +50,6 @@
|
||||||
|
|
||||||
specialArgs = {
|
specialArgs = {
|
||||||
inherit inputs outputs;
|
inherit inputs outputs;
|
||||||
paths.dotfiles = "/home/adrielus/Projects/satellite/dotfiles";
|
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
rec {
|
rec {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{ pkgs, ... }: {
|
{ pkgs, ... }: {
|
||||||
imports = [ ./bat.nix ./ssh.nix ./fish.nix ./tmux ./git.nix ./starship.nix ./direnv.nix ];
|
imports = [ ./exa.nix ./bat.nix ./ssh.nix ./fish.nix ./tmux ./git.nix ./starship.nix ./direnv.nix ];
|
||||||
|
|
||||||
# Enable bash
|
# Enable bash
|
||||||
programs.bash.enable = true;
|
programs.bash.enable = true;
|
||||||
|
@ -11,7 +11,6 @@
|
||||||
comma # Intstall and run programs by sticking a , before them
|
comma # Intstall and run programs by sticking a , before them
|
||||||
bc # Calculator
|
bc # Calculator
|
||||||
ncdu # TUI disk usage
|
ncdu # TUI disk usage
|
||||||
exa # Better ls
|
|
||||||
ripgrep # Better grep
|
ripgrep # Better grep
|
||||||
fd # Better find
|
fd # Better find
|
||||||
httpie # Better curl
|
httpie # Better curl
|
||||||
|
|
6
home/adrielus/features/cli/exa.nix
Normal file
6
home/adrielus/features/cli/exa.nix
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{
|
||||||
|
programs.exa = {
|
||||||
|
enable = true;
|
||||||
|
enableAliases = true;
|
||||||
|
};
|
||||||
|
}
|
|
@ -4,7 +4,6 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
shellAbbrs = {
|
shellAbbrs = {
|
||||||
ls = "exa -la";
|
|
||||||
cat = "bat";
|
cat = "bat";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
4
home/adrielus/features/desktop/common/eww/default.nix
Normal file
4
home/adrielus/features/desktop/common/eww/default.nix
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
{ config, ... }: {
|
||||||
|
programs.eww.enable = true;
|
||||||
|
programs.eww.configDir = config.satellite-dev.path "home/adrielus/features/desktop/common/eww/widgets";
|
||||||
|
}
|
|
@ -2,6 +2,7 @@
|
||||||
imports = [
|
imports = [
|
||||||
./common/rofi
|
./common/rofi
|
||||||
./common/polybar
|
./common/polybar
|
||||||
|
./common/eww
|
||||||
./common/fonts.nix
|
./common/fonts.nix
|
||||||
./common/xresources.nix
|
./common/xresources.nix
|
||||||
./common/xwallpaper.nix
|
./common/xwallpaper.nix
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
{ pkgs, lib, config, paths, ... }:
|
{ pkgs, lib, config, paths, ... }:
|
||||||
let
|
let
|
||||||
devMode = true;
|
|
||||||
extraPackages = with pkgs; [
|
extraPackages = with pkgs; [
|
||||||
# Language servers
|
# Language servers
|
||||||
nodePackages.typescript-language-server # typescript
|
nodePackages.typescript-language-server # typescript
|
||||||
|
@ -40,13 +39,9 @@ let
|
||||||
];
|
];
|
||||||
in
|
in
|
||||||
let
|
let
|
||||||
symlink = config.lib.file.mkOutOfStoreSymlink;
|
|
||||||
|
|
||||||
extraRuntime = env: [
|
extraRuntime = env: [
|
||||||
# Snippets
|
# Snippets
|
||||||
(if devMode
|
(config.satellite-dev.path "dotfiles/vscode-snippets")
|
||||||
then symlink "${paths.dotfiles}/vscode-snippets"
|
|
||||||
else ../../../../dotfiles/vscode-snippets)
|
|
||||||
|
|
||||||
# Base16 theme
|
# Base16 theme
|
||||||
(pkgs.writeTextDir
|
(pkgs.writeTextDir
|
||||||
|
@ -95,11 +90,7 @@ in
|
||||||
# Do not manage neovim via nix
|
# Do not manage neovim via nix
|
||||||
programs.neovim.enable = false;
|
programs.neovim.enable = false;
|
||||||
|
|
||||||
home.file.".config/nvim".source =
|
home.file.".config/nvim".source = config.satellite-dev.path "dotfiles/neovim";
|
||||||
if devMode then
|
|
||||||
symlink "${paths.dotfiles}/neovim" else
|
|
||||||
../../../../dotfiles/neovim;
|
|
||||||
|
|
||||||
home.sessionVariables.EDITOR = "nvim";
|
home.sessionVariables.EDITOR = "nvim";
|
||||||
|
|
||||||
home.packages = [
|
home.packages = [
|
||||||
|
|
|
@ -19,4 +19,6 @@
|
||||||
# obs-studio # video recorder
|
# obs-studio # video recorder
|
||||||
# lmms # music software
|
# lmms # music software
|
||||||
];
|
];
|
||||||
|
|
||||||
|
satellite-dev.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,4 +5,5 @@
|
||||||
discord = import ./discord.nix;
|
discord = import ./discord.nix;
|
||||||
fonts = import ./fonts.nix;
|
fonts = import ./fonts.nix;
|
||||||
firefox = import ./firefox;
|
firefox = import ./firefox;
|
||||||
|
satellite-dev = import ./satellite-dev.nix;
|
||||||
}
|
}
|
||||||
|
|
25
modules/home-manager/satellite-dev.nix
Normal file
25
modules/home-manager/satellite-dev.nix
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
{ lib, config, ... }: {
|
||||||
|
options.satellite-dev = {
|
||||||
|
enable = lib.mkOption {
|
||||||
|
type = lib.types.bool;
|
||||||
|
default = false;
|
||||||
|
description = "While true, makes out of store symlinks for files in dev mode";
|
||||||
|
};
|
||||||
|
|
||||||
|
root = lib.mkOption {
|
||||||
|
type = lib.types.str;
|
||||||
|
default = "~/Projects/satellite";
|
||||||
|
description = "Where the satellite repo is cloned";
|
||||||
|
};
|
||||||
|
|
||||||
|
path = lib.mkOption {
|
||||||
|
type = lib.types.functionTo lib.types.path;
|
||||||
|
description = "The function used to conditionally symlink in or out of store based on the above paths";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config.satellite-dev.path = path:
|
||||||
|
if config.satellite-dev.enable then
|
||||||
|
config.lib.file.mkOutOfStoreSymlink "${config.satellite-dev.root}/${path}"
|
||||||
|
else "${../..}/${path}";
|
||||||
|
}
|
Loading…
Reference in a new issue