mirror of
https://github.com/nmasur/dotfiles
synced 2025-08-24 11:54:41 +00:00
Compare commits
5 Commits
120b97f970
...
nixd
Author | SHA1 | Date | |
---|---|---|---|
|
6cf5f08fd5 | ||
|
8cba026f10 | ||
|
a6e4b3130d | ||
|
33868c1add | ||
|
d806bd7f56 |
@@ -159,6 +159,15 @@
|
||||
};
|
||||
};
|
||||
|
||||
# Mimic nixpkgs package environment for read-only profiles.ini management
|
||||
# From: https://github.com/booxter/home-manager/commit/dd1602e306fec366280f5953c5e1b553e3d9672a
|
||||
home.sessionVariables = {
|
||||
MOZ_LEGACY_PROFILES = 1;
|
||||
MOZ_ALLOW_DOWNGRADE = 1;
|
||||
};
|
||||
|
||||
# launchd.user.envVariables = config.home-manager.users.${config.user}.home.sessionVariables;
|
||||
|
||||
xdg.mimeApps = {
|
||||
associations.added = {
|
||||
"text/html" = [ "firefox.desktop" ];
|
||||
|
@@ -11,6 +11,11 @@
|
||||
options.terraform = lib.mkEnableOption "Whether to enable Terraform LSP";
|
||||
options.github = lib.mkEnableOption "Whether to enable GitHub features";
|
||||
options.kubernetes = lib.mkEnableOption "Whether to enable Kubernetes features";
|
||||
options.nixosConfiguration = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Configuration to use for nixd options checking";
|
||||
default = "default";
|
||||
};
|
||||
|
||||
config = {
|
||||
plugins = [
|
||||
@@ -43,6 +48,21 @@
|
||||
use.lspconfig.nixd.setup = dsl.callWith {
|
||||
cmd = [ "${pkgs.nixd}/bin/nixd" ];
|
||||
capabilities = dsl.rawLua "require('cmp_nvim_lsp').default_capabilities()";
|
||||
# settings = {
|
||||
# nixd = {
|
||||
# options = {
|
||||
# nixos = {
|
||||
# expr = "(builtins.getFlake (\"git+file://\" + toString ./.)).nixosConfigurations.${config.nixosConfiguration}.options";
|
||||
# };
|
||||
# home-manager = {
|
||||
# expr = "(builtins.getFlake (\"git+file://\" + toString ./.)).homeConfigurations.${config.nixosConfiguration}.options";
|
||||
# };
|
||||
# darwin = {
|
||||
# expr = "(builtins.getFlake (\"git+file://\" + toString ./.)).darwinConfigurations.${config.nixosConfiguration}.options";
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
};
|
||||
|
||||
use.lspconfig.pyright.setup = dsl.callWith {
|
||||
|
@@ -13,6 +13,7 @@ let
|
||||
terraform = config.terraform.enable;
|
||||
github = true;
|
||||
kubernetes = config.kubernetes.enable;
|
||||
nixosConfiguration = config.networking.hostName; # Used for Nixd
|
||||
};
|
||||
in
|
||||
{
|
||||
@@ -50,9 +51,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 {
|
||||
xdg.desktopEntries.nvim = lib.mkIf (pkgs.stdenv.isLinux && config.gui.enable) {
|
||||
name = "Neovim wrapper";
|
||||
exec = "kitty nvim %F";
|
||||
exec = "${config.home-manager.users.${config.user}.programs.rofi.terminal} nvim %F";
|
||||
mimeType = [
|
||||
"text/plain"
|
||||
"text/markdown"
|
||||
|
@@ -32,6 +32,7 @@
|
||||
terraform ? false,
|
||||
github ? false,
|
||||
kubernetes ? false,
|
||||
nixosConfiguration ? "default",
|
||||
...
|
||||
}:
|
||||
|
||||
@@ -44,6 +45,7 @@ pkgs.neovimBuilder {
|
||||
terraform
|
||||
github
|
||||
kubernetes
|
||||
nixosConfiguration
|
||||
;
|
||||
imports = [
|
||||
../config/align.nix
|
||||
|
Reference in New Issue
Block a user