diff --git a/modules/bluetooth/default.nix b/modules/bluetooth/default.nix new file mode 100644 index 0000000..f35bd29 --- /dev/null +++ b/modules/bluetooth/default.nix @@ -0,0 +1,16 @@ +{ inputs, ... }: +{ + flake.modules.nixos.ssh = + { pkgs, ... }: + { + hardware.bluetooth = { + enable = true; + settings = { + General = { + Enable = "Source,Sink,Media,Socket"; + Experimental = true; + }; + }; + }; + }; +} diff --git a/modules/cli-tools/default.nix b/modules/cli-tools/default.nix index d5ba546..b993470 100644 --- a/modules/cli-tools/default.nix +++ b/modules/cli-tools/default.nix @@ -15,6 +15,7 @@ let just mmv-go usbutils + lazygit ]; in { diff --git a/modules/git/default.nix b/modules/git/default.nix new file mode 100644 index 0000000..7d51347 --- /dev/null +++ b/modules/git/default.nix @@ -0,0 +1,58 @@ +{ inputs, ... }: +{ + flake.modules.nixos.git = + { pkgs, ... }: + { + environment.systemPackages = with pkgs; [ + git + ]; + + home-manager.sharedModules = [ + inputs.self.modules.homeManager.git + ]; + }; + + flake.modules.darwin.git = + { pkgs, ... }: + { + environment.systemPackages = with pkgs; [ + git + ]; + + home-manager.sharedModules = [ + inputs.self.modules.homeManager.git + ]; + }; + + flake.modules.homeManager.git = + { pkgs, config, ... }: + { + programs.git = { + enable = true; + settings = { + init = { + defaultBranch = "main"; + }; + + core = { + ignorecase = "false"; + }; + + pull = { + rebase = false; + }; + + push = { + autoSetupRemote = true; + }; + + user = { + # TODO get from config + name = "Dennis Schoepf"; + email = "me@dnsc.io"; + }; + }; + ignores = [ ".DS_Store" ]; + }; + }; +} diff --git a/modules/hosts/dnsc-machine/default.nix b/modules/hosts/dnsc-machine/default.nix index d4ef234..504cb10 100644 --- a/modules/hosts/dnsc-machine/default.nix +++ b/modules/hosts/dnsc-machine/default.nix @@ -9,11 +9,14 @@ in home-manager base shell + git ssh + neovim cli-tools nix nvidia-graphics drawing-tablet + bluetooth printing desktop terminal diff --git a/modules/neovim/colorscheme.nix b/modules/neovim/_colorscheme.nix similarity index 88% rename from modules/neovim/colorscheme.nix rename to modules/neovim/_colorscheme.nix index 5b8a799..3876c9c 100644 --- a/modules/neovim/colorscheme.nix +++ b/modules/neovim/_colorscheme.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-colorscheme = { programs.nixvim = { colorscheme = "winterly"; @@ -12,5 +11,4 @@ # discovers it automatically extraFiles."colors/winterly.lua".source = ./extraFiles/winterly.lua; }; - }; } diff --git a/modules/neovim/completion.nix b/modules/neovim/_completion.nix similarity index 92% rename from modules/neovim/completion.nix rename to modules/neovim/_completion.nix index ccbb93f..d8e115e 100644 --- a/modules/neovim/completion.nix +++ b/modules/neovim/_completion.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-completion = { programs.nixvim.plugins.blink-cmp = { enable = true; settings = { @@ -28,5 +27,4 @@ cmdline.completion.menu.auto_show = true; }; }; - }; } diff --git a/modules/neovim/editing.nix b/modules/neovim/_editing.nix similarity index 96% rename from modules/neovim/editing.nix rename to modules/neovim/_editing.nix index c1f984a..458849c 100644 --- a/modules/neovim/editing.nix +++ b/modules/neovim/_editing.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-editing = { pkgs, ... }: { programs.nixvim = { plugins.sleuth.enable = true; plugins.nvim-surround.enable = true; @@ -78,5 +77,4 @@ } ]; }; - }; } diff --git a/modules/neovim/formatter.nix b/modules/neovim/_formatter.nix similarity index 95% rename from modules/neovim/formatter.nix rename to modules/neovim/_formatter.nix index df2fb8d..7ca0b0e 100644 --- a/modules/neovim/formatter.nix +++ b/modules/neovim/_formatter.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-formatter = { pkgs, ... }: { programs.nixvim.plugins.conform-nvim = { enable = true; settings = { @@ -53,5 +52,4 @@ }; extraPackages = [ pkgs.stylua ]; }; - }; } diff --git a/modules/neovim/git.nix b/modules/neovim/_git.nix similarity index 94% rename from modules/neovim/git.nix rename to modules/neovim/_git.nix index ac8845d..69fa283 100644 --- a/modules/neovim/git.nix +++ b/modules/neovim/_git.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-git = { programs.nixvim = { plugins.gitportal = { enable = true; @@ -29,5 +28,4 @@ } ]; }; - }; } diff --git a/modules/neovim/keybindings.nix b/modules/neovim/_keybindings.nix similarity index 98% rename from modules/neovim/keybindings.nix rename to modules/neovim/_keybindings.nix index eb9e9ac..c67b159 100644 --- a/modules/neovim/keybindings.nix +++ b/modules/neovim/_keybindings.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-keybindings = { programs.nixvim = { plugins.which-key = { enable = true; @@ -130,5 +129,4 @@ } ]; }; - }; } diff --git a/modules/neovim/lsp.nix b/modules/neovim/_lsp.nix similarity index 99% rename from modules/neovim/lsp.nix rename to modules/neovim/_lsp.nix index 61861b4..002e79f 100644 --- a/modules/neovim/lsp.nix +++ b/modules/neovim/_lsp.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-lsp = { pkgs, ... }: { programs.nixvim = { plugins.lspconfig.enable = true; @@ -198,5 +197,4 @@ severity_sort = false; }; }; - }; } diff --git a/modules/neovim/options.nix b/modules/neovim/_options.nix similarity index 95% rename from modules/neovim/options.nix rename to modules/neovim/_options.nix index c36b7f4..e2b1fad 100644 --- a/modules/neovim/options.nix +++ b/modules/neovim/_options.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-options = { programs.nixvim = { globals = { mapleader = " "; @@ -48,5 +47,4 @@ foldlevelstart = 99; }; }; - }; } diff --git a/modules/neovim/picker.nix b/modules/neovim/_picker.nix similarity index 98% rename from modules/neovim/picker.nix rename to modules/neovim/_picker.nix index dd7dd06..cbb416b 100644 --- a/modules/neovim/picker.nix +++ b/modules/neovim/_picker.nix @@ -1,6 +1,5 @@ { ... }: { - flake.modules.homeManager.neovim-picker = { pkgs, ... }: { programs.nixvim = { plugins.oil = { enable = true; @@ -170,5 +169,4 @@ } ]; }; - }; } diff --git a/modules/neovim/default.nix b/modules/neovim/default.nix index eae14f8..86fe610 100644 --- a/modules/neovim/default.nix +++ b/modules/neovim/default.nix @@ -3,6 +3,22 @@ ... }: { + flake.modules.nixos.neovim = + { pkgs, ... }: + { + home-manager.sharedModules = [ + inputs.self.modules.homeManager.neovim + ]; + }; + + flake.modules.darwin.neovim = + { pkgs, ... }: + { + home-manager.sharedModules = [ + inputs.self.modules.homeManager.neovim + ]; + }; + flake.modules.homeManager.neovim = { pkgs, ... }: { imports = [ inputs.nixvim.homeModules.nixvim ]; programs.nixvim = { @@ -11,6 +27,16 @@ package = pkgs.neovim-unwrapped; vimAlias = true; vimdiffAlias = true; + imports = [ + ./_colorscheme.nix + ./_completion.nix + ./_editing.nix + ./_formatter.nix + ./_keybindings.nix + ./_lsp.nix + ./_options.nix + ./_picker.nix + ]; }; }; } diff --git a/modules/neovim/statusline.nix b/modules/neovim/statusline.nix deleted file mode 100644 index 64af6d7..0000000 --- a/modules/neovim/statusline.nix +++ /dev/null @@ -1,99 +0,0 @@ -{ ... }: -{ - flake.modules.homeManager.neovim-statusline = { - programs.nixvim.plugins.lualine = { - enable = true; - - settings = { - options = { - theme = { - __raw = "winterly_lualine"; - }; - icons_enabled = false; - component_separators = { - left = "|"; - right = "|"; - }; - section_separators = { - left = ""; - right = ""; - }; - }; - sections = { - lualine_a = [ - { - __unkeyed-1 = "mode"; - fmt = { - __raw = "function(str) return str:sub(1, 1) end"; - }; - } - ]; - lualine_b = [ - { - __unkeyed-1 = "filename"; - file_status = true; - newfile_status = false; - path = 4; - shorting_target = 120; - symbols = { - modified = "[+]"; - readonly = "[-]"; - unnamed = "[No Name]"; - newfile = "[New]"; - }; - } - "encoding" - ]; - lualine_c = null; - lualine_x = null; - lualine_y = [ - "branch" - "diff" - "diagnostics" - ]; - lualine_z = [ - "location" - ]; - }; - }; - - # Sets up my custom colorscheme - luaConfig.pre = /* lua */ '' - local palette = require("dnsc.palette") - - local winterly_lualine = { - normal = { - a = { bg = palette.magenta, fg = palette.bg, gui = "bold" }, - b = { bg = palette.bg_secondary, fg = palette.magenta }, - c = { bg = palette.bg_secondary, fg = palette.magenta }, - }, - insert = { - a = { bg = palette.cyan_bright, fg = palette.bg, gui = "bold" }, - b = { bg = palette.bg_secondary, fg = palette.cyan_bright }, - c = { bg = palette.bg_secondary, fg = palette.cyan_bright }, - }, - visual = { - a = { bg = palette.blue_bright, fg = palette.bg, gui = "bold" }, - b = { bg = palette.bg_secondary, fg = palette.blue_bright }, - c = { bg = palette.bg_secondary, fg = palette.blue_bright }, - }, - replace = { - a = { bg = palette.red_bright, fg = palette.bg, gui = "bold" }, - b = { bg = palette.bg_secondary, fg = palette.red_bright }, - c = { bg = palette.bg_secondary, fg = palette.red_bright }, - }, - command = { - a = { bg = palette.green_bright, fg = palette.bg, gui = "bold" }, - b = { bg = palette.bg_secondary, fg = palette.green_bright }, - c = { bg = palette.bg_secondary, fg = palette.green_bright }, - }, - inactive = { - a = { bg = palette.bg_secondary, fg = palette.fg_dim }, - b = { bg = palette.bg_secondary, fg = palette.fg_dim }, - c = { bg = palette.bg_secondary, fg = palette.fg_dim }, - }, - } - ''; - }; - }; -} diff --git a/modules/terminal/default.nix b/modules/terminal/default.nix index 211d099..4a13819 100644 --- a/modules/terminal/default.nix +++ b/modules/terminal/default.nix @@ -3,6 +3,11 @@ flake.modules.nixos.terminal = { pkgs, ... }: { + environment.systemPackages = with pkgs; [ + tmux + tmuxinator + ]; + home-manager.sharedModules = [ inputs.self.modules.homeManager.terminal ]; @@ -11,6 +16,11 @@ flake.modules.darwin.terminal = { pkgs, ... }: { + environment.systemPackages = with pkgs; [ + tmux + tmuxinator + ]; + home-manager.sharedModules = [ inputs.self.modules.homeManager.terminal ];