mirror of
https://github.com/nmasur/dotfiles
synced 2025-03-14 16:57:06 +00:00
fix neovim colors
This commit is contained in:
parent
e90c6b1724
commit
f59ac536a2
@ -8,20 +8,20 @@
|
||||
|
||||
# Sets Neovim colors based on Nix colorscheme
|
||||
|
||||
# options.colors = lib.mkOption {
|
||||
# type = lib.types.attrsOf lib.types.str;
|
||||
# description = "Attrset of base16 colorscheme key value pairs.";
|
||||
# };
|
||||
options.colors = lib.mkOption {
|
||||
type = lib.types.attrsOf lib.types.str;
|
||||
description = "Attrset of base16 colorscheme key value pairs.";
|
||||
};
|
||||
|
||||
# config = lib.mkIf config.colors {
|
||||
# plugins = [ pkgs.vimPlugins.base16-nvim ];
|
||||
# setup.base16-colorscheme = config.colors;
|
||||
#
|
||||
# # Telescope isn't working, shut off for now
|
||||
# lua = ''
|
||||
# require('base16-colorscheme').with_config {
|
||||
# telescope = false,
|
||||
# }
|
||||
# '';
|
||||
# };
|
||||
config = {
|
||||
plugins = [ pkgs.vimPlugins.base16-nvim ];
|
||||
setup.base16-colorscheme = config.colors;
|
||||
|
||||
# Telescope isn't working, shut off for now
|
||||
lua = ''
|
||||
require('base16-colorscheme').with_config {
|
||||
telescope = false,
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
@ -28,10 +28,10 @@
|
||||
|
||||
{
|
||||
pkgs,
|
||||
# colors ? null,
|
||||
# terraform ? false,
|
||||
# github ? false,
|
||||
# kubernetes ? false,
|
||||
colors ? (import ../../../../../../colorscheme/gruvbox).dark,
|
||||
terraform ? false,
|
||||
github ? false,
|
||||
kubernetes ? false,
|
||||
...
|
||||
}:
|
||||
|
||||
@ -40,15 +40,15 @@
|
||||
pkgs.neovimBuilder {
|
||||
package = pkgs.neovim-unwrapped;
|
||||
inherit
|
||||
# colors
|
||||
# terraform
|
||||
# github
|
||||
# kubernetes
|
||||
colors
|
||||
terraform
|
||||
github
|
||||
kubernetes
|
||||
;
|
||||
imports = [
|
||||
./config/align.nix
|
||||
./config/bufferline.nix
|
||||
# ./config/colors.nix
|
||||
./config/colors.nix
|
||||
./config/completion.nix
|
||||
./config/gitsigns.nix
|
||||
./config/lsp.nix
|
||||
|
@ -28,13 +28,14 @@ in
|
||||
|
||||
home.packages = [ cfg.package ];
|
||||
|
||||
#nmasur.presets.programs.neovim.package = lib.mkDefault pkgs.nmasur-neovim.override {
|
||||
# colors = cfg.colors;
|
||||
# github = cfg.github.enable;
|
||||
# terraform = cfg.terraform.enable;
|
||||
# kubernetes = cfg.kubernetes.enable;
|
||||
#};
|
||||
nmasur.presets.programs.neovim.package = pkgs.nmasur.neovim;
|
||||
nmasur.presets.programs.neovim.package = lib.mkDefault (
|
||||
pkgs.nmasur.neovim.override {
|
||||
colors = cfg.colors;
|
||||
github = cfg.github.enable;
|
||||
terraform = cfg.terraform.enable;
|
||||
kubernetes = cfg.kubernetes.enable;
|
||||
}
|
||||
);
|
||||
|
||||
# Use Neovim as the editor for git commit messages
|
||||
programs.git.extraConfig.core.editor = "${lib.getExe cfg.package}";
|
||||
@ -61,7 +62,9 @@ in
|
||||
|
||||
# Create a desktop option for launching Neovim from a file manager
|
||||
# (Requires launching the terminal and then executing Neovim)
|
||||
xdg.desktopEntries.nvim = lib.mkIf (pkgs.stdenv.isLinux && config.nmasur.presets.services.i3.enable) {
|
||||
xdg.desktopEntries.nvim =
|
||||
lib.mkIf (pkgs.stdenv.isLinux && config.nmasur.presets.services.i3.enable)
|
||||
{
|
||||
name = "Neovim wrapper";
|
||||
exec = "${lib.getExe config.nmasur.presets.services.i3.terminal} nvim %F"; # TODO: change to generic
|
||||
mimeType = [
|
||||
|
Loading…
x
Reference in New Issue
Block a user