Compare commits
No commits in common. "422c7c50f7233784094a1c449bbb9768fb403596" and "bc6f7f81016a45497e6c1160c0f900b00315419e" have entirely different histories.
422c7c50f7
...
bc6f7f8101
@ -1,6 +1,5 @@
|
|||||||
root=true
|
root=true
|
||||||
|
|
||||||
[*]
|
[*]
|
||||||
indent_style: space
|
indent_style: tab
|
||||||
indent_size: 2
|
indent_size: 2
|
||||||
end_of_line: lf
|
|
||||||
|
@ -1,23 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports =
|
|
||||||
[
|
|
||||||
(lib.mkAliasOptionModule ["hm"] [
|
|
||||||
"home-manager"
|
|
||||||
"users"
|
|
||||||
config.my.user
|
|
||||||
])
|
|
||||||
]
|
|
||||||
++ lib.my.getModules [./.];
|
|
||||||
|
|
||||||
hm.imports = [./home.nix];
|
|
||||||
|
|
||||||
home-manager.extraSpecialArgs = {
|
|
||||||
inherit inputs;
|
|
||||||
};
|
|
||||||
home-manager.useGlobalPkgs = true;
|
|
||||||
}
|
|
@ -1,18 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = lib.my.getHmModules [./.];
|
|
||||||
|
|
||||||
my = {
|
|
||||||
nushell.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# let standalone home-manager and home-manager in nixos/nix-darwin use the same derivation
|
|
||||||
home.packages = [
|
|
||||||
(pkgs.callPackage (inputs.home-manager + /home-manager) {path = inputs.home-manager;})
|
|
||||||
];
|
|
||||||
# home.stateVersion = "23.11";
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
{lib, ...}: let
|
|
||||||
inherit (lib) mkOption types;
|
|
||||||
in {
|
|
||||||
options.my = {
|
|
||||||
user = mkOption {type = types.str;};
|
|
||||||
name = mkOption {type = types.str;};
|
|
||||||
email = mkOption {type = types.str;};
|
|
||||||
uid = mkOption {type = types.int;};
|
|
||||||
keys = mkOption {type = types.listOf types.singleLineStr;};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = {
|
|
||||||
my = {
|
|
||||||
user = "michael";
|
|
||||||
name = "Michael Thomas";
|
|
||||||
email = "michaelhthomas@outlook.com";
|
|
||||||
uid = 1000;
|
|
||||||
keys = [
|
|
||||||
# Neptune
|
|
||||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune"
|
|
||||||
# Oracle
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1 +0,0 @@
|
|||||||
default.nix
|
|
@ -1,23 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.nushell;
|
|
||||||
in {
|
|
||||||
options.my.nushell = {
|
|
||||||
enable = mkEnableOption "nushell";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
programs.nushell = {
|
|
||||||
enable = true;
|
|
||||||
extraConfig = ''
|
|
||||||
$env.config = {
|
|
||||||
edit_mode: vi
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,27 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
nix.gc = {
|
|
||||||
automatic = true;
|
|
||||||
options = "--delete-older-than 30d";
|
|
||||||
};
|
|
||||||
nix.optimise.automatic = true;
|
|
||||||
nix.settings = {
|
|
||||||
extra-experimental-features = [
|
|
||||||
"flakes"
|
|
||||||
"nix-command"
|
|
||||||
];
|
|
||||||
keep-outputs = true;
|
|
||||||
log-lines = 25;
|
|
||||||
tarball-ttl = 43200;
|
|
||||||
trusted-users = [
|
|
||||||
"root"
|
|
||||||
config.my.user
|
|
||||||
];
|
|
||||||
};
|
|
||||||
nix.package = pkgs.nix;
|
|
||||||
programs.zsh.enable = true;
|
|
||||||
time.timeZone = "America/New_York";
|
|
||||||
}
|
|
@ -1,25 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.zsh;
|
|
||||||
in {
|
|
||||||
options.my.zsh = {
|
|
||||||
enable = mkEnableOption "zsh";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
hm.my.zsh.enable = true;
|
|
||||||
|
|
||||||
programs.zsh = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.variables.EDITOR = "nvim";
|
|
||||||
|
|
||||||
users.users."${config.my.user}".shell = pkgs.zsh;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,64 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.zsh;
|
|
||||||
in {
|
|
||||||
options.my.zsh = {
|
|
||||||
enable = mkEnableOption "zsh";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
programs.zsh = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
autosuggestion.enable = true;
|
|
||||||
syntaxHighlighting.enable = true;
|
|
||||||
historySubstringSearch.enable = true;
|
|
||||||
autocd = true;
|
|
||||||
enableCompletion = true;
|
|
||||||
|
|
||||||
# Enable pure prompt
|
|
||||||
initExtra = ''
|
|
||||||
fpath+=${pkgs.pure-prompt}/share/zsh/site-functions
|
|
||||||
autoload -U promptinit;
|
|
||||||
promptinit
|
|
||||||
prompt pure
|
|
||||||
'';
|
|
||||||
|
|
||||||
envExtra = ''
|
|
||||||
# Do not load global configuration
|
|
||||||
setopt no_global_rcs
|
|
||||||
'';
|
|
||||||
|
|
||||||
loginExtra = ''
|
|
||||||
setopt correct
|
|
||||||
'';
|
|
||||||
|
|
||||||
sessionVariables = {
|
|
||||||
# Make ls colorful on MacOS
|
|
||||||
CLICOLOR = 1;
|
|
||||||
};
|
|
||||||
|
|
||||||
plugins = [
|
|
||||||
{
|
|
||||||
name = "zsh-nix-shell";
|
|
||||||
file = "nix-shell.plugin.zsh";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "chisui";
|
|
||||||
repo = "zsh-nix-shell";
|
|
||||||
rev = "v0.8.0";
|
|
||||||
sha256 = "1lzrn0n4fxfcgg65v0qhnj7wnybybqzs4adz7xsrkgmcsr0ii8b7";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.zoxide = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,18 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
inputs',
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports =
|
|
||||||
[
|
|
||||||
inputs.agenix.darwinModules.default
|
|
||||||
inputs.home-manager.darwinModules.home-manager
|
|
||||||
../common
|
|
||||||
]
|
|
||||||
++ lib.my.getModules [./.];
|
|
||||||
|
|
||||||
hm.imports = [./home.nix];
|
|
||||||
|
|
||||||
environment.systemPackages = [inputs'.agenix.packages.default];
|
|
||||||
}
|
|
@ -1,3 +0,0 @@
|
|||||||
{lib, ...}: {
|
|
||||||
imports = lib.my.getHmModules [./.];
|
|
||||||
}
|
|
692
flake.lock
generated
692
flake.lock
generated
@ -1,81 +1,17 @@
|
|||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"agenix": {
|
|
||||||
"inputs": {
|
|
||||||
"darwin": "darwin",
|
|
||||||
"home-manager": "home-manager",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"systems": "systems"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1723293904,
|
|
||||||
"narHash": "sha256-b+uqzj+Wa6xgMS9aNbX4I+sXeb5biPDi39VgvSFqFvU=",
|
|
||||||
"owner": "ryantm",
|
|
||||||
"repo": "agenix",
|
|
||||||
"rev": "f6291c5935fdc4e0bef208cfc0dcab7e3f7a1c41",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "ryantm",
|
|
||||||
"repo": "agenix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"ags": {
|
|
||||||
"inputs": {
|
|
||||||
"astal": "astal",
|
|
||||||
"nixpkgs": "nixpkgs"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734091628,
|
|
||||||
"narHash": "sha256-8O3i8zESjHVsGzyXb8gEpLztvANq3Ot5bwo60YKJc7k=",
|
|
||||||
"owner": "Aylur",
|
|
||||||
"repo": "ags",
|
|
||||||
"rev": "27cd93147aba09142fa585fd16f13c56268b696c",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "Aylur",
|
|
||||||
"repo": "ags",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"astal": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"ags",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733520119,
|
|
||||||
"narHash": "sha256-6K07ZJTnFu1xASBCMtVc9cFTbBEauwSc7gGBmjLkLSk=",
|
|
||||||
"owner": "aylur",
|
|
||||||
"repo": "astal",
|
|
||||||
"rev": "4c19d8d06fa25cc6389f37abe8839b4d8be5c0d6",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "aylur",
|
|
||||||
"repo": "astal",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"darwin": {
|
"darwin": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"agenix",
|
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1700795494,
|
"lastModified": 1706581965,
|
||||||
"narHash": "sha256-gzGLZSiOhf155FW7262kdHo2YDeugp3VuIFb4/GGng0=",
|
"narHash": "sha256-1H7dRdK9LJ7+2X1XQtbwXr+QMqtVVo/ZF0/LIvkjdK8=",
|
||||||
"owner": "lnl7",
|
"owner": "lnl7",
|
||||||
"repo": "nix-darwin",
|
"repo": "nix-darwin",
|
||||||
"rev": "4b9b83d5a92e8c1fbfd8eb27eda375908c11ec4d",
|
"rev": "91b9daf672c957ef95a05491a75f62e6a01d5aaf",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -85,56 +21,14 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"darwin_2": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733570843,
|
|
||||||
"narHash": "sha256-sQJAxY1TYWD1UyibN/FnN97paTFuwBw3Vp3DNCyKsMk=",
|
|
||||||
"owner": "lnl7",
|
|
||||||
"repo": "nix-darwin",
|
|
||||||
"rev": "a35b08d09efda83625bef267eb24347b446c80b8",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "lnl7",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "nix-darwin",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"devshell": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1728330715,
|
|
||||||
"narHash": "sha256-xRJ2nPOXb//u1jaBnDP56M7v5ldavjbtR6lfGqSvcKg=",
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "devshell",
|
|
||||||
"rev": "dd6b80932022cea34a019e2bb32f6fa9e494dfef",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "devshell",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-compat": {
|
"flake-compat": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1696426674,
|
"lastModified": 1673956053,
|
||||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||||
"owner": "edolstra",
|
"owner": "edolstra",
|
||||||
"repo": "flake-compat",
|
"repo": "flake-compat",
|
||||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -145,104 +39,30 @@
|
|||||||
},
|
},
|
||||||
"flake-compat_2": {
|
"flake-compat_2": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733328505,
|
|
||||||
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
|
|
||||||
"owner": "edolstra",
|
|
||||||
"repo": "flake-compat",
|
|
||||||
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "edolstra",
|
|
||||||
"repo": "flake-compat",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-compat_3": {
|
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1696426674,
|
"lastModified": 1696426674,
|
||||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
||||||
|
"owner": "edolstra",
|
||||||
|
"repo": "flake-compat",
|
||||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
||||||
"revCount": 57,
|
|
||||||
"type": "tarball",
|
|
||||||
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"type": "tarball",
|
|
||||||
"url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-parts": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs-lib": "nixpkgs-lib"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733312601,
|
|
||||||
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "flake-parts",
|
|
||||||
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
|
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "hercules-ci",
|
"owner": "edolstra",
|
||||||
"repo": "flake-parts",
|
"repo": "flake-compat",
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-parts_2": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs-lib": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733312601,
|
|
||||||
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "flake-parts",
|
|
||||||
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "flake-parts",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-parts_3": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs-lib": [
|
|
||||||
"nur",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733312601,
|
|
||||||
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "flake-parts",
|
|
||||||
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "flake-parts",
|
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_2"
|
"systems": "systems"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710146030,
|
"lastModified": 1681202837,
|
||||||
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
|
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
|
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -253,14 +73,14 @@
|
|||||||
},
|
},
|
||||||
"flake-utils_2": {
|
"flake-utils_2": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_3"
|
"systems": "systems_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731533236,
|
"lastModified": 1705309234,
|
||||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -271,14 +91,14 @@
|
|||||||
},
|
},
|
||||||
"flake-utils_3": {
|
"flake-utils_3": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_4"
|
"systems": "systems_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731533236,
|
"lastModified": 1705309234,
|
||||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -287,197 +107,57 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"git-hooks": {
|
"flake-utils_4": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": [
|
"systems": "systems_5"
|
||||||
"nixvim",
|
|
||||||
"flake-compat"
|
|
||||||
],
|
|
||||||
"gitignore": "gitignore",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
],
|
|
||||||
"nixpkgs-stable": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734797603,
|
"lastModified": 1681202837,
|
||||||
"narHash": "sha256-ulZN7ps8nBV31SE+dwkDvKIzvN6hroRY8sYOT0w+E28=",
|
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
|
||||||
"owner": "cachix",
|
"owner": "numtide",
|
||||||
"repo": "git-hooks.nix",
|
"repo": "flake-utils",
|
||||||
"rev": "f0f0dc4920a903c3e08f5bdb9246bb572fcae498",
|
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "cachix",
|
"owner": "numtide",
|
||||||
"repo": "git-hooks.nix",
|
"repo": "flake-utils",
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"gitignore": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"git-hooks",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1709087332,
|
|
||||||
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "gitignore.nix",
|
|
||||||
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "hercules-ci",
|
|
||||||
"repo": "gitignore.nix",
|
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"home-manager": {
|
"home-manager": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"agenix",
|
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1703113217,
|
"lastModified": 1705659542,
|
||||||
"narHash": "sha256-7ulcXOk63TIT2lVDSExj7XzFx09LpdSAPtvgtM7yQPE=",
|
"narHash": "sha256-WA3xVfAk1AYmFdwghT7mt/erYpsU6JPu9mdTEP/e9HQ=",
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"rev": "3bfaacf46133c037bb356193bd2f1765d9dc82c1",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"home-manager_2": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734366194,
|
|
||||||
"narHash": "sha256-vykpJ1xsdkv0j8WOVXrRFHUAdp9NXHpxdnn1F4pYgSw=",
|
|
||||||
"owner": "rycee",
|
"owner": "rycee",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "80b0fdf483c5d1cb75aaad909bd390d48673857f",
|
"rev": "10cd9c53115061aa6a0a90aad0b0dde6a999cdb9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "rycee",
|
"owner": "rycee",
|
||||||
"ref": "release-24.11",
|
"ref": "release-23.11",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"home-manager_3": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734862405,
|
|
||||||
"narHash": "sha256-bXZJvUMJ2A6sIpYcCUAGjYCD5UDzmpmQCdmJSkPhleU=",
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"rev": "cb27edb5221d2f2920a03155f8becc502cf60e35",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "home-manager",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"ixx": {
|
|
||||||
"inputs": {
|
|
||||||
"flake-utils": [
|
|
||||||
"nixvim",
|
|
||||||
"nuschtosSearch",
|
|
||||||
"flake-utils"
|
|
||||||
],
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nuschtosSearch",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1729958008,
|
|
||||||
"narHash": "sha256-EiOq8jF4Z/zQe0QYVc3+qSKxRK//CFHMB84aYrYGwEs=",
|
|
||||||
"owner": "NuschtOS",
|
|
||||||
"repo": "ixx",
|
|
||||||
"rev": "9fd01aad037f345350eab2cd45e1946cc66da4eb",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NuschtOS",
|
|
||||||
"ref": "v0.0.6",
|
|
||||||
"repo": "ixx",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"master": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734892047,
|
|
||||||
"narHash": "sha256-85aPEsOxviepQc526USyeqpQQQE3F9u9LpiPCGWGRnM=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "2cf41595ff64bcda9e3e1ed1cac217b5a023a82d",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nix-darwin": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733570843,
|
|
||||||
"narHash": "sha256-sQJAxY1TYWD1UyibN/FnN97paTFuwBw3Vp3DNCyKsMk=",
|
|
||||||
"owner": "lnl7",
|
|
||||||
"repo": "nix-darwin",
|
|
||||||
"rev": "a35b08d09efda83625bef267eb24347b446c80b8",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "lnl7",
|
|
||||||
"repo": "nix-darwin",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nix-vscode-extensions": {
|
"nix-vscode-extensions": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat",
|
"flake-compat": "flake-compat",
|
||||||
"flake-utils": "flake-utils",
|
"flake-utils": "flake-utils",
|
||||||
"nixpkgs": "nixpkgs_2"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734832456,
|
"lastModified": 1706663720,
|
||||||
"narHash": "sha256-gyp5aVMSA83OV8kP/a1FBA6KGJqNkswUK9VdAh1hLS4=",
|
"narHash": "sha256-nPstfigc9FdWIwbtZcwfAjEP5fsI171CDMQ7rJdg0ok=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "nix-vscode-extensions",
|
"repo": "nix-vscode-extensions",
|
||||||
"rev": "c567c5f3bc53723d726f286ea94d5aebac55d4c5",
|
"rev": "129d9ddaf92f8a0942037aebf99dfa09d31e0dde",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -490,121 +170,62 @@
|
|||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat_2",
|
"flake-compat": "flake-compat_2",
|
||||||
"flake-utils": "flake-utils_2",
|
"flake-utils": "flake-utils_2",
|
||||||
"nixpkgs": "nixpkgs_3"
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1733854371,
|
"lastModified": 1706608109,
|
||||||
"narHash": "sha256-K9qGHniYBbjqVcEiwXyiofj/IFf78L5F0/FCf+CKyr0=",
|
"narHash": "sha256-Yc7pmonKJX/dOFm+qEInE+JlskMiN9OmOwUd/EKp4a0=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NixOS-WSL",
|
"repo": "NixOS-WSL",
|
||||||
"rev": "dee4425dcee3149475ead0cb6a616b8a028c5888",
|
"rev": "0b52d9e7a6c779f8b88c6e3bdfe6064fad648dcf",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"ref": "main",
|
|
||||||
"repo": "NixOS-WSL",
|
"repo": "NixOS-WSL",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1733581040,
|
"lastModified": 1684570954,
|
||||||
"narHash": "sha256-Qn3nPMSopRQJgmvHzVqPcE3I03zJyl8cSbgnnltfFDY=",
|
"narHash": "sha256-FX5y4Sm87RWwfu9PI71XFvuRpZLowh00FQpIJ1WfXqE=",
|
||||||
"owner": "nixos",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "22c3f2cf41a0e70184334a958e6b124fb0ce3e01",
|
"rev": "3005f20ce0aaa58169cdee57c8aa12e5f1b6e1b3",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "NixOS",
|
||||||
"ref": "nixos-unstable",
|
"ref": "nixos-unstable",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs-lib": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733096140,
|
|
||||||
"narHash": "sha256-1qRH7uAUsyQI7R1Uwl4T+XvdNv778H0Nb5njNrqvylY=",
|
|
||||||
"type": "tarball",
|
|
||||||
"url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"type": "tarball",
|
|
||||||
"url": "https://github.com/NixOS/nixpkgs/archive/5487e69da40cbd611ab2cadee0b4637225f7cfae.tar.gz"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1713805509,
|
"lastModified": 1706515015,
|
||||||
"narHash": "sha256-YgSEan4CcrjivCNO5ZNzhg7/8ViLkZ4CB/GrGBVSudo=",
|
"narHash": "sha256-eFfY5A7wlYy3jD/75lx6IJRueg4noE+jowl0a8lIlVo=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "1e1dc66fe68972a76679644a5577828b6a7e8be4",
|
"rev": "f4a8d6d5324c327dcc2d863eb7f3cc06ad630df4",
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"ref": "nixpkgs-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_3": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733384649,
|
|
||||||
"narHash": "sha256-K5DJ2LpPqht7K76bsxetI+YHhGGRyVteTPRQaIIKJpw=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "190c31a89e5eec80dd6604d7f9e5af3802a58a13",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"ref": "nixos-24.05",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_4": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734737257,
|
|
||||||
"narHash": "sha256-GIMyMt1pkkoXdCq9un859bX6YQZ/iYtukb9R5luazLM=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "1c6e20d41d6a9c1d737945962160e8571df55daa",
|
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"id": "nixpkgs",
|
"id": "nixpkgs",
|
||||||
"ref": "nixos-24.11",
|
"ref": "nixos-23.11",
|
||||||
"type": "indirect"
|
"type": "indirect"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs_5": {
|
"nixpkgs_3": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734649271,
|
"lastModified": 1706487304,
|
||||||
"narHash": "sha256-4EVBRhOjMDuGtMaofAIqzJbg4Ql7Ai0PSeuVZTHjyKQ=",
|
"narHash": "sha256-LE8lVX28MV2jWJsidW13D2qrHU/RUUONendL2Q/WlJg=",
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "d70bd19e0a38ad4790d3913bf08fcbfc9eeca507",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_6": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1728538411,
|
|
||||||
"narHash": "sha256-f0SBJz1eZ2yOuKUr5CA9BHULGXVSn6miBuUWdTyhUhU=",
|
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "b69de56fac8c2b6f8fd27f2eca01dcda8e0a4221",
|
"rev": "90f456026d284c22b3e3497be980b2e47d0b28ac",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -614,62 +235,13 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs_7": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733097829,
|
|
||||||
"narHash": "sha256-9hbb1rqGelllb4kVUCZ307G2k3/UhmA8PPGBoyuWaSw=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "2c15aa59df0017ca140d9ba302412298ab4bf22a",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixpkgs-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixvim": {
|
|
||||||
"inputs": {
|
|
||||||
"devshell": "devshell",
|
|
||||||
"flake-compat": "flake-compat_3",
|
|
||||||
"flake-parts": "flake-parts_2",
|
|
||||||
"git-hooks": "git-hooks",
|
|
||||||
"home-manager": "home-manager_3",
|
|
||||||
"nix-darwin": "nix-darwin",
|
|
||||||
"nixpkgs": [
|
|
||||||
"unstable"
|
|
||||||
],
|
|
||||||
"nuschtosSearch": "nuschtosSearch",
|
|
||||||
"treefmt-nix": "treefmt-nix"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734880727,
|
|
||||||
"narHash": "sha256-bQfaaYoH8kSdw2UWb8RLZoa/2jPvDjaw87nvj+pO5lE=",
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "nixvim",
|
|
||||||
"rev": "450cccf472f40ae8e3b92eec9e5f4b071693ac85",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nix-community",
|
|
||||||
"repo": "nixvim",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nur": {
|
"nur": {
|
||||||
"inputs": {
|
|
||||||
"flake-parts": "flake-parts_3",
|
|
||||||
"nixpkgs": "nixpkgs_5",
|
|
||||||
"treefmt-nix": "treefmt-nix_2"
|
|
||||||
},
|
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734891997,
|
"lastModified": 1706665018,
|
||||||
"narHash": "sha256-MXE+6AV6HJfUTwKAaNPR5+WsejO02Q5JNNhz0yMUyVw=",
|
"narHash": "sha256-NtvxIQhRxavrL7PQ1ZURqWr15XM1Dc98yv4U5gTbJhk=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NUR",
|
"repo": "NUR",
|
||||||
"rev": "b8deab92e4f1bc950ef7b2273b8b5c3a764c2e77",
|
"rev": "98930fb5cf79e652111ed531e6ce777618b1c898",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -678,58 +250,31 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nuschtosSearch": {
|
|
||||||
"inputs": {
|
|
||||||
"flake-utils": "flake-utils_3",
|
|
||||||
"ixx": "ixx",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733773348,
|
|
||||||
"narHash": "sha256-Y47y+LesOCkJaLvj+dI/Oa6FAKj/T9sKVKDXLNsViPw=",
|
|
||||||
"owner": "NuschtOS",
|
|
||||||
"repo": "search",
|
|
||||||
"rev": "3051be7f403bff1d1d380e4612f0c70675b44fc9",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NuschtOS",
|
|
||||||
"repo": "search",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"agenix": "agenix",
|
"darwin": "darwin",
|
||||||
"ags": "ags",
|
"home-manager": "home-manager",
|
||||||
"darwin": "darwin_2",
|
|
||||||
"flake-parts": "flake-parts",
|
|
||||||
"home-manager": "home-manager_2",
|
|
||||||
"master": "master",
|
|
||||||
"nix-vscode-extensions": "nix-vscode-extensions",
|
"nix-vscode-extensions": "nix-vscode-extensions",
|
||||||
"nixos-wsl": "nixos-wsl",
|
"nixos-wsl": "nixos-wsl",
|
||||||
"nixpkgs": "nixpkgs_4",
|
"nixpkgs": "nixpkgs_2",
|
||||||
"nixvim": "nixvim",
|
|
||||||
"nur": "nur",
|
"nur": "nur",
|
||||||
"rust-overlay": "rust-overlay",
|
"rust-overlay": "rust-overlay",
|
||||||
"treefmt-nix": "treefmt-nix_3",
|
|
||||||
"unstable": "unstable",
|
"unstable": "unstable",
|
||||||
"utils": "utils"
|
"utils": "utils",
|
||||||
|
"vscode-server": "vscode-server"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"rust-overlay": {
|
"rust-overlay": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": "nixpkgs_6"
|
"flake-utils": "flake-utils_3",
|
||||||
|
"nixpkgs": "nixpkgs_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734834660,
|
"lastModified": 1706634984,
|
||||||
"narHash": "sha256-bm8V+Cu8rWJA+vKQnc94mXTpSDgvedyoDKxTVi/uJfw=",
|
"narHash": "sha256-xn7lGPE8gRGBe3Lt8ESoN/uUHm7IrbiV7siupwjHX1o=",
|
||||||
"owner": "oxalica",
|
"owner": "oxalica",
|
||||||
"repo": "rust-overlay",
|
"repo": "rust-overlay",
|
||||||
"rev": "b070e6030118680977bc2388868c4b3963872134",
|
"rev": "883b84c426107a8ec020e7124f263d7c35a5bb9f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -813,73 +358,13 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"treefmt-nix": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixvim",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734704479,
|
|
||||||
"narHash": "sha256-MMi74+WckoyEWBRcg/oaGRvXC9BVVxDZNRMpL+72wBI=",
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "treefmt-nix",
|
|
||||||
"rev": "65712f5af67234dad91a5a4baee986a8b62dbf8f",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "treefmt-nix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"treefmt-nix_2": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nur",
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1733222881,
|
|
||||||
"narHash": "sha256-JIPcz1PrpXUCbaccEnrcUS8jjEb/1vJbZz5KkobyFdM=",
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "treefmt-nix",
|
|
||||||
"rev": "49717b5af6f80172275d47a418c9719a31a78b53",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "treefmt-nix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"treefmt-nix_3": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": "nixpkgs_7"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1734704479,
|
|
||||||
"narHash": "sha256-MMi74+WckoyEWBRcg/oaGRvXC9BVVxDZNRMpL+72wBI=",
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "treefmt-nix",
|
|
||||||
"rev": "65712f5af67234dad91a5a4baee986a8b62dbf8f",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "numtide",
|
|
||||||
"repo": "treefmt-nix",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"unstable": {
|
"unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734649271,
|
"lastModified": 1706371002,
|
||||||
"narHash": "sha256-4EVBRhOjMDuGtMaofAIqzJbg4Ql7Ai0PSeuVZTHjyKQ=",
|
"narHash": "sha256-dwuorKimqSYgyu8Cw6ncKhyQjUDOyuXoxDTVmAXq88s=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "d70bd19e0a38ad4790d3913bf08fcbfc9eeca507",
|
"rev": "c002c6aa977ad22c60398daaa9be52f2203d0006",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -890,14 +375,14 @@
|
|||||||
},
|
},
|
||||||
"utils": {
|
"utils": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_5"
|
"systems": "systems_4"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731533236,
|
"lastModified": 1705309234,
|
||||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -905,6 +390,27 @@
|
|||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"vscode-server": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-utils": "flake-utils_4",
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1684517665,
|
||||||
|
"narHash": "sha256-SaAr66uCQ8CF75jIr23FZjk1+9Kfwm5sQnwV25206Gs=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nixos-vscode-server",
|
||||||
|
"rev": "1e1358493df6529d4c7bc4cc3066f76fd16d4ae6",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nixos-vscode-server",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": "root",
|
"root": "root",
|
||||||
|
225
flake.nix
225
flake.nix
@ -2,50 +2,219 @@
|
|||||||
description = "Michael Thomas's NixOS configuration";
|
description = "Michael Thomas's NixOS configuration";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "nixpkgs/nixos-24.11";
|
nixpkgs.url = "nixpkgs/nixos-23.11";
|
||||||
unstable.url = "nixpkgs/nixos-unstable";
|
unstable.url = "nixpkgs/nixos-unstable";
|
||||||
master.url = "github:NixOS/nixpkgs";
|
|
||||||
nur.url = "github:nix-community/NUR";
|
nur.url = "github:nix-community/NUR";
|
||||||
|
|
||||||
home-manager = {
|
utils.url = "github:numtide/flake-utils";
|
||||||
url = "github:rycee/home-manager/release-24.11";
|
rust-overlay.url = "github:oxalica/rust-overlay";
|
||||||
|
nix-vscode-extensions.url = "github:nix-community/nix-vscode-extensions";
|
||||||
|
|
||||||
|
nixos-wsl = {
|
||||||
|
url = "github:nix-community/NixOS-WSL";
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.follows = "nixpkgs";
|
nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
vscode-server = {
|
||||||
|
url = "github:nix-community/nixos-vscode-server";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
darwin = {
|
darwin = {
|
||||||
url = "github:lnl7/nix-darwin/master";
|
url = "github:lnl7/nix-darwin/master";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
|
|
||||||
|
|
||||||
utils.url = "github:numtide/flake-utils";
|
home-manager = {
|
||||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
url = "github:rycee/home-manager/release-23.11";
|
||||||
treefmt-nix.url = "github:numtide/treefmt-nix";
|
inputs = {
|
||||||
nixvim = {
|
nixpkgs.follows = "nixpkgs";
|
||||||
url = "github:nix-community/nixvim";
|
};
|
||||||
inputs.nixpkgs.follows = "unstable";
|
|
||||||
};
|
|
||||||
rust-overlay.url = "github:oxalica/rust-overlay";
|
|
||||||
nix-vscode-extensions.url = "github:nix-community/nix-vscode-extensions";
|
|
||||||
ags.url = "github:Aylur/ags";
|
|
||||||
agenix = {
|
|
||||||
url = "github:ryantm/agenix";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs @ {flake-parts, ...}:
|
outputs = {
|
||||||
flake-parts.lib.mkFlake {inherit inputs;} {
|
self,
|
||||||
flake = {
|
nixpkgs,
|
||||||
overlays = import ./overlays {inherit inputs;};
|
unstable,
|
||||||
|
nur,
|
||||||
|
utils,
|
||||||
|
rust-overlay,
|
||||||
|
nix-vscode-extensions,
|
||||||
|
nixos-wsl,
|
||||||
|
vscode-server,
|
||||||
|
darwin,
|
||||||
|
home-manager,
|
||||||
|
...
|
||||||
|
} @ inputs: {
|
||||||
|
# This repo's overlay plus any other overlays you use
|
||||||
|
# If you want to use packages from flakes that are not nixpkgs (such as NUR), add their overlays here.\
|
||||||
|
overlays = {
|
||||||
|
default = import ./overlays inputs;
|
||||||
|
pkg-sets = (
|
||||||
|
final: prev: {
|
||||||
|
unstable = import inputs.unstable {system = final.system;};
|
||||||
|
trunk = import inputs.trunk {system = final.system;};
|
||||||
|
}
|
||||||
|
);
|
||||||
|
rust-overlay = rust-overlay.overlays.default;
|
||||||
|
vscode-extensions = nix-vscode-extensions.overlays.default;
|
||||||
|
};
|
||||||
|
|
||||||
|
overlaysModule = {
|
||||||
|
nixpkgs.overlays = builtins.attrValues self.overlays;
|
||||||
|
};
|
||||||
|
|
||||||
|
nixosConfigurations = {
|
||||||
|
loft = nixpkgs.lib.nixosSystem {
|
||||||
|
system = utils.lib.system.x86_64-linux;
|
||||||
|
modules = [
|
||||||
|
self.overlaysModule
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
./modules/common.nix
|
||||||
|
./modules/containers.nix
|
||||||
|
|
||||||
|
./machines/loft/configuration.nix
|
||||||
|
];
|
||||||
|
specialArgs = {inherit inputs;};
|
||||||
};
|
};
|
||||||
|
|
||||||
systems = [
|
kitchen = nixpkgs.lib.nixosSystem {
|
||||||
"aarch64-darwin"
|
system = utils.lib.system.x86_64-linux;
|
||||||
"aarch64-linux"
|
modules = [
|
||||||
"x86_64-linux"
|
self.overlaysModule
|
||||||
];
|
home-manager.nixosModules.home-manager
|
||||||
imports = [./flakes];
|
./modules/common.nix
|
||||||
|
./modules/containers.nix
|
||||||
|
{
|
||||||
|
home-manager.useGlobalPkgs = true;
|
||||||
|
home-manager.useUserPackages = true;
|
||||||
|
home-manager.users.michael = import ./user/environments/nixos/home.nix;
|
||||||
|
}
|
||||||
|
|
||||||
|
./machines/kitchen/configuration.nix
|
||||||
|
];
|
||||||
|
specialArgs = {inherit inputs;};
|
||||||
|
};
|
||||||
|
|
||||||
|
thinkcentre = nixpkgs.lib.nixosSystem {
|
||||||
|
system = utils.lib.system.x86_64-linux;
|
||||||
|
modules = [
|
||||||
|
self.overlaysModule
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
./modules/common.nix
|
||||||
|
./modules/hyprland.nix
|
||||||
|
./modules/containers.nix
|
||||||
|
{
|
||||||
|
home-manager.useGlobalPkgs = true;
|
||||||
|
home-manager.useUserPackages = true;
|
||||||
|
home-manager.users.michael = import ./user/environments/nixos/home.nix;
|
||||||
|
}
|
||||||
|
|
||||||
|
./machines/thinkcentre/configuration.nix
|
||||||
|
];
|
||||||
|
specialArgs = {inherit inputs;};
|
||||||
|
};
|
||||||
|
|
||||||
|
# WSL environment
|
||||||
|
work = inputs.nixpkgs.lib.nixosSystem {
|
||||||
|
system = utils.lib.system.x86_64-linux;
|
||||||
|
modules = [
|
||||||
|
self.overlaysModule
|
||||||
|
home-manager.nixosModules.home-manager
|
||||||
|
vscode-server.nixosModules.default
|
||||||
|
./modules/containers.nix
|
||||||
|
./modules/nix.nix
|
||||||
|
|
||||||
|
./machines/work/configuration.nix
|
||||||
|
];
|
||||||
|
specialArgs = {inherit inputs;};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
darwinConfigurations = {
|
||||||
|
mac = darwin.lib.darwinSystem {
|
||||||
|
system = "aarch64-darwin";
|
||||||
|
specialArgs = {inherit inputs;};
|
||||||
|
modules = [
|
||||||
|
self.overlaysModule
|
||||||
|
home-manager.darwinModules.home-manager
|
||||||
|
{
|
||||||
|
home-manager.useGlobalPkgs = true;
|
||||||
|
home-manager.useUserPackages = true;
|
||||||
|
home-manager.users.michael = import ./user/environments/mac/home.nix;
|
||||||
|
}
|
||||||
|
|
||||||
|
./modules/yabai.nix
|
||||||
|
./machines/mac/configuration.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
homeConfigurations = {
|
||||||
|
nixos = inputs.home-manager.lib.homeManagerConfiguration {
|
||||||
|
system = "x86_64-linux";
|
||||||
|
homeDirectory = "/home/michael";
|
||||||
|
username = "michael";
|
||||||
|
stateVersion = "21.05";
|
||||||
|
configuration = {
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./user/environments/nixos/home.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
wsl = inputs.home-manager.lib.homeManagerConfiguration {
|
||||||
|
system = "x86_64-linux";
|
||||||
|
homeDirectory = "/home/michael";
|
||||||
|
username = "michael";
|
||||||
|
stateVersion = "21.05";
|
||||||
|
configuration = {
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./user/environments/wsl/home.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
mac = inputs.home-manager.lib.homeManagerConfiguration {
|
||||||
|
system = "aarch64-darwin";
|
||||||
|
homeDirectory = "/Users/michael";
|
||||||
|
username = "michael";
|
||||||
|
stateVersion = "22.05";
|
||||||
|
configuration = {
|
||||||
|
config,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./user/environments/mac/home.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
# // utils.lib.eachSystem [ "aarch64-linux" "x86_64-darwin" "x86_64-linux" ] (system: {
|
||||||
|
# nixpkgs = import nixpkgs {
|
||||||
|
# inherit system;
|
||||||
|
# overlays = [
|
||||||
|
# self.overlays.default
|
||||||
|
# ];
|
||||||
|
# config.allowUnfree = true;
|
||||||
|
# };
|
||||||
|
# });
|
||||||
}
|
}
|
||||||
|
@ -1,44 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
withSystem,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
mkDarwin = {
|
|
||||||
system ? "aarch64-darwin",
|
|
||||||
modules ? [],
|
|
||||||
}:
|
|
||||||
withSystem system (
|
|
||||||
{
|
|
||||||
inputs',
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
system,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
inputs.darwin.lib.darwinSystem {
|
|
||||||
inherit system;
|
|
||||||
specialArgs = {
|
|
||||||
inherit
|
|
||||||
inputs
|
|
||||||
inputs'
|
|
||||||
lib
|
|
||||||
pkgs
|
|
||||||
;
|
|
||||||
};
|
|
||||||
modules = [../darwin] ++ modules;
|
|
||||||
}
|
|
||||||
);
|
|
||||||
in {
|
|
||||||
flake.darwinConfigurations = {
|
|
||||||
mac = mkDarwin {
|
|
||||||
modules = [
|
|
||||||
{
|
|
||||||
hm = import ../user/environments/mac/home.nix;
|
|
||||||
}
|
|
||||||
|
|
||||||
../modules/yabai.nix
|
|
||||||
../machines/mac/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,9 +0,0 @@
|
|||||||
{
|
|
||||||
imports = [
|
|
||||||
./lib.nix
|
|
||||||
./darwin.nix
|
|
||||||
./nixos.nix
|
|
||||||
./packages.nix
|
|
||||||
./treefmt.nix
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,30 +0,0 @@
|
|||||||
{
|
|
||||||
perSystem = {
|
|
||||||
inputs',
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
# use nixpkgs lib instead of flake-parts lib
|
|
||||||
# avoids home-manager warning about version mismatch
|
|
||||||
inherit (pkgs) lib;
|
|
||||||
in {
|
|
||||||
_module.args.lib = lib.extend (
|
|
||||||
final: prev: {
|
|
||||||
my = let
|
|
||||||
lib = final;
|
|
||||||
getPaths = file: root:
|
|
||||||
builtins.filter builtins.pathExists (
|
|
||||||
map (dir: root + "/${dir}/${file}") (
|
|
||||||
lib.attrNames (lib.filterAttrs (name: type: type == "directory") (builtins.readDir root))
|
|
||||||
)
|
|
||||||
);
|
|
||||||
in {
|
|
||||||
inherit getPaths;
|
|
||||||
getModules = builtins.concatMap (getPaths "default.nix");
|
|
||||||
getHmModules = builtins.concatMap (getPaths "home.nix");
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
};
|
|
||||||
}
|
|
126
flakes/nixos.nix
126
flakes/nixos.nix
@ -1,126 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
self,
|
|
||||||
withSystem,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
mkNixos = {
|
|
||||||
system ? "x86_64-linux",
|
|
||||||
nixpkgs ? inputs.nixpkgs,
|
|
||||||
config ? {},
|
|
||||||
overlays ? [],
|
|
||||||
modules ? [],
|
|
||||||
}:
|
|
||||||
withSystem system (
|
|
||||||
{
|
|
||||||
inputs',
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
system,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
customPkgs = import nixpkgs (
|
|
||||||
lib.recursiveUpdate {
|
|
||||||
inherit system;
|
|
||||||
overlays = (builtins.attrValues self.overlays) ++ overlays;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
} {inherit config;}
|
|
||||||
);
|
|
||||||
in
|
|
||||||
nixpkgs.lib.nixosSystem {
|
|
||||||
inherit system;
|
|
||||||
specialArgs = {
|
|
||||||
inherit inputs inputs' lib;
|
|
||||||
pkgs =
|
|
||||||
if (nixpkgs != inputs.nixpkgs || config != {} || overlays != [])
|
|
||||||
then customPkgs
|
|
||||||
else pkgs;
|
|
||||||
};
|
|
||||||
modules = [../nixos] ++ modules;
|
|
||||||
}
|
|
||||||
);
|
|
||||||
in {
|
|
||||||
flake.nixosConfigurations = let
|
|
||||||
defaultModules = [
|
|
||||||
../modules
|
|
||||||
inputs.agenix.nixosModules.default
|
|
||||||
{
|
|
||||||
environment.systemPackages = [
|
|
||||||
inputs.agenix.packages.x86_64-linux.default
|
|
||||||
];
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
fullNixOSModules =
|
|
||||||
defaultModules
|
|
||||||
++ [
|
|
||||||
{
|
|
||||||
home-manager.users.michael = import ../user/environments/nixos/home.nix;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
in {
|
|
||||||
kitchen = mkNixos {
|
|
||||||
modules =
|
|
||||||
fullNixOSModules
|
|
||||||
++ [
|
|
||||||
../modules/common.nix
|
|
||||||
../modules/containers.nix
|
|
||||||
|
|
||||||
../machines/kitchen/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
thinkcentre = mkNixos {
|
|
||||||
modules =
|
|
||||||
fullNixOSModules
|
|
||||||
++ [
|
|
||||||
../modules/common.nix
|
|
||||||
../modules/containers.nix
|
|
||||||
|
|
||||||
../machines/thinkcentre/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
terra = mkNixos {
|
|
||||||
modules =
|
|
||||||
fullNixOSModules
|
|
||||||
++ [
|
|
||||||
../modules/common.nix
|
|
||||||
../modules/containers.nix
|
|
||||||
|
|
||||||
../machines/terra/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
oracle = mkNixos {
|
|
||||||
modules =
|
|
||||||
defaultModules
|
|
||||||
++ [
|
|
||||||
{
|
|
||||||
home-manager.users.michael = import ../user/environments/nixos-server/home.nix;
|
|
||||||
}
|
|
||||||
|
|
||||||
../machines/oracle/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
nova = mkNixos {
|
|
||||||
modules =
|
|
||||||
defaultModules
|
|
||||||
++ [
|
|
||||||
{
|
|
||||||
home-manager.users.michael = import ../user/environments/nixos-server/home.nix;
|
|
||||||
}
|
|
||||||
|
|
||||||
../machines/nova/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
work = mkNixos {
|
|
||||||
modules = [
|
|
||||||
inputs.nixos-wsl.nixosModules.default
|
|
||||||
../machines/work/configuration.nix
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,23 +0,0 @@
|
|||||||
{
|
|
||||||
self,
|
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
perSystem = {
|
|
||||||
lib,
|
|
||||||
system,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
pkgs = import inputs.nixpkgs {
|
|
||||||
inherit system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
overlays = builtins.attrValues self.overlays;
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
_module.args.pkgs = pkgs;
|
|
||||||
|
|
||||||
packages = import ../pkgs {
|
|
||||||
inherit inputs pkgs;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,8 +0,0 @@
|
|||||||
{inputs, ...}: {
|
|
||||||
imports = [inputs.treefmt-nix.flakeModule];
|
|
||||||
|
|
||||||
perSystem.treefmt = {
|
|
||||||
projectRootFile = "flake.nix";
|
|
||||||
programs.alejandra.enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
@ -19,6 +19,8 @@
|
|||||||
# $ nix search wget
|
# $ nix search wget
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
wget
|
wget
|
||||||
|
micro
|
||||||
|
gnome.gnome-tweaks
|
||||||
];
|
];
|
||||||
|
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
@ -44,8 +46,6 @@
|
|||||||
|
|
||||||
programs.zsh.enable = true;
|
programs.zsh.enable = true;
|
||||||
|
|
||||||
my.hyprland.enable = true;
|
|
||||||
|
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
# Define a user account. Don't forget to set a password with ‘passwd’.
|
||||||
users.users.michael = {
|
users.users.michael = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
|
@ -27,7 +27,7 @@
|
|||||||
# Video
|
# Video
|
||||||
ffmpeg
|
ffmpeg
|
||||||
# Spotify
|
# Spotify
|
||||||
master.spicetify-cli
|
unstable.spicetify-cli
|
||||||
# Java
|
# Java
|
||||||
checkstyle
|
checkstyle
|
||||||
# XCode
|
# XCode
|
||||||
@ -46,7 +46,6 @@
|
|||||||
eval `/usr/libexec/path_helper -s`
|
eval `/usr/libexec/path_helper -s`
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
enableGlobalCompInit = false;
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -56,6 +55,24 @@
|
|||||||
nix-daemon.enable = true;
|
nix-daemon.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
nixpkgs = {
|
||||||
|
# Workaround for pyopenssl being marked broken
|
||||||
|
config.allowBroken = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
nix = {
|
||||||
|
package = pkgs.nix;
|
||||||
|
gc = {
|
||||||
|
automatic = true;
|
||||||
|
interval.Day = 7;
|
||||||
|
options = "--delete-older-than 7d";
|
||||||
|
};
|
||||||
|
extraOptions = ''
|
||||||
|
experimental-features = nix-command flakes
|
||||||
|
'';
|
||||||
|
settings.auto-optimise-store = false;
|
||||||
|
};
|
||||||
|
|
||||||
system = {
|
system = {
|
||||||
# Since it's not possible to declare default shell, run this command after build
|
# Since it's not possible to declare default shell, run this command after build
|
||||||
activationScripts.postActivation.text = ''sudo chsh -s ${pkgs.zsh}/bin/zsh'';
|
activationScripts.postActivation.text = ''sudo chsh -s ${pkgs.zsh}/bin/zsh'';
|
||||||
|
@ -1,106 +0,0 @@
|
|||||||
# Edit this configuration file to define what should be installed on
|
|
||||||
# your system. Help is available in the configuration.nix(5) man page
|
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
|
||||||
{pkgs, ...}: {
|
|
||||||
imports = [
|
|
||||||
# Include the results of the hardware scan.
|
|
||||||
./hardware-configuration.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
# Bootloader.
|
|
||||||
boot.loader.systemd-boot.enable = true;
|
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
|
||||||
|
|
||||||
networking.hostName = "nova"; # Define your hostname.
|
|
||||||
|
|
||||||
# Enable networking
|
|
||||||
networking.useDHCP = false;
|
|
||||||
systemd.network.enable = true;
|
|
||||||
systemd.network.networks."10-wired" = {
|
|
||||||
matchConfig.Name = "enp1s0";
|
|
||||||
networkConfig = {
|
|
||||||
Address = "192.168.1.11/24";
|
|
||||||
Gateway = "192.168.1.1";
|
|
||||||
DNS = "192.168.1.1";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Set your time zone.
|
|
||||||
time.timeZone = "America/New_York";
|
|
||||||
|
|
||||||
# Select internationalisation properties.
|
|
||||||
i18n.defaultLocale = "en_US.UTF-8";
|
|
||||||
|
|
||||||
i18n.extraLocaleSettings = {
|
|
||||||
LC_ADDRESS = "en_US.UTF-8";
|
|
||||||
LC_IDENTIFICATION = "en_US.UTF-8";
|
|
||||||
LC_MEASUREMENT = "en_US.UTF-8";
|
|
||||||
LC_MONETARY = "en_US.UTF-8";
|
|
||||||
LC_NAME = "en_US.UTF-8";
|
|
||||||
LC_NUMERIC = "en_US.UTF-8";
|
|
||||||
LC_PAPER = "en_US.UTF-8";
|
|
||||||
LC_TELEPHONE = "en_US.UTF-8";
|
|
||||||
LC_TIME = "en_US.UTF-8";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Configure keymap in X11
|
|
||||||
services.xserver.xkb = {
|
|
||||||
layout = "us";
|
|
||||||
variant = "";
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.zsh.enable = true;
|
|
||||||
|
|
||||||
my.services.mealie.enable = true;
|
|
||||||
my.services.nextcloud.enable = true;
|
|
||||||
|
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
|
||||||
users.users.michael = {
|
|
||||||
isNormalUser = true;
|
|
||||||
description = "Michael Thomas";
|
|
||||||
extraGroups = ["networkmanager" "wheel"];
|
|
||||||
shell = pkgs.zsh;
|
|
||||||
packages = with pkgs; [];
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
# Neptune
|
|
||||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune"
|
|
||||||
# Oracle
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Allow unfree packages
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
|
||||||
|
|
||||||
# List packages installed in system profile. To search, run:
|
|
||||||
# $ nix search wget
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
];
|
|
||||||
|
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
|
||||||
# started in user sessions.
|
|
||||||
# programs.mtr.enable = true;
|
|
||||||
# programs.gnupg.agent = {
|
|
||||||
# enable = true;
|
|
||||||
# enableSSHSupport = true;
|
|
||||||
# };
|
|
||||||
|
|
||||||
# List services that you want to enable:
|
|
||||||
|
|
||||||
# Enable the OpenSSH daemon.
|
|
||||||
services.openssh.enable = true;
|
|
||||||
|
|
||||||
# Open ports in the firewall.
|
|
||||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
|
||||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
|
||||||
# Or disable the firewall altogether.
|
|
||||||
# networking.firewall.enable = false;
|
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
|
||||||
# settings for stateful data, like file locations and database versions
|
|
||||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
|
||||||
# this value at the release version of the first install of this system.
|
|
||||||
# Before changing this value read the documentation for this option
|
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
|
||||||
system.stateVersion = "24.05"; # Did you read the comment?
|
|
||||||
}
|
|
@ -1,39 +0,0 @@
|
|||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{
|
|
||||||
lib,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/profiles/qemu-guest.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["uhci_hcd" "ehci_pci" "ahci" "virtio_pci" "sr_mod" "virtio_blk"];
|
|
||||||
boot.initrd.kernelModules = [];
|
|
||||||
boot.kernelModules = ["kvm-amd"];
|
|
||||||
boot.extraModulePackages = [];
|
|
||||||
|
|
||||||
fileSystems."/" = {
|
|
||||||
device = "/dev/disk/by-uuid/51a7185f-56b6-4589-8a57-4543bae6e19d";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-uuid/41B1-929E";
|
|
||||||
fsType = "vfat";
|
|
||||||
options = ["fmask=0022" "dmask=0022"];
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [];
|
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
|
||||||
# still possible to use this option, but it's recommended to use it in conjunction
|
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
|
||||||
networking.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.enp1s0.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
}
|
|
@ -1,123 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
./hardware-configuration.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.tmp.cleanOnBoot = true;
|
|
||||||
zramSwap.enable = true;
|
|
||||||
|
|
||||||
networking.hostName = "oracle";
|
|
||||||
networking.domain = "subnet08161027.vcn08161027.oraclevcn.com";
|
|
||||||
networking.firewall = {
|
|
||||||
enable = true;
|
|
||||||
allowedUDPPorts = [51820];
|
|
||||||
};
|
|
||||||
|
|
||||||
services.openssh.enable = true;
|
|
||||||
services.openssh.settings = {
|
|
||||||
PasswordAuthentication = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [wireguard-tools];
|
|
||||||
|
|
||||||
# Wireguard tunnel
|
|
||||||
age.secrets.wireguardOracle.file = ../../secrets/wireguard-oracle.age;
|
|
||||||
networking.wg-quick.interfaces = {
|
|
||||||
wg0 = {
|
|
||||||
address = ["10.0.10.1/24"];
|
|
||||||
listenPort = 51820;
|
|
||||||
privateKeyFile = config.age.secrets.wireguardOracle.path;
|
|
||||||
|
|
||||||
peers = [
|
|
||||||
{
|
|
||||||
publicKey = "iKJO9Q8LsdCdApapTX9CJmrtAKn1TYhg4YUiBUBPzmo=";
|
|
||||||
allowedIPs = ["10.0.10.2/32"];
|
|
||||||
}
|
|
||||||
{
|
|
||||||
publicKey = "IM7i+2BFsa+XyA4V4jd8iM+jpW307rDEkPOGdSddfzI=";
|
|
||||||
allowedIPs = ["10.0.10.3/32"];
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.zsh.enable = true;
|
|
||||||
environment.variables.EDITOR = "nvim";
|
|
||||||
|
|
||||||
users.users.michael = {
|
|
||||||
isNormalUser = true;
|
|
||||||
home = "/home/michael";
|
|
||||||
description = "Michael Thomas";
|
|
||||||
extraGroups = ["wheel" "networkmanager"];
|
|
||||||
shell = pkgs.zsh;
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
''ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune''
|
|
||||||
|
|
||||||
''ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDQr9lluvuGk3qU1bE7HrrZcE36x5hhD5Dat+E4My55aoh+Df/JeuWMPvzS4zLKMsIIZCUX6kbjvTtvWe7gPLflhDOUGI947MK9B01pojDn0LBugz57Ai9fPlG5+AlMWaxWitmP8JB637oxBpqesqxHdiEKW25u9t2qOvjX3kCdcoSYDlW72Xm8ZI9+qKcAlGLnFhiQxM18rjHcZYdn9ZyWRRSC1ocuTqnbh5lsYoMhD+4QWo5LmwMVjr5uix0i+ktqKzENaiDgA/MQIWQrHqUavfjvMRyyQO7bScVTe/PllKFpLOBym2SLC5hD7vG69BBo0dQUto8tAbIgI9Tmv1dx michael@venus''
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [
|
|
||||||
{
|
|
||||||
device = "/var/lib/swapfile";
|
|
||||||
size = 4 * 1024;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
# Services
|
|
||||||
services.caddy = {
|
|
||||||
enable = true;
|
|
||||||
package = let
|
|
||||||
caddyWithPlugins = builtins.fetchurl {
|
|
||||||
url = "https://raw.githubusercontent.com/jpds/nixpkgs/a33b02fa9d664f31dadc8a874eb1a5dbaa9f4ecf/pkgs/servers/caddy/default.nix";
|
|
||||||
sha256 = "sha256:1x1g6qyhmclz2jyc5nmfjsri3xx4pw5rd15n2xjkxlgdcvywcv5f";
|
|
||||||
};
|
|
||||||
in (pkgs.callPackage "${caddyWithPlugins}" {
|
|
||||||
externalPlugins = [
|
|
||||||
{
|
|
||||||
name = "greenpau/caddy-security";
|
|
||||||
repo = "github.com/greenpau/caddy-security";
|
|
||||||
version = "v1.1.23";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
vendorHash = "sha256-rGNyeHZZBxVM8GMUQMV/JzkK9S/l8tefaQde/d4x9LA=";
|
|
||||||
});
|
|
||||||
globalConfig = ''
|
|
||||||
email michaelhthomas@outlook.com
|
|
||||||
'';
|
|
||||||
virtualHosts = {
|
|
||||||
"auth.s.michaelt.xyz".extraConfig = ''
|
|
||||||
reverse_proxy http://10.0.10.2:7654
|
|
||||||
'';
|
|
||||||
"traggo.s.michaelt.xyz".extraConfig = ''
|
|
||||||
reverse_proxy http://10.0.10.2:3030
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
networking.firewall.allowedTCPPorts = [80 443];
|
|
||||||
|
|
||||||
my.server = {
|
|
||||||
domain = "s.michaelt.xyz";
|
|
||||||
proxyIP = "10.0.10.2";
|
|
||||||
};
|
|
||||||
my.services.homer.enable = true;
|
|
||||||
my.services.forgejo.proxy = true;
|
|
||||||
|
|
||||||
services.uptime-kuma = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
port = "3001";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.caddy.virtualHosts."status.gringotts.michaelt.xyz".extraConfig = ''
|
|
||||||
reverse_proxy http://localhost:${config.services.uptime-kuma.settings.PORT}
|
|
||||||
'';
|
|
||||||
|
|
||||||
system.stateVersion = "23.11";
|
|
||||||
}
|
|
@ -1,18 +0,0 @@
|
|||||||
{modulesPath, ...}: {
|
|
||||||
imports = [(modulesPath + "/profiles/qemu-guest.nix")];
|
|
||||||
boot.loader.grub = {
|
|
||||||
efiSupport = true;
|
|
||||||
efiInstallAsRemovable = true;
|
|
||||||
device = "nodev";
|
|
||||||
};
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-uuid/97E5-76C2";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
|
||||||
boot.initrd.availableKernelModules = ["ata_piix" "uhci_hcd" "xen_blkfront" "vmw_pvscsi"];
|
|
||||||
boot.initrd.kernelModules = ["nvme"];
|
|
||||||
fileSystems."/" = {
|
|
||||||
device = "/dev/mapper/centosvolume-root";
|
|
||||||
fsType = "xfs";
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,97 +0,0 @@
|
|||||||
{pkgs, ...}: {
|
|
||||||
imports = [
|
|
||||||
# Include the results of the hardware scan.
|
|
||||||
./hardware-configuration.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
networking.hostName = "terra"; # Define your hostname.
|
|
||||||
networking.nameservers = ["1.1.1.1" "8.8.8.8"];
|
|
||||||
networking.firewall = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
networking.networkmanager.enable = true;
|
|
||||||
|
|
||||||
# Set your time zone.
|
|
||||||
time.timeZone = "America/New_York";
|
|
||||||
|
|
||||||
# Select internationalisation properties.
|
|
||||||
i18n.defaultLocale = "en_US.UTF-8";
|
|
||||||
|
|
||||||
i18n.extraLocaleSettings = {
|
|
||||||
LC_ADDRESS = "en_US.UTF-8";
|
|
||||||
LC_IDENTIFICATION = "en_US.UTF-8";
|
|
||||||
LC_MEASUREMENT = "en_US.UTF-8";
|
|
||||||
LC_MONETARY = "en_US.UTF-8";
|
|
||||||
LC_NAME = "en_US.UTF-8";
|
|
||||||
LC_NUMERIC = "en_US.UTF-8";
|
|
||||||
LC_PAPER = "en_US.UTF-8";
|
|
||||||
LC_TELEPHONE = "en_US.UTF-8";
|
|
||||||
LC_TIME = "en_US.UTF-8";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Configure keymap in X11
|
|
||||||
services.xserver.xkb = {
|
|
||||||
layout = "us";
|
|
||||||
variant = "";
|
|
||||||
};
|
|
||||||
|
|
||||||
services.openssh = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
PermitRootLogin = "no";
|
|
||||||
PasswordAuthentication = false;
|
|
||||||
AllowUsers = ["michael"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.zsh.enable = true;
|
|
||||||
environment.variables.EDITOR = "nvim";
|
|
||||||
|
|
||||||
my.hyprland.enable = true;
|
|
||||||
my.libreoffice.enable = true;
|
|
||||||
my.steam.enable = true;
|
|
||||||
|
|
||||||
# Define a user account. Don't forget to set a password with ‘passwd’.
|
|
||||||
users.users.michael = {
|
|
||||||
isNormalUser = true;
|
|
||||||
description = "Michael Thomas";
|
|
||||||
extraGroups = ["wheel" "docker" "podman" "adbusers" "dialout" "libvirtd" "networkmanager"];
|
|
||||||
shell = pkgs.zsh;
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
# Neptune
|
|
||||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune"
|
|
||||||
# Oracle
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Enablle libvirtd
|
|
||||||
virtualisation.libvirtd.enable = true;
|
|
||||||
boot.kernelModules = ["kvm-amd" "kvm-intel"];
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
obs-studio
|
|
||||||
kdenlive
|
|
||||||
inkscape
|
|
||||||
thunderbird
|
|
||||||
|
|
||||||
virt-manager
|
|
||||||
virtiofsd
|
|
||||||
|
|
||||||
# GTK Discord Client
|
|
||||||
unstable.dissent
|
|
||||||
|
|
||||||
prismlauncher
|
|
||||||
lutris
|
|
||||||
|
|
||||||
android-studio
|
|
||||||
];
|
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
|
||||||
# settings for stateful data, like file locations and database versions
|
|
||||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
|
||||||
# this value at the release version of the first install of this system.
|
|
||||||
# Before changing this value read the documentation for this option
|
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
|
||||||
system.stateVersion = "23.11"; # Did you read the comment?
|
|
||||||
}
|
|
@ -1,50 +0,0 @@
|
|||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"];
|
|
||||||
boot.initrd.kernelModules = ["amdgpu"];
|
|
||||||
boot.kernelModules = ["kvm-amd"];
|
|
||||||
boot.kernelPackages = pkgs.linuxKernel.packages.linux_6_8;
|
|
||||||
boot.extraModulePackages = [];
|
|
||||||
|
|
||||||
hardware.opengl.driSupport = true;
|
|
||||||
hardware.opengl.driSupport32Bit = true;
|
|
||||||
services.xserver.videoDrivers = ["amdgpu"];
|
|
||||||
|
|
||||||
fileSystems."/" = {
|
|
||||||
device = "/dev/disk/by-uuid/fa11ad2d-97d9-4e87-8fe9-f2cae0d9894e";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
|
||||||
device = "/dev/disk/by-uuid/2FCC-48ED";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices = [
|
|
||||||
{device = "/dev/disk/by-uuid/b378f2ec-0bbb-4896-92b5-ef08c707555d";}
|
|
||||||
];
|
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
|
||||||
# still possible to use this option, but it's recommended to use it in conjunction
|
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
|
||||||
networking.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.enp8s0.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.enp9s0u4u4.useDHCP = lib.mkDefault true;
|
|
||||||
# networking.interfaces.wlp7s0.useDHCP = lib.mkDefault true;
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
}
|
|
@ -1,40 +1,10 @@
|
|||||||
{
|
{pkgs, ...}: {
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
imports = [
|
||||||
# Include the results of the hardware scan.
|
# Include the results of the hardware scan.
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
networking.hostName = "venus"; # Define your hostname.
|
networking.hostName = "venus"; # Define your hostname.
|
||||||
networking.nameservers = ["1.1.1.1" "8.8.8.8"];
|
|
||||||
networking.firewall = {
|
|
||||||
enable = true;
|
|
||||||
interfaces."wg0" = {
|
|
||||||
allowedTCPPorts = [7654 3030];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Wireguard tunnel to oracle
|
|
||||||
age.secrets.wireguardThinkcentre.file = ../../secrets/wireguard-thinkcentre.age;
|
|
||||||
networking.wg-quick.interfaces = {
|
|
||||||
wg0 = {
|
|
||||||
address = ["10.0.10.2/32"];
|
|
||||||
listenPort = 51820;
|
|
||||||
privateKeyFile = config.age.secrets.wireguardThinkcentre.path;
|
|
||||||
|
|
||||||
peers = [
|
|
||||||
{
|
|
||||||
publicKey = "sdqT2l1HRe9rDYejJ+luQK8zdC+/KqDuQ1rpvZq/KlQ=";
|
|
||||||
endpoint = "150.136.162.107:51820";
|
|
||||||
allowedIPs = ["10.0.10.1/24"];
|
|
||||||
persistentKeepalive = 25;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Set your time zone.
|
# Set your time zone.
|
||||||
time.timeZone = "America/New_York";
|
time.timeZone = "America/New_York";
|
||||||
@ -55,72 +25,9 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
# Configure keymap in X11
|
# Configure keymap in X11
|
||||||
services.xserver.xkb = {
|
services.xserver = {
|
||||||
layout = "us";
|
layout = "us";
|
||||||
variant = "";
|
xkbVariant = "";
|
||||||
};
|
|
||||||
|
|
||||||
services.openssh = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
PermitRootLogin = "no";
|
|
||||||
PasswordAuthentication = false;
|
|
||||||
AllowUsers = ["michael"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
my.services.homepage-dashboard = {
|
|
||||||
enable = true;
|
|
||||||
port = 8082;
|
|
||||||
};
|
|
||||||
|
|
||||||
age.secrets.keycloakDb.file = ../../secrets/keycloak-db.age;
|
|
||||||
services.keycloak = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.unstable.keycloak;
|
|
||||||
settings = {
|
|
||||||
hostname-url = "https://auth.s.michaelt.xyz";
|
|
||||||
hostname-admin-url = "https://auth.s.michaelt.xyz";
|
|
||||||
hostname-strict = false;
|
|
||||||
hostname-strict-https = false;
|
|
||||||
# proxy-headers = "xforwarded";
|
|
||||||
proxy = "edge";
|
|
||||||
http-enabled = true;
|
|
||||||
http-port = 7654;
|
|
||||||
};
|
|
||||||
database.passwordFile = config.age.secrets.keycloakDb.path;
|
|
||||||
themes = with pkgs; {
|
|
||||||
keywind = keycloak-theme-keywind;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
virtualisation.oci-containers.backend = "podman";
|
|
||||||
|
|
||||||
virtualisation.oci-containers.containers.traggo = {
|
|
||||||
image = "traggo/server:latest";
|
|
||||||
autoStart = true;
|
|
||||||
ports = ["3030:3030"];
|
|
||||||
volumes = [
|
|
||||||
"/var/lib/traggo/data:/opt/traggo/data"
|
|
||||||
];
|
|
||||||
environment = {
|
|
||||||
TRAGGO_DEFAULT_USER_NAME = "michael";
|
|
||||||
TRAGGO_DEFAULT_USER_PASS = "NfvzH2H5eNJLAJb6";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
my.server = {
|
|
||||||
domain = "s.michaelt.xyz";
|
|
||||||
firewallInterface = "wg0";
|
|
||||||
};
|
|
||||||
|
|
||||||
# TODO: Disable desktop
|
|
||||||
my.hyprland.enable = true;
|
|
||||||
|
|
||||||
my.services.forgejo = {
|
|
||||||
enable = true;
|
|
||||||
port = 3000;
|
|
||||||
actions.enable = true;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [
|
swapDevices = [
|
||||||
@ -139,12 +46,6 @@
|
|||||||
description = "Michael Thomas";
|
description = "Michael Thomas";
|
||||||
extraGroups = ["wheel" "docker" "podman" "adbusers" "dialout"];
|
extraGroups = ["wheel" "docker" "podman" "adbusers" "dialout"];
|
||||||
shell = pkgs.zsh;
|
shell = pkgs.zsh;
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
# Neptune
|
|
||||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune"
|
|
||||||
# Oracle
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
# This value determines the NixOS release from which the default
|
||||||
|
@ -1,33 +1,29 @@
|
|||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
config,
|
imports =
|
||||||
lib,
|
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||||
pkgs,
|
];
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod"];
|
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
|
||||||
boot.initrd.kernelModules = [];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [];
|
boot.kernelModules = [ ];
|
||||||
boot.extraModulePackages = [];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" =
|
||||||
device = "/dev/disk/by-uuid/2b1793d6-feff-48df-9180-03e8c2bef7bf";
|
{ device = "/dev/disk/by-uuid/2b1793d6-feff-48df-9180-03e8c2bef7bf";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
fileSystems."/boot" =
|
||||||
device = "/dev/disk/by-uuid/2082-08EF";
|
{ device = "/dev/disk/by-uuid/2082-08EF";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [];
|
swapDevices = [ ];
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||||
|
@ -1,16 +1,57 @@
|
|||||||
{pkgs, ...}: {
|
{
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
modulesPath,
|
||||||
|
inputs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib; let
|
||||||
|
defaultUser = "michael";
|
||||||
|
in {
|
||||||
|
imports = [
|
||||||
|
"${modulesPath}/profiles/minimal.nix"
|
||||||
|
|
||||||
|
inputs.nixos-wsl.nixosModules.wsl
|
||||||
|
];
|
||||||
|
|
||||||
wsl = {
|
wsl = {
|
||||||
enable = true;
|
enable = true;
|
||||||
defaultUser = "michael";
|
wslConf = {
|
||||||
interop.includePath = false;
|
automount.root = "/mnt";
|
||||||
|
interop.appendWindowsPath = false;
|
||||||
|
};
|
||||||
|
defaultUser = defaultUser;
|
||||||
|
startMenuLaunchers = true;
|
||||||
|
|
||||||
|
# Enable integration with Docker Desktop (needs to be installed)
|
||||||
|
# docker.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
time.timeZone = "America/New_York";
|
||||||
|
|
||||||
|
programs.adb.enable = true;
|
||||||
|
|
||||||
|
# Required because for some reason WSL kernel doesn't play well with nftables
|
||||||
|
networking.firewall.package = pkgs.iptables-legacy;
|
||||||
|
|
||||||
|
home-manager = {
|
||||||
|
users.michael = import ../../user/environments/wsl/home.nix pkgs;
|
||||||
|
useGlobalPkgs = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
nvim-custom
|
wget
|
||||||
];
|
];
|
||||||
|
|
||||||
my.zsh.enable = true;
|
services.vscode-server.enable = true;
|
||||||
|
|
||||||
system.stateVersion = "24.05";
|
programs.zsh.enable = true;
|
||||||
hm.home.stateVersion = "24.05";
|
|
||||||
|
users.users.${defaultUser} = {
|
||||||
|
uid = pkgs.lib.mkForce 1001;
|
||||||
|
extraGroups = ["wheel" "docker" "podman"];
|
||||||
|
shell = pkgs.zsh;
|
||||||
|
};
|
||||||
|
|
||||||
|
system.stateVersion = "22.05";
|
||||||
}
|
}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
# Enable Avahi Network Discovery
|
# Enable Avahi Network Discovery
|
||||||
services.avahi = {
|
services.avahi = {
|
||||||
enable = true;
|
enable = true;
|
||||||
nssmdns4 = true;
|
nssmdns = true;
|
||||||
publish.enable = true;
|
publish.enable = true;
|
||||||
publish.addresses = true;
|
publish.addresses = true;
|
||||||
};
|
};
|
||||||
|
@ -4,8 +4,9 @@
|
|||||||
./bluetooth.nix
|
./bluetooth.nix
|
||||||
./bootloader.nix
|
./bootloader.nix
|
||||||
./cups.nix
|
./cups.nix
|
||||||
|
./flatpak.nix
|
||||||
./fonts.nix
|
./fonts.nix
|
||||||
./hosts.nix
|
./nix.nix
|
||||||
./sound.nix
|
./sound.nix
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,4 @@
|
|||||||
{pkgs, ...}: {
|
{pkgs, ...}: {
|
||||||
virtualisation.containers.enable = true;
|
|
||||||
|
|
||||||
# Enable Podman w/ docker compose compatibility
|
# Enable Podman w/ docker compose compatibility
|
||||||
virtualisation.podman = {
|
virtualisation.podman = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
imports = [
|
|
||||||
./services
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
networking.hosts = {
|
|
||||||
"150.136.162.107" = ["oracle"];
|
|
||||||
};
|
|
||||||
}
|
|
39
modules/hyprland.nix
Normal file
39
modules/hyprland.nix
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
programs.hyprland = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.unstable.hyprland;
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
# Theme
|
||||||
|
adw-gtk3
|
||||||
|
|
||||||
|
# Greeter
|
||||||
|
cage
|
||||||
|
greetd.gtkgreet
|
||||||
|
|
||||||
|
# Applications
|
||||||
|
gnome.nautilus
|
||||||
|
gnome.sushi
|
||||||
|
gnome.eog
|
||||||
|
gnome.totem
|
||||||
|
gnome.cheese
|
||||||
|
gnome.file-roller
|
||||||
|
gnome.gnome-weather
|
||||||
|
gnome.gnome-contacts
|
||||||
|
gnome.gnome-calendar
|
||||||
|
gnome.gnome-screenshot
|
||||||
|
gnome.gnome-dictionary
|
||||||
|
gnome.gnome-font-viewer
|
||||||
|
gnome.gnome-system-monitor
|
||||||
|
];
|
||||||
|
|
||||||
|
services.greetd = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
default_session = {
|
||||||
|
command = "cage -s -- gtkgreet --command=Hyprland";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
20
modules/nix.nix
Normal file
20
modules/nix.nix
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
nix = {
|
||||||
|
extraOptions = ''
|
||||||
|
experimental-features = flakes nix-command
|
||||||
|
'';
|
||||||
|
# this is required until nix 2.4 is released
|
||||||
|
package = pkgs.nixFlakes;
|
||||||
|
|
||||||
|
settings.auto-optimise-store = true;
|
||||||
|
gc = {
|
||||||
|
automatic = true;
|
||||||
|
dates = "weekly";
|
||||||
|
options = "--delete-older-than 30d";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
nixpkgs.config = {
|
||||||
|
allowUnfree = true;
|
||||||
|
};
|
||||||
|
}
|
@ -1,9 +0,0 @@
|
|||||||
{
|
|
||||||
imports = [
|
|
||||||
./forgejo
|
|
||||||
./homepage-dashboard
|
|
||||||
./homer
|
|
||||||
./mealie
|
|
||||||
./nextcloud
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,234 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.my.services.forgejo;
|
|
||||||
inherit (config.my.server) domain proxyIP firewallInterface;
|
|
||||||
forgejoDomain = "git.${domain}";
|
|
||||||
forgejoUrl = "https://${forgejoDomain}";
|
|
||||||
|
|
||||||
# for nix actions runner
|
|
||||||
storeDeps = pkgs.runCommand "store-deps" {} ''
|
|
||||||
mkdir -p $out/bin
|
|
||||||
for dir in ${
|
|
||||||
toString [
|
|
||||||
pkgs.coreutils
|
|
||||||
pkgs.findutils
|
|
||||||
pkgs.gnugrep
|
|
||||||
pkgs.gawk
|
|
||||||
pkgs.git
|
|
||||||
pkgs.nix
|
|
||||||
pkgs.bash
|
|
||||||
pkgs.jq
|
|
||||||
pkgs.nodejs
|
|
||||||
pkgs.devenv
|
|
||||||
]
|
|
||||||
}; do
|
|
||||||
for bin in "$dir"/bin/*; do
|
|
||||||
ln -s "$bin" "$out/bin/$(basename "$bin")"
|
|
||||||
done
|
|
||||||
done
|
|
||||||
|
|
||||||
# Add SSL CA certs
|
|
||||||
mkdir -p $out/etc/ssl/certs
|
|
||||||
cp -a "${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt" $out/etc/ssl/certs/ca-bundle.crt
|
|
||||||
'';
|
|
||||||
in {
|
|
||||||
options.my.services.forgejo = {
|
|
||||||
enable = mkEnableOption "Forgejo";
|
|
||||||
proxy = mkEnableOption "Forgejo reverse proxy entry";
|
|
||||||
actions = mkOption {
|
|
||||||
type = types.submodule (_: {
|
|
||||||
options.enable = mkEnableOption "Forgejo Actions";
|
|
||||||
});
|
|
||||||
default = {};
|
|
||||||
};
|
|
||||||
subdomain = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "git";
|
|
||||||
example = "git";
|
|
||||||
description = "Subdomain to use for the service.";
|
|
||||||
};
|
|
||||||
port = mkOption {
|
|
||||||
type = types.port;
|
|
||||||
default = 3000;
|
|
||||||
example = 8080;
|
|
||||||
description = "HTTP port for the Forgejo service.";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkMerge [
|
|
||||||
(mkIf cfg.enable {
|
|
||||||
age.secrets.forgejoSendgridKey = {
|
|
||||||
file = ../../../secrets/sendgrid-key.age;
|
|
||||||
owner = "forgejo";
|
|
||||||
group = "forgejo";
|
|
||||||
};
|
|
||||||
services.forgejo = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.unstable.forgejo;
|
|
||||||
settings.server = {
|
|
||||||
DOMAIN = forgejoDomain;
|
|
||||||
ROOT_URL = forgejoUrl;
|
|
||||||
DISABLE_SSH = true;
|
|
||||||
HTTP_PORT = cfg.port;
|
|
||||||
};
|
|
||||||
settings.session = {
|
|
||||||
COOKIE_SECURE = true;
|
|
||||||
};
|
|
||||||
settings.service = {
|
|
||||||
DISABLE_REGISTRATION = true;
|
|
||||||
ENABLE_NOTIFY_MAIL = true;
|
|
||||||
};
|
|
||||||
settings.admin = {
|
|
||||||
DEFAULT_EMAIL_NOTIFICATIONS = "onmention";
|
|
||||||
};
|
|
||||||
settings.openid = {
|
|
||||||
ENABLE_OPENID_SIGNIN = true;
|
|
||||||
ENABLE_OPENID_SIGNUP = true;
|
|
||||||
};
|
|
||||||
settings.oauth2_client = {
|
|
||||||
ENABLE_AUTO_REGISTRATION = true;
|
|
||||||
};
|
|
||||||
settings.mailer = {
|
|
||||||
ENABLED = true;
|
|
||||||
FROM = "forgejo@michaelt.xyz";
|
|
||||||
PROTOCOL = "starttls";
|
|
||||||
SMTP_ADDR = "smtp.sendgrid.net";
|
|
||||||
SMTP_PORT = 587;
|
|
||||||
USER = "apikey";
|
|
||||||
};
|
|
||||||
mailerPasswordFile = config.age.secrets.forgejoSendgridKey.path;
|
|
||||||
};
|
|
||||||
|
|
||||||
networking.firewall.interfaces."${firewallInterface}".allowedTCPPorts = [cfg.port];
|
|
||||||
})
|
|
||||||
(mkIf cfg.actions.enable {
|
|
||||||
# build image // taken from https://git.clan.lol/clan/clan-infra/src/branch/main/modules/web01/gitea/actions-runner.nix
|
|
||||||
# everything here has no dependencies on the store
|
|
||||||
systemd.services.forgejo-runner-nix-image = {
|
|
||||||
wantedBy = ["multi-user.target"];
|
|
||||||
after = ["podman.service"];
|
|
||||||
requires = ["podman.service"];
|
|
||||||
path = [
|
|
||||||
config.virtualisation.podman.package
|
|
||||||
pkgs.gnutar
|
|
||||||
pkgs.shadow
|
|
||||||
pkgs.getent
|
|
||||||
];
|
|
||||||
# we also include etc here because the cleanup job also wants the nixuser to be present
|
|
||||||
script = ''
|
|
||||||
set -eux -o pipefail
|
|
||||||
mkdir -p etc/nix
|
|
||||||
|
|
||||||
# Create an unpriveleged user that we can use also without the run-as-user.sh script
|
|
||||||
touch etc/passwd etc/group
|
|
||||||
groupid=$(cut -d: -f3 < <(getent group nixuser))
|
|
||||||
userid=$(cut -d: -f3 < <(getent passwd nixuser))
|
|
||||||
groupadd --prefix $(pwd) --gid "$groupid" nixuser
|
|
||||||
emptypassword='$6$1ero.LwbisiU.h3D$GGmnmECbPotJoPQ5eoSTD6tTjKnSWZcjHoVTkxFLZP17W9hRi/XkmCiAMOfWruUwy8gMjINrBMNODc7cYEo4K.'
|
|
||||||
useradd --prefix $(pwd) -p "$emptypassword" -m -d /tmp -u "$userid" -g "$groupid" -G nixuser nixuser
|
|
||||||
|
|
||||||
cat <<NIX_CONFIG > etc/nix/nix.conf
|
|
||||||
accept-flake-config = true
|
|
||||||
experimental-features = nix-command flakes
|
|
||||||
NIX_CONFIG
|
|
||||||
|
|
||||||
cat <<NSSWITCH > etc/nsswitch.conf
|
|
||||||
passwd: files mymachines systemd
|
|
||||||
group: files mymachines systemd
|
|
||||||
shadow: files
|
|
||||||
|
|
||||||
hosts: files mymachines dns myhostname
|
|
||||||
networks: files
|
|
||||||
|
|
||||||
ethers: files
|
|
||||||
services: files
|
|
||||||
protocols: files
|
|
||||||
rpc: files
|
|
||||||
NSSWITCH
|
|
||||||
|
|
||||||
# list the content as it will be imported into the container
|
|
||||||
tar -cv . | tar -tvf -
|
|
||||||
tar -cv . | podman import - forgejo-runner-nix
|
|
||||||
'';
|
|
||||||
serviceConfig = {
|
|
||||||
RuntimeDirectory = "forgejo-runner-nix-image";
|
|
||||||
WorkingDirectory = "/run/forgejo-runner-nix-image";
|
|
||||||
Type = "oneshot";
|
|
||||||
RemainAfterExit = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
users.users.nixuser = {
|
|
||||||
group = "nixuser";
|
|
||||||
description = "Used for running nix ci jobs";
|
|
||||||
home = "/var/empty";
|
|
||||||
isSystemUser = true;
|
|
||||||
};
|
|
||||||
users.groups.nixuser = {};
|
|
||||||
|
|
||||||
# configure the actions runner itself
|
|
||||||
age.secrets.forgejoActions.file = ../../../secrets/forgejo-actions.age;
|
|
||||||
services.gitea-actions-runner = mkIf cfg.actions.enable {
|
|
||||||
package = pkgs.unstable.forgejo-runner;
|
|
||||||
instances.venus = {
|
|
||||||
enable = true;
|
|
||||||
name = "venus-nix-runner";
|
|
||||||
url = forgejoUrl;
|
|
||||||
settings = {
|
|
||||||
# options = "-v /var/run/podman/podman.sock:/var/run/podman/podman.sock";
|
|
||||||
runner = {
|
|
||||||
capacity = 1;
|
|
||||||
timeout = "45m";
|
|
||||||
};
|
|
||||||
container = {
|
|
||||||
options = "-e NIX_BUILD_SHELL=/bin/bash -e PAGER=cat -e PATH=/bin -e SSL_CERT_FILE=/etc/ssl/certs/ca-bundle.crt --device /dev/kvm -v /nix:/nix -v ${storeDeps}/bin:/bin -v ${storeDeps}/etc/ssl:/etc/ssl --user nixuser --device=/dev/kvm";
|
|
||||||
# privileged = true;
|
|
||||||
valid_volumes = [
|
|
||||||
"/nix"
|
|
||||||
"${storeDeps}/bin"
|
|
||||||
"${storeDeps}/etc/ssl"
|
|
||||||
];
|
|
||||||
# force_pull = false;
|
|
||||||
network = "bridge";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
labels = [
|
|
||||||
"nix:docker://forgejo-runner-nix"
|
|
||||||
];
|
|
||||||
tokenFile = config.age.secrets.forgejoActions.path;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
})
|
|
||||||
(mkIf cfg.proxy {
|
|
||||||
services.caddy.virtualHosts."${forgejoDomain}".extraConfig = ''
|
|
||||||
handle_errors {
|
|
||||||
respond "This server is currently unavailable." 502
|
|
||||||
}
|
|
||||||
|
|
||||||
redir /user/login /user/oauth2/Keycloak?{query}
|
|
||||||
|
|
||||||
reverse_proxy http://${proxyIP}:${toString cfg.port}
|
|
||||||
'';
|
|
||||||
|
|
||||||
webapps.dashboardCategories = [
|
|
||||||
{
|
|
||||||
name = "Git";
|
|
||||||
tag = "git";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
webapps.apps.forgejo.dashboard = {
|
|
||||||
name = "Forgejo";
|
|
||||||
category = "git";
|
|
||||||
icon = "git-alt";
|
|
||||||
url = forgejoUrl;
|
|
||||||
description = "Beyond coding. We forge.";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,73 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.my.services.homepage-dashboard;
|
|
||||||
inherit (config.my.server) domain proxyIP firewallInterface;
|
|
||||||
in {
|
|
||||||
disabledModules = ["services/misc/homepage-dashboard.nix"];
|
|
||||||
|
|
||||||
imports = [
|
|
||||||
# Use homepage-dashboard service from nixos-unstable channel.
|
|
||||||
"${inputs.unstable}/nixos/modules/services/misc/homepage-dashboard.nix"
|
|
||||||
];
|
|
||||||
|
|
||||||
options.my.services.homepage-dashboard = {
|
|
||||||
enable = mkEnableOption "Homepage Dashboard";
|
|
||||||
proxy = mkEnableOption "Homepage Dashboard reverse proxy entry";
|
|
||||||
port = mkOption {
|
|
||||||
type = types.port;
|
|
||||||
default = 8082;
|
|
||||||
description = "HTTP port for the homepage-dashboard service.";
|
|
||||||
};
|
|
||||||
services = mkOption {
|
|
||||||
type = types.attrs;
|
|
||||||
default = {};
|
|
||||||
description = "Attrset of services by group.";
|
|
||||||
example = ''
|
|
||||||
{
|
|
||||||
Group = {
|
|
||||||
App = {
|
|
||||||
href = "https://example.com";
|
|
||||||
description = "An amazing app!";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkMerge [
|
|
||||||
(mkIf cfg.enable {
|
|
||||||
services.homepage-dashboard = {
|
|
||||||
enable = true;
|
|
||||||
listenPort = cfg.port;
|
|
||||||
settings.logpath = "/var/log/homepage-dashboard";
|
|
||||||
# Convert services to YAML format
|
|
||||||
services =
|
|
||||||
lib.mapAttrsToList (
|
|
||||||
groupName: groupAttrs: {
|
|
||||||
${groupName} = (
|
|
||||||
lib.mapAttrsToList (
|
|
||||||
serviceName: serviceAttrs: {${serviceName} = serviceAttrs;}
|
|
||||||
)
|
|
||||||
groupAttrs
|
|
||||||
);
|
|
||||||
}
|
|
||||||
)
|
|
||||||
cfg.services;
|
|
||||||
};
|
|
||||||
systemd.services.homepage-dashboard.environment.LOG_TARGETS = "stdout";
|
|
||||||
|
|
||||||
networking.firewall.interfaces."${firewallInterface}".allowedTCPPorts = [cfg.port];
|
|
||||||
})
|
|
||||||
(mkIf cfg.proxy {
|
|
||||||
services.caddy.virtualHosts."${domain}".extraConfig = ''
|
|
||||||
reverse_proxy http://${proxyIP}:${toString cfg.port}
|
|
||||||
'';
|
|
||||||
})
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,139 +0,0 @@
|
|||||||
# Heavily inspired by https://github.com/Stunkymonkey/nixos/blob/b061b1785b4d07f9032b8cf17e866ff9dbc947b0/modules/services/homer/config.nix
|
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
options.webapps = {
|
|
||||||
dashboardCategories = lib.mkOption {
|
|
||||||
type = lib.types.listOf (lib.types.submodule {
|
|
||||||
options = {
|
|
||||||
name = lib.mkOption {
|
|
||||||
type = lib.types.str;
|
|
||||||
description = ''
|
|
||||||
Category name.
|
|
||||||
'';
|
|
||||||
example = "Applications";
|
|
||||||
};
|
|
||||||
tag = lib.mkOption {
|
|
||||||
type = lib.types.str;
|
|
||||||
description = ''
|
|
||||||
Category tag.
|
|
||||||
'';
|
|
||||||
example = "app";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
});
|
|
||||||
description = ''
|
|
||||||
App categories to display on the dashboard.
|
|
||||||
'';
|
|
||||||
example = [
|
|
||||||
{
|
|
||||||
name = "Application";
|
|
||||||
tag = "app";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
default = [];
|
|
||||||
};
|
|
||||||
|
|
||||||
apps = lib.mkOption {
|
|
||||||
type =
|
|
||||||
lib.types.attrsOf
|
|
||||||
(lib.types.submodule {
|
|
||||||
options = {
|
|
||||||
dashboard = {
|
|
||||||
url = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.str;
|
|
||||||
description = ''
|
|
||||||
Url to webapp
|
|
||||||
'';
|
|
||||||
example = "http://192.168.1.10:1234";
|
|
||||||
default = null;
|
|
||||||
};
|
|
||||||
name = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.str;
|
|
||||||
description = ''
|
|
||||||
Application name.
|
|
||||||
'';
|
|
||||||
example = "App";
|
|
||||||
default = null;
|
|
||||||
};
|
|
||||||
description = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.str;
|
|
||||||
description = ''
|
|
||||||
Application description.
|
|
||||||
'';
|
|
||||||
example = "An amazing app!";
|
|
||||||
default = null;
|
|
||||||
};
|
|
||||||
category = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.str;
|
|
||||||
description = ''
|
|
||||||
App category tag.
|
|
||||||
'';
|
|
||||||
example = "app";
|
|
||||||
default = null;
|
|
||||||
};
|
|
||||||
icon = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.str;
|
|
||||||
description = ''
|
|
||||||
Font Awesome application icon.
|
|
||||||
'';
|
|
||||||
example = "rss";
|
|
||||||
default = null;
|
|
||||||
};
|
|
||||||
type = lib.mkOption {
|
|
||||||
type = lib.types.nullOr lib.types.str;
|
|
||||||
description = ''
|
|
||||||
application type.
|
|
||||||
'';
|
|
||||||
example = "Ping";
|
|
||||||
default = "Ping";
|
|
||||||
};
|
|
||||||
method = lib.mkOption {
|
|
||||||
type = lib.types.enum ["get" "head"];
|
|
||||||
description = ''
|
|
||||||
method of request used
|
|
||||||
'';
|
|
||||||
example = "get";
|
|
||||||
default = "head";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
});
|
|
||||||
description = ''
|
|
||||||
Defines a web application.
|
|
||||||
'';
|
|
||||||
default = {};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = let
|
|
||||||
cfg = config.webapps;
|
|
||||||
in {
|
|
||||||
lib.webapps.homerServices = let
|
|
||||||
apps = builtins.filter (a: a.dashboard.name != null) (lib.attrValues cfg.apps);
|
|
||||||
in
|
|
||||||
lib.forEach cfg.dashboardCategories (
|
|
||||||
cat: let
|
|
||||||
catApps = lib.sort (a: b: a.dashboard.name < b.dashboard.name) (
|
|
||||||
builtins.filter
|
|
||||||
(a:
|
|
||||||
a.dashboard.category
|
|
||||||
!= null
|
|
||||||
&& a.dashboard.category == cat.tag
|
|
||||||
|| a.dashboard.category == null && cat.tag == "misc")
|
|
||||||
apps
|
|
||||||
);
|
|
||||||
in {
|
|
||||||
inherit (cat) name;
|
|
||||||
items = lib.forEach catApps (a: {
|
|
||||||
inherit (a.dashboard) method name type url;
|
|
||||||
subtitle = a.dashboard.description;
|
|
||||||
icon = lib.optionalString (a.dashboard.icon != null) "fas fa-${a.dashboard.icon}";
|
|
||||||
target = "_blank";
|
|
||||||
});
|
|
||||||
}
|
|
||||||
);
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,56 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.my.services.homer;
|
|
||||||
inherit (config.my.server) domain;
|
|
||||||
homeConfig = {
|
|
||||||
title = "Dashboard";
|
|
||||||
header = false;
|
|
||||||
footer = false;
|
|
||||||
colors = {
|
|
||||||
dark = {
|
|
||||||
highlight-primary = "#cc241d";
|
|
||||||
highlight-secondary = "#8ec07c";
|
|
||||||
highlight-hover = "#d79921";
|
|
||||||
background = "rgb(40,36,34)";
|
|
||||||
card-background = "#3c3836";
|
|
||||||
text = "#eaeaea";
|
|
||||||
text-header = "#ffffff";
|
|
||||||
text-title = "#fafafa";
|
|
||||||
text-subtitle = "#f5f5f5";
|
|
||||||
card-shadow = "rgba(0, 0, 0, 0.4)";
|
|
||||||
link = "#3273dc";
|
|
||||||
link-hover = "#ffdd57";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
connectivityCheck = true;
|
|
||||||
columns = "auto";
|
|
||||||
services = config.lib.webapps.homerServices;
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
imports = [
|
|
||||||
./config.nix
|
|
||||||
];
|
|
||||||
|
|
||||||
options.my.services.homer = {
|
|
||||||
enable = mkEnableOption "Homer Dashboard";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
services.caddy.virtualHosts."${domain}".extraConfig = ''
|
|
||||||
handle_path /assets/config.yml {
|
|
||||||
root * ${pkgs.writeText "homerConfig.yml" (builtins.toJSON homeConfig)}
|
|
||||||
file_server
|
|
||||||
}
|
|
||||||
|
|
||||||
root * ${pkgs.homer}
|
|
||||||
file_server {
|
|
||||||
hide .git
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,45 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
inputs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.my.services.mealie;
|
|
||||||
in {
|
|
||||||
disabledModules = ["services/web-apps/mealie.nix"];
|
|
||||||
imports = ["${inputs.unstable}/nixos/modules/services/web-apps/mealie.nix"];
|
|
||||||
|
|
||||||
options.my.services.mealie = {
|
|
||||||
enable = mkEnableOption "Mealie";
|
|
||||||
port = mkOption {
|
|
||||||
type = types.port;
|
|
||||||
default = 3123;
|
|
||||||
example = 8080;
|
|
||||||
description = "HTTP port for the Mealie service.";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
services.mealie = {
|
|
||||||
enable = true;
|
|
||||||
inherit (cfg) port;
|
|
||||||
package = pkgs.unstable.mealie;
|
|
||||||
settings = {
|
|
||||||
BASE_URL = "https://recipes.thomasfmly.org";
|
|
||||||
|
|
||||||
# OIDC
|
|
||||||
OIDC_AUTH_ENABLED = true;
|
|
||||||
OIDC_CONFIGURATION_URL = "https://authentik.thomasfmly.org/application/o/mealie/.well-known/openid-configuration";
|
|
||||||
OIDC_CLIENT_ID = "FLFfJCP0nWsxGfHpAf26XfoqMaIoUuaVdODJLW28";
|
|
||||||
OIDC_CLIENT_SECRET = "YSEfBhGQUmzAKnrAEi9413NM4m8juF8u7e8zOLzfCA1JXZdRsgj8WWXTKLqEeGhCiQsVvD1iX52sFcWqOWo2r7tpolpUUVymj8O4kfMWampO1Nn65K2aPFtuXu3soUwB";
|
|
||||||
OIDC_ADMIN_GROUP = "Administrators";
|
|
||||||
OIDC_AUTO_REDIRECT = true;
|
|
||||||
OIDC_PROVIDER_NAME = "Authentik";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [cfg.port];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,75 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.my.services.nextcloud;
|
|
||||||
in {
|
|
||||||
options.my.services.nextcloud = {
|
|
||||||
enable = mkEnableOption "Nextcloud";
|
|
||||||
port = mkOption {
|
|
||||||
type = types.port;
|
|
||||||
default = 9090;
|
|
||||||
example = 8080;
|
|
||||||
description = "HTTP port for the Nextcloud service.";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
services.nextcloud = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.nextcloud29;
|
|
||||||
hostName = "cloud.thomasfmly.org";
|
|
||||||
phpExtraExtensions = ext: with ext; [smbclient];
|
|
||||||
|
|
||||||
database.createLocally = true;
|
|
||||||
configureRedis = true;
|
|
||||||
|
|
||||||
maxUploadSize = "16G";
|
|
||||||
|
|
||||||
autoUpdateApps.enable = true;
|
|
||||||
extraAppsEnable = true;
|
|
||||||
# https://github.com/NixOS/nixpkgs/blob/master/pkgs/servers/nextcloud/packages/nextcloud-apps.json
|
|
||||||
extraApps = with config.services.nextcloud.package.packages.apps; {
|
|
||||||
inherit calendar notes user_oidc;
|
|
||||||
};
|
|
||||||
|
|
||||||
config = {
|
|
||||||
dbtype = "pgsql";
|
|
||||||
adminuser = "michael";
|
|
||||||
adminpassFile = config.age.secrets.nextcloudAdminpass.path;
|
|
||||||
};
|
|
||||||
|
|
||||||
settings = {
|
|
||||||
# Proxy Settings
|
|
||||||
overwriteprotocol = "https";
|
|
||||||
trusted_proxies = ["192.168.1.10"];
|
|
||||||
|
|
||||||
# Configuration Settings
|
|
||||||
default_phone_region = "US";
|
|
||||||
maintenance_window_start = 1;
|
|
||||||
};
|
|
||||||
|
|
||||||
phpOptions = {
|
|
||||||
"opcache.interned_strings_buffer" = "23";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
age.secrets.nextcloudAdminpass = {
|
|
||||||
file = ../../../secrets/nextcloud-adminpass.age;
|
|
||||||
owner = "nextcloud";
|
|
||||||
group = "nextcloud";
|
|
||||||
};
|
|
||||||
|
|
||||||
services.nginx.virtualHosts."${config.services.nextcloud.hostName}".listen = [
|
|
||||||
{
|
|
||||||
addr = "0.0.0.0";
|
|
||||||
inherit (cfg) port;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
networking.firewall.allowedTCPPorts = [cfg.port];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,5 +1,6 @@
|
|||||||
{
|
{
|
||||||
# Enable sound.
|
# Enable sound.
|
||||||
|
sound.enable = true;
|
||||||
hardware.pulseaudio.enable = false;
|
hardware.pulseaudio.enable = false;
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
|
|
||||||
|
@ -18,11 +18,11 @@
|
|||||||
split_ratio = 0;
|
split_ratio = 0;
|
||||||
split_type = "auto";
|
split_type = "auto";
|
||||||
auto_balance = "off";
|
auto_balance = "off";
|
||||||
top_padding = 0;
|
top_padding = 12;
|
||||||
bottom_padding = 0;
|
bottom_padding = 12;
|
||||||
left_padding = 0;
|
left_padding = 12;
|
||||||
right_padding = 0;
|
right_padding = 12;
|
||||||
window_gap = 6;
|
window_gap = 06;
|
||||||
layout = "bsp";
|
layout = "bsp";
|
||||||
mouse_modifier = "fn";
|
mouse_modifier = "fn";
|
||||||
mouse_action1 = "move";
|
mouse_action1 = "move";
|
||||||
@ -34,49 +34,42 @@
|
|||||||
services.skhd = {
|
services.skhd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
skhdConfig = ''
|
skhdConfig = ''
|
||||||
ctrl + alt - h: yabai -m window --focus west
|
ctrl + alt - h: yabai -m window --focus west
|
||||||
ctrl + alt - j: yabai -m window --focus south
|
ctrl + alt - j: yabai -m window --focus south
|
||||||
ctrl + alt - k: yabai -m window --focus north
|
ctrl + alt - k: yabai -m window --focus north
|
||||||
ctrl + alt - l: yabai -m window --focus east
|
ctrl + alt - l: yabai -m window --focus east
|
||||||
|
|
||||||
cmd + ctrl + alt - h : yabai -m window --warp west
|
cmd + ctrl + alt - h : yabai -m window --warp west
|
||||||
cmd + ctrl + alt - j : yabai -m window --warp south
|
cmd + ctrl + alt - j : yabai -m window --warp south
|
||||||
cmd + ctrl + alt - k : yabai -m window --warp north
|
cmd + ctrl + alt - k : yabai -m window --warp north
|
||||||
cmd + ctrl + alt - l : yabai -m window --warp east
|
cmd + ctrl + alt - l : yabai -m window --warp east
|
||||||
|
|
||||||
ctrl + alt - 1 : yabai -m space --focus 1
|
ctrl + alt - 1 : yabai -m space --focus 1
|
||||||
ctrl + alt - 2 : yabai -m space --focus 2
|
ctrl + alt - 2 : yabai -m space --focus 2
|
||||||
ctrl + alt - 3 : yabai -m space --focus 3
|
ctrl + alt - 3 : yabai -m space --focus 3
|
||||||
ctrl + alt - 4 : yabai -m space --focus 4
|
ctrl + alt - 4 : yabai -m space --focus 4
|
||||||
ctrl + alt - 5 : yabai -m space --focus 5
|
ctrl + alt - 5 : yabai -m space --focus 5
|
||||||
ctrl + alt - 6 : yabai -m space --focus 6
|
ctrl + alt - 6 : yabai -m space --focus 6
|
||||||
ctrl + alt - 7 : yabai -m space --focus 7
|
ctrl + alt - 7 : yabai -m space --focus 7
|
||||||
ctrl + alt - 8 : yabai -m space --focus 8
|
ctrl + alt - 8 : yabai -m space --focus 8
|
||||||
ctrl + alt - 9 : yabai -m space --focus 9
|
ctrl + alt - 9 : yabai -m space --focus 9
|
||||||
|
|
||||||
ctrl + alt - q: yabai -m window --close
|
ctrl + alt - q: yabai -m window --close
|
||||||
|
|
||||||
## stack window
|
|
||||||
# Note that this only works when the active window does *not* already belong to a stack
|
|
||||||
shift + alt + cmd - left : yabai -m window west --stack $(yabai -m query --windows --window | jq -r '.id')
|
|
||||||
shift + alt + cmd - right : yabai -m window east --stack $(yabai -m query --windows --window | jq -r '.id')
|
|
||||||
|
|
||||||
# 0x21 - [
|
# 0x21 - [
|
||||||
# 0x1E - ]
|
# 0x1E - ]
|
||||||
ctrl + alt - 0x21 : yabai -m query --spaces --space \
|
ctrl + alt - 0x21 : yabai -m query --spaces --space \
|
||||||
| jq -re ".index" \
|
| jq -re ".index" \
|
||||||
| xargs -I{} yabai -m query --windows --space {} \
|
| xargs -I{} yabai -m query --windows --space {} \
|
||||||
| jq -sre "add | map(select(.minimized != 1)) | sort_by(.display, .frame.y, .frame.y, .id) | nth(index(map(select(.focused == 1))) - 1).id" \
|
| jq -sre "add | map(select(.minimized != 1)) | sort_by(.display, .frame.y, .frame.y, .id) | nth(index(map(select(.focused == 1))) - 1).id" \
|
||||||
| xargs -I{} yabai -m window --focus {}
|
| xargs -I{} yabai -m window --focus {}
|
||||||
|
|
||||||
ctrl + alt - 0x1E : yabai -m query --spaces --space \
|
ctrl + alt - 0x1E : yabai -m query --spaces --space \
|
||||||
| jq -re ".index" \
|
| jq -re ".index" \
|
||||||
| xargs -I{} yabai -m query --windows --space {} \
|
| xargs -I{} yabai -m query --windows --space {} \
|
||||||
| jq -sre "add | map(select(.minimized != 1)) | sort_by(.display, .frame.y, .frame.x, .id) | reverse | nth(index(map(select(.focused == 1))) - 1).id" \
|
| jq -sre "add | map(select(.minimized != 1)) | sort_by(.display, .frame.y, .frame.x, .id) | reverse | nth(index(map(select(.focused == 1))) - 1).id" \
|
||||||
| xargs -I{} yabai -m window --focus {}
|
| xargs -I{} yabai -m window --focus {}
|
||||||
|
|
||||||
# applications
|
|
||||||
ctrl + alt - t: open -n -a 'Alacritty.app'
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -1,45 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.ags;
|
|
||||||
in {
|
|
||||||
imports = [inputs.ags.homeManagerModules.default];
|
|
||||||
|
|
||||||
options.my.ags = {
|
|
||||||
enable = mkEnableOption "ags";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
programs.ags = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
extraPackages = with pkgs; [
|
|
||||||
bun
|
|
||||||
which
|
|
||||||
fzf
|
|
||||||
# inputs.matugen.packages.${system}.default
|
|
||||||
slurp
|
|
||||||
wf-recorder
|
|
||||||
wl-clipboard
|
|
||||||
wayshot
|
|
||||||
swappy
|
|
||||||
pavucontrol
|
|
||||||
networkmanager
|
|
||||||
gtk3
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
brightnessctl
|
|
||||||
fd
|
|
||||||
dart-sass
|
|
||||||
hyprpicker
|
|
||||||
swww
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,14 +0,0 @@
|
|||||||
{
|
|
||||||
inputs,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports =
|
|
||||||
[
|
|
||||||
inputs.home-manager.nixosModules.home-manager
|
|
||||||
../common
|
|
||||||
]
|
|
||||||
++ lib.my.getModules [./.];
|
|
||||||
|
|
||||||
hm.imports = lib.my.getHmModules [./.];
|
|
||||||
}
|
|
@ -1,75 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.hyprland;
|
|
||||||
in {
|
|
||||||
options.my.hyprland = {
|
|
||||||
enable = mkEnableOption "hyprland";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
hm.my.hyprland.enable = true;
|
|
||||||
|
|
||||||
programs.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Hint electron apps to use wayland
|
|
||||||
environment.sessionVariables.NIXOS_OZONE_WL = "1";
|
|
||||||
|
|
||||||
services.gnome.gnome-keyring.enable = true;
|
|
||||||
security.pam.services.greetd.enableGnomeKeyring = true;
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
# Theme
|
|
||||||
adw-gtk3
|
|
||||||
|
|
||||||
# Applications
|
|
||||||
nautilus
|
|
||||||
sushi
|
|
||||||
eog
|
|
||||||
totem
|
|
||||||
cheese
|
|
||||||
file-roller
|
|
||||||
gnome-weather
|
|
||||||
gnome-contacts
|
|
||||||
gnome-calendar
|
|
||||||
gnome-screenshot
|
|
||||||
wordbook
|
|
||||||
gnome-font-viewer
|
|
||||||
gnome-system-monitor
|
|
||||||
monophony # music player
|
|
||||||
|
|
||||||
# Nvim clipboard
|
|
||||||
wl-clipboard
|
|
||||||
];
|
|
||||||
|
|
||||||
# Required for Nautilus to work outside GNOME
|
|
||||||
services.gvfs.enable = true;
|
|
||||||
|
|
||||||
# Use CAPSLOCK as Hyper key
|
|
||||||
services.keyd = {
|
|
||||||
enable = true;
|
|
||||||
keyboards.default = {
|
|
||||||
ids = ["*"];
|
|
||||||
settings.main = {
|
|
||||||
capslock = "overload(meta, esc)";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.greetd = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
default_session = {
|
|
||||||
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --cmd Hyprland";
|
|
||||||
user = "greeter";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,238 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.hyprland;
|
|
||||||
in {
|
|
||||||
options.my.hyprland = {
|
|
||||||
enable = mkEnableOption "hyprland";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
my.ags.enable = true;
|
|
||||||
|
|
||||||
programs.fuzzel.enable = true;
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
pavucontrol
|
|
||||||
swaybg
|
|
||||||
];
|
|
||||||
|
|
||||||
wayland.windowManager.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
"$mod" = "SUPER";
|
|
||||||
general = {
|
|
||||||
gaps_in = 5;
|
|
||||||
gaps_out = 10;
|
|
||||||
};
|
|
||||||
input = {
|
|
||||||
follow_mouse = 2;
|
|
||||||
sensitivity = -0.2;
|
|
||||||
};
|
|
||||||
exec-once = [
|
|
||||||
"hyprctl setcursor Adwaita 24"
|
|
||||||
"ags"
|
|
||||||
"swaybg -i /home/michael/Photos/wallpaper.jpg"
|
|
||||||
"hypridle"
|
|
||||||
];
|
|
||||||
bind =
|
|
||||||
[
|
|
||||||
# Program launcher
|
|
||||||
"$mod, SPACE, exec, fuzzel"
|
|
||||||
# Program shortcuts
|
|
||||||
"$mod, F, exec, firefox"
|
|
||||||
"$mod, Q, killactive"
|
|
||||||
"$mod, T, exec, foot"
|
|
||||||
", Print, exec, grimblast copy area"
|
|
||||||
# Windows
|
|
||||||
"$mod, H, movefocus, l"
|
|
||||||
"$mod, J, movefocus, d"
|
|
||||||
"$mod, K, movefocus, u"
|
|
||||||
"$mod, L, movefocus, r"
|
|
||||||
# Moving windows
|
|
||||||
"$mod SHIFT, H, movewindow, l"
|
|
||||||
"$mod SHIFT, J, movewindow, d"
|
|
||||||
"$mod SHIFT, K, movewindow, u"
|
|
||||||
"$mod SHIFT, L, movewindow, r"
|
|
||||||
]
|
|
||||||
++ (
|
|
||||||
# workspaces
|
|
||||||
# binds $mod + [shift +] {1..10} to [move to] workspace {1..10}
|
|
||||||
builtins.concatLists (builtins.genList (
|
|
||||||
x: let
|
|
||||||
ws = let
|
|
||||||
c = (x + 1) / 10;
|
|
||||||
in
|
|
||||||
builtins.toString (x + 1 - (c * 10));
|
|
||||||
in [
|
|
||||||
"$mod, ${ws}, workspace, ${toString (x + 1)}"
|
|
||||||
"$mod SHIFT, ${ws}, movetoworkspace, ${toString (x + 1)}"
|
|
||||||
]
|
|
||||||
)
|
|
||||||
10)
|
|
||||||
);
|
|
||||||
};
|
|
||||||
extraConfig = ''
|
|
||||||
# will switch to a submap called resize
|
|
||||||
bind=$mod,R,submap,resize
|
|
||||||
|
|
||||||
# media controls
|
|
||||||
bindel=, XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+
|
|
||||||
bindel=, XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
|
|
||||||
bindl=, XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
|
|
||||||
|
|
||||||
# will start a submap called "resize"
|
|
||||||
submap=resize
|
|
||||||
|
|
||||||
# sets repeatable binds for resizing the active window
|
|
||||||
binde=,h,resizeactive,-10 0
|
|
||||||
binde=,j,resizeactive,0 10
|
|
||||||
binde=,k,resizeactive,0 -10
|
|
||||||
binde=,l,resizeactive,10 0
|
|
||||||
|
|
||||||
# use reset to go back to the global submap
|
|
||||||
bind=,escape,submap,reset
|
|
||||||
|
|
||||||
# will reset the submap, meaning end the current one and return to the global one
|
|
||||||
submap=reset
|
|
||||||
|
|
||||||
# mouse bindings
|
|
||||||
bindm=ALT,mouse:272,movewindow
|
|
||||||
bindm=ALT,mouse:273,resizewindow
|
|
||||||
|
|
||||||
# no gaps when only window
|
|
||||||
workspace = w[t1], gapsout:0, gapsin:0
|
|
||||||
workspace = w[tg1], gapsout:0, gapsin:0
|
|
||||||
workspace = f[1], gapsout:0, gapsin:0
|
|
||||||
windowrulev2 = bordersize 0, floating:0, onworkspace:w[t1]
|
|
||||||
windowrulev2 = rounding 0, floating:0, onworkspace:w[t1]
|
|
||||||
windowrulev2 = bordersize 0, floating:0, onworkspace:w[tg1]
|
|
||||||
windowrulev2 = rounding 0, floating:0, onworkspace:w[tg1]
|
|
||||||
windowrulev2 = bordersize 0, floating:0, onworkspace:f[1]
|
|
||||||
windowrulev2 = rounding 0, floating:0, onworkspace:f[1]
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
gtk = {
|
|
||||||
enable = true;
|
|
||||||
font.name = "Inter 11";
|
|
||||||
theme = {
|
|
||||||
name = "adw-gtk3-dark";
|
|
||||||
package = pkgs.adw-gtk3;
|
|
||||||
};
|
|
||||||
iconTheme = {
|
|
||||||
name = "Papirus";
|
|
||||||
package = pkgs.papirus-icon-theme;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.pointerCursor = {
|
|
||||||
gtk.enable = true;
|
|
||||||
name = "Adwaita";
|
|
||||||
package = pkgs.adwaita-icon-theme;
|
|
||||||
size = 24;
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.hyprlock = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
general = {
|
|
||||||
no_fade_in = false;
|
|
||||||
grace = 0;
|
|
||||||
disable_loading_bar = true;
|
|
||||||
};
|
|
||||||
background = {
|
|
||||||
monitor = "";
|
|
||||||
path = "~/Photos/wallpaper.jpg";
|
|
||||||
blur_passes = 3;
|
|
||||||
contrast = 0.8916;
|
|
||||||
brightness = 0.8172;
|
|
||||||
vibrancy = 0.1696;
|
|
||||||
vibrancy_darkness = 0.0;
|
|
||||||
};
|
|
||||||
input-field = {
|
|
||||||
monitor = "";
|
|
||||||
size = "250, 60";
|
|
||||||
outline_thickness = 2;
|
|
||||||
dots_size = 0.2; # Scale of input-field height, 0.2 - 0.8
|
|
||||||
dots_spacing = 0.2; # Scale of dots' absolute size, 0.0 - 1.0
|
|
||||||
dots_center = true;
|
|
||||||
outer_color = "rgba(0, 0, 0, 0)";
|
|
||||||
inner_color = "rgba(0, 0, 0, 0.5)";
|
|
||||||
font_color = "rgb(200, 200, 200)";
|
|
||||||
fade_on_empty = false;
|
|
||||||
font_family = "Inter";
|
|
||||||
placeholder_text = "Enter Password";
|
|
||||||
hide_input = false;
|
|
||||||
position = "0, 375";
|
|
||||||
halign = "center";
|
|
||||||
valign = "bottom";
|
|
||||||
};
|
|
||||||
label = [
|
|
||||||
# Time
|
|
||||||
{
|
|
||||||
monitor = "";
|
|
||||||
text = "cmd[update:1000] echo \"$(date +\"%-I:%M %P\")\"";
|
|
||||||
color = "rgba(255, 255, 255, 0.6)";
|
|
||||||
font_size = 120;
|
|
||||||
font_family = "Inter ExtraBold";
|
|
||||||
position = "0, -300";
|
|
||||||
halign = "center";
|
|
||||||
valign = "top";
|
|
||||||
}
|
|
||||||
# User
|
|
||||||
{
|
|
||||||
monitor = "";
|
|
||||||
text = config.my.name;
|
|
||||||
color = "rgba(255, 255, 255, 0.6)";
|
|
||||||
font_size = 24;
|
|
||||||
font_family = "Inter Semibold";
|
|
||||||
position = "0, 450";
|
|
||||||
halign = "center";
|
|
||||||
valign = "bottom";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.hypridle = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
general = {
|
|
||||||
lock_cmd = "pidof hyprlock || hyprlock";
|
|
||||||
before_sleep_cmd = "loginctl lock-session";
|
|
||||||
after_sleep_cmd = "hyprctl dispatch dpms on";
|
|
||||||
};
|
|
||||||
|
|
||||||
listener = [
|
|
||||||
# Dim screen
|
|
||||||
{
|
|
||||||
timeout = 150; # 2.5 min
|
|
||||||
on-timeout = "brightnessctl -s set 10"; # set monitor backlight to minimum, avoid 0 on OLED monitor.
|
|
||||||
on-resume = "brightnessctl -r"; # monitor backlight restore.
|
|
||||||
}
|
|
||||||
# Lock
|
|
||||||
{
|
|
||||||
timeout = 300; # 5 min
|
|
||||||
on-timeout = "loginctl lock-session";
|
|
||||||
}
|
|
||||||
# Turn off screen
|
|
||||||
{
|
|
||||||
timeout = 330; # 5.5 min
|
|
||||||
on-timeout = "hyprctl dispatch dpms off";
|
|
||||||
on-resume = "hyprctl dispatch dpms on";
|
|
||||||
}
|
|
||||||
# Suspend
|
|
||||||
{
|
|
||||||
timeout = 1800; # 30 min
|
|
||||||
on-timeout = "systemctl suspend";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,22 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.libreoffice;
|
|
||||||
in {
|
|
||||||
options.my.libreoffice = {
|
|
||||||
enable = mkEnableOption "libreoffice";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
libreoffice-qt
|
|
||||||
hunspell
|
|
||||||
hunspellDicts.uk_UA
|
|
||||||
hunspellDicts.th_TH
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,28 +0,0 @@
|
|||||||
{lib, ...}:
|
|
||||||
with lib; {
|
|
||||||
options.my.server = {
|
|
||||||
name = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "Server";
|
|
||||||
example = "Venus";
|
|
||||||
description = "User-facing name of the server.";
|
|
||||||
};
|
|
||||||
domain = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
example = "example.com";
|
|
||||||
description = "Full domain name of the server.";
|
|
||||||
};
|
|
||||||
proxyIP = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "127.0.0.1";
|
|
||||||
example = "127.0.0.1";
|
|
||||||
description = "IP address of server hosting services behind reverse proxy.";
|
|
||||||
};
|
|
||||||
firewallInterface = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "eth0";
|
|
||||||
example = "wg0";
|
|
||||||
description = "Network interface to expose services on.";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,21 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
...
|
|
||||||
}: let
|
|
||||||
inherit (lib) mkEnableOption mkIf;
|
|
||||||
cfg = config.my.steam;
|
|
||||||
in {
|
|
||||||
options.my.steam = {
|
|
||||||
enable = mkEnableOption "steam";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
programs.steam = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.unstable.steam;
|
|
||||||
gamescopeSession.enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,33 +1,13 @@
|
|||||||
{inputs, ...}: {
|
{
|
||||||
rust-overlay = inputs.rust-overlay.overlays.default;
|
nixpkgs,
|
||||||
vscode-extensions = inputs.nix-vscode-extensions.overlays.default;
|
unstable,
|
||||||
|
...
|
||||||
# This one brings our custom packages from the 'pkgs' directory
|
}: let
|
||||||
additions = final: _prev:
|
inherit (nixpkgs.lib) composeManyExtensions;
|
||||||
import ../pkgs {
|
inherit (builtins) attrNames readDir;
|
||||||
inherit (final) pkgs;
|
localOverlays =
|
||||||
inherit inputs;
|
map
|
||||||
};
|
(f: import (./default + "/${f}"))
|
||||||
|
(attrNames (readDir ./default));
|
||||||
# This one contains whatever you want to overlay
|
in
|
||||||
# You can change versions, add patches, set compilation flags, anything really.
|
composeManyExtensions localOverlays
|
||||||
# https://nixos.wiki/wiki/Overlays
|
|
||||||
modifications = final: prev: {
|
|
||||||
# avoid build failure on darwin
|
|
||||||
inherit (final.unstable) ghostscript;
|
|
||||||
};
|
|
||||||
|
|
||||||
# When applied, the unstable nixpkgs set (declared in the flake inputs) will
|
|
||||||
# be accessible through 'pkgs.unstable'
|
|
||||||
unstable-packages = final: _prev: {
|
|
||||||
unstable = import inputs.unstable {
|
|
||||||
inherit (final) system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
master = import inputs.master {
|
|
||||||
inherit (final) system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
1
overlays/default/firebird-emu.nix
Normal file
1
overlays/default/firebird-emu.nix
Normal file
@ -0,0 +1 @@
|
|||||||
|
import ./firebird-emu/default.nix
|
3
overlays/default/firebird-emu/default.nix
Normal file
3
overlays/default/firebird-emu/default.nix
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
self: super: {
|
||||||
|
firebird-emu = self.libsForQt5.callPackage ./package.nix {};
|
||||||
|
}
|
44
overlays/default/firebird-emu/package.nix
Normal file
44
overlays/default/firebird-emu/package.nix
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
{
|
||||||
|
stdenv,
|
||||||
|
lib,
|
||||||
|
fetchFromGitHub,
|
||||||
|
qmake,
|
||||||
|
qtbase,
|
||||||
|
qtdeclarative,
|
||||||
|
qtquickcontrols,
|
||||||
|
wrapQtAppsHook,
|
||||||
|
}:
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "firebird-emu";
|
||||||
|
version = "1.6";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "nspire-emus";
|
||||||
|
repo = "firebird";
|
||||||
|
rev = "v${version}";
|
||||||
|
fetchSubmodules = true;
|
||||||
|
hash = "sha256-ZptjlnOiF+hKuKYvBFJL95H5YQuR99d4biOco/MVEmE=";
|
||||||
|
};
|
||||||
|
|
||||||
|
NIX_CFLAGS_COMPILE = lib.optionals (stdenv.cc.isClang && stdenv.isDarwin) [
|
||||||
|
"-fno-lto" # work around https://github.com/NixOS/nixpkgs/issues/19098
|
||||||
|
];
|
||||||
|
|
||||||
|
nativeBuildInputs = [qmake wrapQtAppsHook];
|
||||||
|
|
||||||
|
buildInputs = [qtbase qtdeclarative qtquickcontrols];
|
||||||
|
|
||||||
|
postInstall = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
||||||
|
mkdir $out/Applications
|
||||||
|
mv $out/bin/${pname}.app $out/Applications/
|
||||||
|
'';
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
homepage = "https://github.com/nspire-emus/firebird";
|
||||||
|
description = "Third-party multi-platform emulator of the ARM-based TI-Nspire™ calculators";
|
||||||
|
license = lib.licenses.gpl3;
|
||||||
|
maintainers = with lib.maintainers; [pneumaticat];
|
||||||
|
# Only tested on Linux, but likely possible to build on, e.g. macOS
|
||||||
|
platforms = lib.platforms.unix;
|
||||||
|
};
|
||||||
|
}
|
15
overlays/default/paperwm.nix
Normal file
15
overlays/default/paperwm.nix
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
self: super: {
|
||||||
|
gnomeExtensions =
|
||||||
|
super.gnomeExtensions
|
||||||
|
// {
|
||||||
|
paperwm = super.gnomeExtensions.paperwm.overrideDerivation (old: {
|
||||||
|
version = "43.0";
|
||||||
|
src = super.fetchFromGitHub {
|
||||||
|
owner = "paperwm";
|
||||||
|
repo = "PaperWM";
|
||||||
|
rev = "64960df6cde10bcf47c33ce56a2d35e99d8d02bf";
|
||||||
|
sha256 = "sha256-ejyWIa4HX1lEIHc9qax8jgrgi992W6rkTK60FGzKI/E=";
|
||||||
|
};
|
||||||
|
});
|
||||||
|
};
|
||||||
|
}
|
5
overlays/iptables/default.nix
Normal file
5
overlays/iptables/default.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
self: super: {
|
||||||
|
iptables = super.iptables.override {
|
||||||
|
nftablesCompat = false;
|
||||||
|
};
|
||||||
|
}
|
@ -1,5 +0,0 @@
|
|||||||
{pkgs, ...} @ args: {
|
|
||||||
homer = pkgs.callPackage ./homer {};
|
|
||||||
keycloak-theme-keywind = pkgs.callPackage ./keywind {};
|
|
||||||
nvim-custom = import ./nvim/default.nix args;
|
|
||||||
}
|
|
@ -1,19 +0,0 @@
|
|||||||
{
|
|
||||||
stdenv,
|
|
||||||
fetchzip,
|
|
||||||
}:
|
|
||||||
stdenv.mkDerivation rec {
|
|
||||||
pname = "homer";
|
|
||||||
version = "24.04.1";
|
|
||||||
|
|
||||||
src = fetchzip {
|
|
||||||
url = "https://github.com/bastienwirtz/homer/releases/download/v${version}/homer.zip";
|
|
||||||
hash = "sha256-BWQMBQn/bnRQdhJpgn9sIeiybdzT7c9c9h9toNGx48k=";
|
|
||||||
stripRoot = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
cp -r $src $out/
|
|
||||||
'';
|
|
||||||
sourceRoot = ".";
|
|
||||||
}
|
|
@ -1,20 +0,0 @@
|
|||||||
{
|
|
||||||
stdenv,
|
|
||||||
fetchFromGitHub,
|
|
||||||
}:
|
|
||||||
stdenv.mkDerivation {
|
|
||||||
pname = "keycloak-theme-keywind";
|
|
||||||
version = "0.0.1-dev";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "michaelhthomas";
|
|
||||||
repo = "keywind";
|
|
||||||
rev = "f3f016ab34ac9731ef8dadd6e79406a3c2433a34";
|
|
||||||
hash = "sha256-wronX44qyUIuoTSdKj01UlLrwH9U5qNkUuSouV+xSUU=";
|
|
||||||
};
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
mkdir -p $out
|
|
||||||
cp -a theme/keywind/login $out
|
|
||||||
'';
|
|
||||||
}
|
|
@ -1,144 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
helpers,
|
|
||||||
icons,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
plugins = {
|
|
||||||
bufferline = {
|
|
||||||
enable = true;
|
|
||||||
settings.options = {
|
|
||||||
always_show_bufferline = false;
|
|
||||||
offsets = [
|
|
||||||
{
|
|
||||||
filetype = "neo-tree";
|
|
||||||
text = "Neo-tree";
|
|
||||||
highlight = "Directory";
|
|
||||||
text_align = "left";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
diagnostics = "nvim_lsp";
|
|
||||||
diagnostics_indicator = ''
|
|
||||||
function(_, _, diag)
|
|
||||||
local icons = ${helpers.toLuaObject icons.diagnostics}
|
|
||||||
local ret = (diag.error and icons.Error .. diag.error .. " " or "")
|
|
||||||
.. (diag.warning and icons.Warn .. diag.warning or "")
|
|
||||||
return vim.trim(ret)
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
separator_style = "thin"; # “slant”, “padded_slant”, “slope”, “padded_slope”, “thick”, “thin”
|
|
||||||
close_command = "Bdelete! %d";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
extraPlugins = with pkgs.vimPlugins; [bufdelete-nvim];
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<Tab>";
|
|
||||||
action = "<cmd>BufferLineCycleNext<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Cycle to next buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<S-Tab>";
|
|
||||||
action = "<cmd>BufferLineCyclePrev<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Cycle to previous buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<S-l>";
|
|
||||||
action = "<cmd>BufferLineCycleNext<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Cycle to next buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<S-h>";
|
|
||||||
action = "<cmd>BufferLineCyclePrev<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Cycle to previous buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>bd";
|
|
||||||
action = "<cmd>Bdelete<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Delete buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>bb";
|
|
||||||
action = "<cmd>e #<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Switch to Other Buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# {
|
|
||||||
# mode = "n";
|
|
||||||
# key = "<leader>`";
|
|
||||||
# action = "<cmd>e #<cr>";
|
|
||||||
# options = {
|
|
||||||
# desc = "Switch to Other Buffer";
|
|
||||||
# };
|
|
||||||
# }
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>br";
|
|
||||||
action = "<cmd>BufferLineCloseRight<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Delete buffers to the right";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>bl";
|
|
||||||
action = "<cmd>BufferLineCloseLeft<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Delete buffers to the left";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>bo";
|
|
||||||
action = "<cmd>BufferLineCloseOthers<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Delete other buffers";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>bp";
|
|
||||||
action = "<cmd>BufferLineTogglePin<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Toggle pin";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>bP";
|
|
||||||
action = "<Cmd>BufferLineGroupClose ungrouped<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Delete non-pinned buffers";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,8 +0,0 @@
|
|||||||
{
|
|
||||||
colorschemes = {
|
|
||||||
base16 = {
|
|
||||||
enable = false;
|
|
||||||
colorscheme = "mountain";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,48 +0,0 @@
|
|||||||
{
|
|
||||||
colorschemes = {
|
|
||||||
catppuccin = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
background = {
|
|
||||||
light = "macchiato";
|
|
||||||
dark = "mocha";
|
|
||||||
};
|
|
||||||
flavour = "mocha"; # "latte", "mocha", "frappe", "macchiato" or raw lua code
|
|
||||||
disable_bold = false;
|
|
||||||
disable_italic = false;
|
|
||||||
disable_underline = false;
|
|
||||||
transparent_background = true;
|
|
||||||
term_colors = true;
|
|
||||||
integrations = {
|
|
||||||
cmp = true;
|
|
||||||
noice = true;
|
|
||||||
notify = true;
|
|
||||||
neotree = true;
|
|
||||||
harpoon = true;
|
|
||||||
gitsigns = true;
|
|
||||||
which_key = true;
|
|
||||||
illuminate = {
|
|
||||||
enabled = true;
|
|
||||||
};
|
|
||||||
treesitter = true;
|
|
||||||
treesitter_context = true;
|
|
||||||
telescope.enabled = true;
|
|
||||||
indent_blankline.enabled = true;
|
|
||||||
mini.enabled = true;
|
|
||||||
native_lsp = {
|
|
||||||
enabled = true;
|
|
||||||
inlay_hints = {
|
|
||||||
background = true;
|
|
||||||
};
|
|
||||||
underlines = {
|
|
||||||
errors = ["underline"];
|
|
||||||
hints = ["underline"];
|
|
||||||
information = ["underline"];
|
|
||||||
warnings = ["underline"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
colorschemes.gruvbox = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,14 +0,0 @@
|
|||||||
{
|
|
||||||
colorschemes = {
|
|
||||||
rose-pine = {
|
|
||||||
enable = false;
|
|
||||||
settings = {
|
|
||||||
styles = {
|
|
||||||
italic = true;
|
|
||||||
bold = true;
|
|
||||||
transparency = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,131 +0,0 @@
|
|||||||
{
|
|
||||||
plugins = {
|
|
||||||
cmp = {
|
|
||||||
enable = true;
|
|
||||||
autoEnableSources = false;
|
|
||||||
settings = {
|
|
||||||
experimental = {
|
|
||||||
ghost_text = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
settings = {
|
|
||||||
mapping = {
|
|
||||||
__raw = ''
|
|
||||||
cmp.mapping.preset.insert({
|
|
||||||
['<C-j>'] = cmp.mapping.select_next_item(),
|
|
||||||
['<C-k>'] = cmp.mapping.select_prev_item(),
|
|
||||||
['<C-e>'] = cmp.mapping.abort(),
|
|
||||||
|
|
||||||
['<C-b>'] = cmp.mapping.scroll_docs(-4),
|
|
||||||
|
|
||||||
['<C-f>'] = cmp.mapping.scroll_docs(4),
|
|
||||||
|
|
||||||
['<C-Space>'] = cmp.mapping.complete(),
|
|
||||||
|
|
||||||
['<CR>'] = cmp.mapping.confirm({ select = true }),
|
|
||||||
|
|
||||||
['<S-CR>'] = cmp.mapping.confirm({ behavior = cmp.ConfirmBehavior.Replace, select = true }),
|
|
||||||
})
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
snippet = {
|
|
||||||
expand = "function(args) require('luasnip').lsp_expand(args.body) end";
|
|
||||||
};
|
|
||||||
sources = {
|
|
||||||
__raw = ''
|
|
||||||
cmp.config.sources({
|
|
||||||
{name = 'nvim_lsp'},
|
|
||||||
{name = 'copilot'},
|
|
||||||
{name = 'path'},
|
|
||||||
{name = 'luasnip'},
|
|
||||||
{name = 'cmdline'},
|
|
||||||
}, {
|
|
||||||
{name = 'buffer'},
|
|
||||||
})
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
performance = {
|
|
||||||
debounce = 60;
|
|
||||||
fetching_timeout = 200;
|
|
||||||
max_view_entries = 30;
|
|
||||||
};
|
|
||||||
window = {
|
|
||||||
completion = {
|
|
||||||
border = "rounded";
|
|
||||||
winhighlight = "Normal:Normal,FloatBorder:FloatBorder,CursorLine:Visual,Search:None";
|
|
||||||
};
|
|
||||||
documentation = {
|
|
||||||
border = "rounded";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
formatting = {
|
|
||||||
fields = ["kind" "abbr" "menu"];
|
|
||||||
expandable_indicator = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Completion from Language Server
|
|
||||||
cmp-nvim-lsp.enable = true; # lsp
|
|
||||||
# Completion for buffer words
|
|
||||||
cmp-buffer.enable = true;
|
|
||||||
# Completion for file system paths
|
|
||||||
cmp-path.enable = true;
|
|
||||||
};
|
|
||||||
extraConfigLua = ''
|
|
||||||
luasnip = require("luasnip")
|
|
||||||
kind_icons = {
|
|
||||||
Text = "",
|
|
||||||
Method = "",
|
|
||||||
Function = "",
|
|
||||||
Constructor = "",
|
|
||||||
Field = "",
|
|
||||||
Variable = "",
|
|
||||||
Class = "",
|
|
||||||
Interface = "",
|
|
||||||
Module = "",
|
|
||||||
Property = "",
|
|
||||||
Unit = "",
|
|
||||||
Value = "",
|
|
||||||
Enum = "",
|
|
||||||
Keyword = "",
|
|
||||||
Snippet = "",
|
|
||||||
Color = "",
|
|
||||||
File = "",
|
|
||||||
Reference = "",
|
|
||||||
Folder = "",
|
|
||||||
EnumMember = "",
|
|
||||||
Constant = "",
|
|
||||||
Struct = "",
|
|
||||||
Event = "",
|
|
||||||
Operator = "",
|
|
||||||
TypeParameter = "",
|
|
||||||
}
|
|
||||||
|
|
||||||
local cmp = require'cmp'
|
|
||||||
|
|
||||||
-- Use buffer source for `/` (if you enabled `native_menu`, this won't work anymore).
|
|
||||||
cmp.setup.cmdline({'/', "?" }, {
|
|
||||||
sources = {
|
|
||||||
{ name = 'buffer' }
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Set configuration for specific filetype.
|
|
||||||
cmp.setup.filetype('gitcommit', {
|
|
||||||
sources = cmp.config.sources({
|
|
||||||
{ name = 'cmp_git' }, -- You can specify the `cmp_git` source if you were installed it.
|
|
||||||
}, {
|
|
||||||
{ name = 'buffer' },
|
|
||||||
})
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Use cmdline & path source for ':' (if you enabled `native_menu`, this won't work anymore).
|
|
||||||
cmp.setup.cmdline(':', {
|
|
||||||
sources = cmp.config.sources({
|
|
||||||
{ name = 'path' }
|
|
||||||
}, {
|
|
||||||
{ name = 'cmdline' }
|
|
||||||
}),
|
|
||||||
}) '';
|
|
||||||
}
|
|
@ -1,222 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.dap = {
|
|
||||||
enable = true;
|
|
||||||
signs = {
|
|
||||||
dapBreakpoint = {
|
|
||||||
text = "●";
|
|
||||||
texthl = "DapBreakpoint";
|
|
||||||
};
|
|
||||||
dapBreakpointCondition = {
|
|
||||||
text = "●";
|
|
||||||
texthl = "DapBreakpointCondition";
|
|
||||||
};
|
|
||||||
dapLogPoint = {
|
|
||||||
text = "◆";
|
|
||||||
texthl = "DapLogPoint";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
extensions = {
|
|
||||||
dap-python = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
dap-ui = {
|
|
||||||
enable = true;
|
|
||||||
floating.mappings = {
|
|
||||||
close = ["<ESC>" "q"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
dap-virtual-text = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
configurations = {
|
|
||||||
java = [
|
|
||||||
{
|
|
||||||
type = "java";
|
|
||||||
request = "launch";
|
|
||||||
name = "Debug (Attach) - Remote";
|
|
||||||
hostName = "127.0.0.1";
|
|
||||||
port = 5005;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dB";
|
|
||||||
action = "
|
|
||||||
<cmd>lua require('dap').set_breakpoint(vim.fn.input('Breakpoint condition: '))<cr>
|
|
||||||
";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Breakpoint Condition";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>db";
|
|
||||||
action = ":DapToggleBreakpoint<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Toggle Breakpoint";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dc";
|
|
||||||
action = ":DapContinue<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Continue";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>da";
|
|
||||||
action = "<cmd>lua require('dap').continue({ before = get_args })<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Run with Args";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dC";
|
|
||||||
action = "<cmd>lua require('dap').run_to_cursor()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Run to cursor";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dg";
|
|
||||||
action = "<cmd>lua require('dap').goto_()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Go to line (no execute)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>di";
|
|
||||||
action = ":DapStepInto<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Step into";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dj";
|
|
||||||
action = "
|
|
||||||
<cmd>lua require('dap').down()<cr>
|
|
||||||
";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Down";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dk";
|
|
||||||
action = "<cmd>lua require('dap').up()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Up";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dl";
|
|
||||||
action = "<cmd>lua require('dap').run_last()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Run Last";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>do";
|
|
||||||
action = ":DapStepOut<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Step Out";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dO";
|
|
||||||
action = ":DapStepOver<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Step Over";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dp";
|
|
||||||
action = "<cmd>lua require('dap').pause()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Pause";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dr";
|
|
||||||
action = ":DapToggleRepl<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Toggle REPL";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ds";
|
|
||||||
action = "<cmd>lua require('dap').session()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Session";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dt";
|
|
||||||
action = ":DapTerminate<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Terminate";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>du";
|
|
||||||
action = "<cmd>lua require('dapui').toggle()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Dap UI";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>dw";
|
|
||||||
action = "<cmd>lua require('dap.ui.widgets').hover()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Widgets";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>de";
|
|
||||||
action = "<cmd>lua require('dapui').eval()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Eval";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,85 +0,0 @@
|
|||||||
{
|
|
||||||
# Import all your configuration modules here
|
|
||||||
imports = [
|
|
||||||
./sets.nix
|
|
||||||
./keymaps.nix
|
|
||||||
|
|
||||||
./bufferlines/bufferline.nix
|
|
||||||
|
|
||||||
# ./colorschemes/base16.nix
|
|
||||||
# ./colorschemes/catppuccin.nix
|
|
||||||
# ./colorschemes/rose-pine.nix
|
|
||||||
./colorschemes/gruvbox.nix
|
|
||||||
|
|
||||||
./completion/cmp.nix
|
|
||||||
|
|
||||||
./dap/dap.nix
|
|
||||||
|
|
||||||
./filetrees/neo-tree.nix
|
|
||||||
./git/gitsigns.nix
|
|
||||||
./git/diffview.nix
|
|
||||||
./git/lazygit.nix
|
|
||||||
# ./git/neogit.nix
|
|
||||||
|
|
||||||
./languages/nvim-jdtls.nix
|
|
||||||
./languages/nvim-lint.nix
|
|
||||||
./languages/typescript-tools-nvim.nix
|
|
||||||
./languages/treesitter/treesitter.nix
|
|
||||||
./languages/treesitter/mdx.nix
|
|
||||||
./languages/treesitter/treesitter-context.nix
|
|
||||||
./languages/treesitter/treesitter-textobjects.nix
|
|
||||||
./languages/treesitter/ts-autotag.nix
|
|
||||||
./languages/treesitter/ts-context-commentstring.nix
|
|
||||||
./languages/latex
|
|
||||||
|
|
||||||
./lsp/conform.nix
|
|
||||||
./lsp/fidget.nix
|
|
||||||
./lsp/lsp.nix
|
|
||||||
./lsp/lspsaga.nix
|
|
||||||
./lsp/trouble.nix
|
|
||||||
|
|
||||||
./none-ls/none-ls.nix
|
|
||||||
|
|
||||||
./snippets/luasnip.nix
|
|
||||||
|
|
||||||
./statusline/lualine.nix
|
|
||||||
|
|
||||||
./telescope/telescope.nix
|
|
||||||
|
|
||||||
./ui/alpha.nix
|
|
||||||
# ./ui/dressing-nvim.nix
|
|
||||||
./ui/indent-blankline.nix
|
|
||||||
./ui/noice.nix
|
|
||||||
./ui/nvim-notify.nix
|
|
||||||
./ui/nui.nix
|
|
||||||
./ui/statuscol.nix
|
|
||||||
|
|
||||||
# ./utils/better-escape.nix
|
|
||||||
./utils/flash.nix # better search labels
|
|
||||||
./utils/flutter-tools.nix
|
|
||||||
# ./utils/hardtime.nix # hints to get better at vim
|
|
||||||
# ./utils/harpoon.nix # better navigation between files & terminals
|
|
||||||
./utils/illuminate.nix # highlight other uses of current word
|
|
||||||
./utils/markdown-preview.nix
|
|
||||||
./utils/mini.nix # lots of utilities
|
|
||||||
./utils/neoconf.nix
|
|
||||||
# ./utils/neodev.nix # lua development
|
|
||||||
./utils/neotest.nix # test runner
|
|
||||||
./utils/colorizer.nix
|
|
||||||
./utils/nvim-surround.nix # surrounds
|
|
||||||
# ./utils/oil.nix # file explorer as buffer
|
|
||||||
./utils/persistence.nix # session management / restore
|
|
||||||
./utils/plenary.nix # utility library for other plugins
|
|
||||||
# ./utils/project-nvim.nix # project management
|
|
||||||
# ./utils/sidebar.nix # sidebar
|
|
||||||
# ./utils/tmux-navigator.nix
|
|
||||||
./utils/todo-comments.nix
|
|
||||||
./utils/toggleterm.nix
|
|
||||||
# ./utils/ultimate-autopair.nix # auto pairs (ew)
|
|
||||||
./utils/undotree.nix # browse undo history
|
|
||||||
./utils/vim-be-good.nix # game to get better at vim
|
|
||||||
./utils/web-devicons.nix # required for other packages
|
|
||||||
./utils/whichkey.nix # help with keybindings
|
|
||||||
./utils/wilder.nix # better wildmenu suggestions
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,81 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.neo-tree = {
|
|
||||||
enable = true;
|
|
||||||
enableDiagnostics = true;
|
|
||||||
enableGitStatus = true;
|
|
||||||
enableModifiedMarkers = true;
|
|
||||||
enableRefreshOnWrite = true;
|
|
||||||
closeIfLastWindow = true;
|
|
||||||
popupBorderStyle = "rounded"; # Type: null or one of “NC”, “double”, “none”, “rounded”, “shadow”, “single”, “solid” or raw lua code
|
|
||||||
buffers = {
|
|
||||||
bindToCwd = false;
|
|
||||||
followCurrentFile.enabled = true;
|
|
||||||
};
|
|
||||||
window = {
|
|
||||||
width = 40;
|
|
||||||
height = 15;
|
|
||||||
autoExpandWidth = false;
|
|
||||||
mappings = {
|
|
||||||
"<space>" = "none";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
filesystem = {
|
|
||||||
bindToCwd = false;
|
|
||||||
followCurrentFile.enabled = true;
|
|
||||||
useLibuvFileWatcher = true;
|
|
||||||
};
|
|
||||||
defaultComponentConfigs = {
|
|
||||||
indent = {
|
|
||||||
withExpanders = true; # if nil and file nesting is enabled, will enable expanders
|
|
||||||
expanderCollapsed = "";
|
|
||||||
expanderExpanded = "";
|
|
||||||
expanderHighlight = "NeoTreeExpander";
|
|
||||||
};
|
|
||||||
gitStatus = {
|
|
||||||
symbols = {
|
|
||||||
unstaged = "";
|
|
||||||
staged = "";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>e";
|
|
||||||
action = ":Neotree toggle reveal_force_cwd<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Explorer NeoTree (root dir)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>E";
|
|
||||||
action = "<cmd>Neotree toggle<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Explorer NeoTree (cwd)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>be";
|
|
||||||
action = ":Neotree buffers<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Buffer explorer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ge";
|
|
||||||
action = ":Neotree git_status<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Git explorer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.diffview = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,92 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.gitsigns = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
trouble = true;
|
|
||||||
current_line_blame = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>gh";
|
|
||||||
action = "gitsigns";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "+hunks";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ghb";
|
|
||||||
action = ":Gitsigns blame_line<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Blame line";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ghd";
|
|
||||||
action = ":Gitsigns diffthis<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Diff This";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ghp";
|
|
||||||
action = ":Gitsigns preview_hunk<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Preview hunk";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ghR";
|
|
||||||
action = ":Gitsigns reset_buffer<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Reset Buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>ghr";
|
|
||||||
action = ":Gitsigns reset_hunk<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Reset Hunk";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>ghs";
|
|
||||||
action = ":Gitsigns stage_hunk<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Stage Hunk";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ghS";
|
|
||||||
action = ":Gitsigns stage_buffer<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Stage Buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ghu";
|
|
||||||
action = ":Gitsigns undo_stage_hunk<CR>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Undo Stage Hunk";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,22 +0,0 @@
|
|||||||
{pkgs, ...}: {
|
|
||||||
extraPlugins = with pkgs.vimPlugins; [
|
|
||||||
lazygit-nvim
|
|
||||||
];
|
|
||||||
|
|
||||||
extraPackages = with pkgs; [lazygit];
|
|
||||||
|
|
||||||
extraConfigLua = ''
|
|
||||||
require("telescope").load_extension("lazygit")
|
|
||||||
'';
|
|
||||||
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>gg";
|
|
||||||
action = "<cmd>LazyGit<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "LazyGit (root dir)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.neogit = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>gg";
|
|
||||||
action = "<cmd>Neogit<CR>";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
if MVim then return end -- avoid loading twice the same module
|
|
||||||
MVim = {}
|
|
||||||
|
|
||||||
---@return {fg?:string}?
|
|
||||||
function MVim.fg(name)
|
|
||||||
local color = MVim.color(name)
|
|
||||||
return color and { fg = color } or nil
|
|
||||||
end
|
|
||||||
|
|
||||||
---@param name string
|
|
||||||
---@param bg? boolean
|
|
||||||
---@return string?
|
|
||||||
function MVim.color(name, bg)
|
|
||||||
---@type {fg?:number, bg?:number}?
|
|
||||||
local hl = vim.api.nvim_get_hl(0, { name = name, link = false })
|
|
||||||
---@type number?
|
|
||||||
local color = nil
|
|
||||||
if hl then
|
|
||||||
if bg then
|
|
||||||
color = hl.bg
|
|
||||||
else
|
|
||||||
color = hl.fg
|
|
||||||
end
|
|
||||||
end
|
|
||||||
return color and string.format("#%06x", color) or nil
|
|
||||||
end
|
|
@ -1,64 +0,0 @@
|
|||||||
{
|
|
||||||
misc = {
|
|
||||||
dots = "";
|
|
||||||
};
|
|
||||||
dap = {
|
|
||||||
Stopped = [" " "DiagnosticWarn" "DapStoppedLine"];
|
|
||||||
Breakpoint = " ";
|
|
||||||
BreakpointCondition = " ";
|
|
||||||
BreakpointRejected = [" " "DiagnosticError"];
|
|
||||||
LogPoint = ".>";
|
|
||||||
};
|
|
||||||
diagnostics = {
|
|
||||||
Error = " ";
|
|
||||||
Warn = " ";
|
|
||||||
Hint = " ";
|
|
||||||
Info = " ";
|
|
||||||
};
|
|
||||||
git = {
|
|
||||||
added = " ";
|
|
||||||
modified = " ";
|
|
||||||
removed = " ";
|
|
||||||
};
|
|
||||||
kinds = {
|
|
||||||
Array = " ";
|
|
||||||
Boolean = " ";
|
|
||||||
Class = " ";
|
|
||||||
Codeium = " ";
|
|
||||||
Color = " ";
|
|
||||||
Control = " ";
|
|
||||||
Collapsed = " ";
|
|
||||||
Constant = " ";
|
|
||||||
Constructor = " ";
|
|
||||||
Copilot = " ";
|
|
||||||
Enum = " ";
|
|
||||||
EnumMember = " ";
|
|
||||||
Event = " ";
|
|
||||||
Field = " ";
|
|
||||||
File = " ";
|
|
||||||
Folder = " ";
|
|
||||||
Function = " ";
|
|
||||||
Interface = " ";
|
|
||||||
Key = " ";
|
|
||||||
Keyword = " ";
|
|
||||||
Method = " ";
|
|
||||||
Module = " ";
|
|
||||||
Namespace = " ";
|
|
||||||
Null = " ";
|
|
||||||
Number = " ";
|
|
||||||
Object = " ";
|
|
||||||
Operator = " ";
|
|
||||||
Package = " ";
|
|
||||||
Property = " ";
|
|
||||||
Reference = " ";
|
|
||||||
Snippet = " ";
|
|
||||||
String = " ";
|
|
||||||
Struct = " ";
|
|
||||||
TabNine = " ";
|
|
||||||
Text = " ";
|
|
||||||
TypeParameter = " ";
|
|
||||||
Unit = " ";
|
|
||||||
Value = " ";
|
|
||||||
Variable = " ";
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,616 +0,0 @@
|
|||||||
{
|
|
||||||
globals.mapleader = " ";
|
|
||||||
|
|
||||||
keymaps = [
|
|
||||||
# better up/down
|
|
||||||
{
|
|
||||||
mode = ["n" "x"];
|
|
||||||
key = "j";
|
|
||||||
action = "v:count == 0 ? 'gj' : 'j'";
|
|
||||||
options = {
|
|
||||||
desc = "Down";
|
|
||||||
expr = true;
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = ["n" "x"];
|
|
||||||
key = "<Down>";
|
|
||||||
action = "v:count == 0 ? 'gj' : 'j'";
|
|
||||||
options = {
|
|
||||||
desc = "Down";
|
|
||||||
expr = true;
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = ["n" "x"];
|
|
||||||
key = "k";
|
|
||||||
action = "v:count == 0 ? 'gk' : 'k'";
|
|
||||||
options = {
|
|
||||||
desc = "Up";
|
|
||||||
expr = true;
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = ["n" "x"];
|
|
||||||
key = "<Up>";
|
|
||||||
action = "v:count == 0 ? 'gk' : 'k'";
|
|
||||||
options = {
|
|
||||||
desc = "Up";
|
|
||||||
expr = true;
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Clear search with <esc>
|
|
||||||
{
|
|
||||||
mode = ["i" "n"];
|
|
||||||
key = "<esc>";
|
|
||||||
action = "<cmd>noh<cr><esc>";
|
|
||||||
options = {
|
|
||||||
desc = "Escape and Clear hlsearch";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Add undo break-points
|
|
||||||
{
|
|
||||||
mode = "i";
|
|
||||||
key = ",";
|
|
||||||
action = ",<c-g>u";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "i";
|
|
||||||
key = ".";
|
|
||||||
action = ".<c-g>u";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "i";
|
|
||||||
key = ";";
|
|
||||||
action = ";<c-g>u";
|
|
||||||
}
|
|
||||||
|
|
||||||
# Move to window using the <ctrl> hjkl keys
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-h>";
|
|
||||||
action = "<C-w>h";
|
|
||||||
options = {
|
|
||||||
desc = "Go to Left Window";
|
|
||||||
remap = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-j>";
|
|
||||||
action = "<C-w>j";
|
|
||||||
options = {
|
|
||||||
desc = "Go to Lower Window";
|
|
||||||
remap = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-k>";
|
|
||||||
action = "<C-w>k";
|
|
||||||
options = {
|
|
||||||
desc = "Go to Upper Window";
|
|
||||||
remap = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-l>";
|
|
||||||
action = "<C-w>l";
|
|
||||||
options = {
|
|
||||||
desc = "Go to Right Window";
|
|
||||||
remap = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Resize window using <ctrl> arrow keys
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-Up>";
|
|
||||||
action = "<cmd>resize +2<cr>";
|
|
||||||
options = {desc = "Increase Window Height";};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-Down>";
|
|
||||||
action = "<cmd>resize -2<cr>";
|
|
||||||
options = {desc = "Decrease Window Height";};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-Left>";
|
|
||||||
action = "<cmd>vertical resize -2<cr>";
|
|
||||||
options = {desc = "Decrease Window Width";};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-Right>";
|
|
||||||
action = "<cmd>vertical resize +2<cr>";
|
|
||||||
options = {desc = "Increase Window Width";};
|
|
||||||
}
|
|
||||||
|
|
||||||
# General maps
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>f";
|
|
||||||
action = "+find/file";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>s";
|
|
||||||
action = "+search";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>q";
|
|
||||||
action = "+quit/session";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>g";
|
|
||||||
action = "+git";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>u";
|
|
||||||
action = "+ui";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>w";
|
|
||||||
action = "+windows";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><Tab>";
|
|
||||||
action = "+tab";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>d";
|
|
||||||
action = "+debug";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>c";
|
|
||||||
action = "+code";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>t";
|
|
||||||
action = "+test";
|
|
||||||
}
|
|
||||||
|
|
||||||
# Tabs
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><tab>l";
|
|
||||||
action = "<cmd>tablast<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Last tab";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><tab>f";
|
|
||||||
action = "<cmd>tabfirst<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "First Tab";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><tab><tab>";
|
|
||||||
action = "<cmd>tabnew<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "New Tab";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><tab>]";
|
|
||||||
action = "<cmd>tabnext<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Next Tab";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><tab>d";
|
|
||||||
action = "<cmd>tabclose<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Close tab";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader><tab>[";
|
|
||||||
action = "<cmd>tabprevious<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Previous Tab";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Windows
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ww";
|
|
||||||
action = "<C-W>p";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Other window";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>wd";
|
|
||||||
action = "<C-W>c";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Delete window";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>w-";
|
|
||||||
action = "<C-W>s";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Split window below";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>w|";
|
|
||||||
action = "<C-W>v";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Split window right";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# {
|
|
||||||
# mode = "n";
|
|
||||||
# key = "<leader>-";
|
|
||||||
# action = "<C-W>s";
|
|
||||||
# options = {
|
|
||||||
# silent = true;
|
|
||||||
# desc = "Split window below";
|
|
||||||
# };
|
|
||||||
# }
|
|
||||||
|
|
||||||
# {
|
|
||||||
# mode = "n";
|
|
||||||
# key = "<leader>|";
|
|
||||||
# action = "<C-W>v";
|
|
||||||
# options = {
|
|
||||||
# silent = true;
|
|
||||||
# desc = "Split window right";
|
|
||||||
# };
|
|
||||||
# }
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-s>";
|
|
||||||
action = "<cmd>w<cr><esc>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Save file";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Quit/Session
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>qq";
|
|
||||||
action = "<cmd>quitall<cr><esc>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Quit all";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>qs";
|
|
||||||
action = ":lua require('persistence').load()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Restore session";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ql";
|
|
||||||
action = "<cmd>lua require('persistence').load({ last = true })<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Restore last session";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>qd";
|
|
||||||
action = "<cmd>lua require('persistence').stop()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Don't save current session";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ul";
|
|
||||||
action = ":lua ToggleLineNumber()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Toggle Line Numbers";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>uL";
|
|
||||||
action = ":lua ToggleRelativeLineNumber()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Toggle Relative Line Numbers";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>uw";
|
|
||||||
action = ":lua ToggleWrap()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Toggle Line Wrap";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "v";
|
|
||||||
key = "J";
|
|
||||||
action = ":m '>+1<CR>gv=gv";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Move up when line is highlighted";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "v";
|
|
||||||
key = "K";
|
|
||||||
action = ":m '<-2<CR>gv=gv";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Move down when line is highlighted";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "J";
|
|
||||||
action = "mzJ`z";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Allow cursor to stay in the same place after appeding to current line";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# better indenting
|
|
||||||
{
|
|
||||||
mode = "v";
|
|
||||||
key = "<";
|
|
||||||
action = "<gv";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Indent while remaining in visual mode.";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "v";
|
|
||||||
key = ">";
|
|
||||||
action = ">gv";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Indent while remaining in visual mode.";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-d>";
|
|
||||||
action = "<C-d>zz";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Allow <C-d> and <C-u> to keep the cursor in the middle";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-u>";
|
|
||||||
action = "<C-u>zz";
|
|
||||||
options = {
|
|
||||||
desc = "Allow C-d and C-u to keep the cursor in the middle";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Remap for dealing with word wrap and adding jumps to the jumplist.
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "j";
|
|
||||||
action.__raw = "
|
|
||||||
[[(v:count > 1 ? 'm`' . v:count : 'g') . 'j']]
|
|
||||||
";
|
|
||||||
options = {
|
|
||||||
expr = true;
|
|
||||||
desc = "Remap for dealing with word wrap and adding jumps to the jumplist.";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "k";
|
|
||||||
action.__raw = "
|
|
||||||
[[(v:count > 1 ? 'm`' . v:count : 'g') . 'k']]
|
|
||||||
";
|
|
||||||
options = {
|
|
||||||
expr = true;
|
|
||||||
desc = "Remap for dealing with word wrap and adding jumps to the jumplist.";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "n";
|
|
||||||
action = "nzzzv";
|
|
||||||
options = {
|
|
||||||
desc = "Allow search terms to stay in the middle";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "N";
|
|
||||||
action = "Nzzzv";
|
|
||||||
options = {
|
|
||||||
desc = "Allow search terms to stay in the middle";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Paste stuff without saving the deleted word into the buffer
|
|
||||||
{
|
|
||||||
mode = "x";
|
|
||||||
key = "<leader>p";
|
|
||||||
action = "\"_dP";
|
|
||||||
options = {
|
|
||||||
desc = "Deletes to void register and paste over";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Copy stuff to system clipboard with <leader> + y or just y to have it just in vim
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>y";
|
|
||||||
action = "\"+y";
|
|
||||||
options = {
|
|
||||||
desc = "Copy to system clipboard";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>Y";
|
|
||||||
action = "\"+Y";
|
|
||||||
options = {
|
|
||||||
desc = "Copy to system clipboard";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# Delete to void register
|
|
||||||
{
|
|
||||||
mode = ["n" "v"];
|
|
||||||
key = "<leader>D";
|
|
||||||
action = "\"_d";
|
|
||||||
options = {
|
|
||||||
desc = "Delete to void register";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# <C-c> instead of pressing esc just because
|
|
||||||
{
|
|
||||||
mode = "i";
|
|
||||||
key = "<C-c>";
|
|
||||||
action = "<Esc>";
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<C-f>";
|
|
||||||
action = "!tmux new tmux-sessionizer<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Switch between projects";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
extraConfigLua = ''
|
|
||||||
local notify = require("notify")
|
|
||||||
|
|
||||||
local function show_notification(message, level)
|
|
||||||
notify(message, level, { title = "conform.nvim" })
|
|
||||||
end
|
|
||||||
|
|
||||||
function ToggleLineNumber()
|
|
||||||
if vim.wo.number then
|
|
||||||
vim.wo.number = false
|
|
||||||
show_notification("Line numbers disabled", "info")
|
|
||||||
else
|
|
||||||
vim.wo.number = true
|
|
||||||
vim.wo.relativenumber = false
|
|
||||||
show_notification("Line numbers enabled", "info")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function ToggleRelativeLineNumber()
|
|
||||||
if vim.wo.relativenumber then
|
|
||||||
vim.wo.relativenumber = false
|
|
||||||
show_notification("Relative line numbers disabled", "info")
|
|
||||||
else
|
|
||||||
vim.wo.relativenumber = true
|
|
||||||
vim.wo.number = false
|
|
||||||
show_notification("Relative line numbers enabled", "info")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
function ToggleWrap()
|
|
||||||
if vim.wo.wrap then
|
|
||||||
vim.wo.wrap = false
|
|
||||||
show_notification("Wrap disabled", "info")
|
|
||||||
else
|
|
||||||
vim.wo.wrap = true
|
|
||||||
vim.wo.number = false
|
|
||||||
show_notification("Wrap enabled", "info")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
if vim.lsp.inlay_hint then
|
|
||||||
vim.keymap.set('n', '<leader>uh', function()
|
|
||||||
vim.lsp.inlay_hint(0, nil)
|
|
||||||
end, { desc = 'Toggle Inlay Hints' })
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
}
|
|
@ -1,8 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.lsp.servers.texlab = {
|
|
||||||
enable = true;
|
|
||||||
settings.texlab = {
|
|
||||||
build.onSave = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,81 +0,0 @@
|
|||||||
let
|
|
||||||
javaTestPath = "/nix/store/j3nvmhvj2pmnykw5pbm51dn0bz4cv6j3-vscode-extension-vscjava-vscode-java-test-0.38.2023032402/share/vscode/extensions/vscjava.vscode-java-test/server/com.microsoft.java.test.plugin-0.38.2.jar
|
|
||||||
";
|
|
||||||
in {
|
|
||||||
plugins.nvim-jdtls = {
|
|
||||||
enable = true;
|
|
||||||
cmd = [
|
|
||||||
"/nix/store/20h2hjjm94gbskqhbwikbgxbblv1xpf2-jdt-language-server-1.31.0/bin/jdtls"
|
|
||||||
];
|
|
||||||
# configuration = "/path/to/configuration";
|
|
||||||
data = "~/.cache/jdtls/workspace";
|
|
||||||
settings = {
|
|
||||||
java = {
|
|
||||||
signatureHelp = true;
|
|
||||||
completion = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
initOptions = {
|
|
||||||
bundles = [
|
|
||||||
"/nix/store/b9ib40q36wxjl4xs5lng263lflz1fsi7-vscode-extension-vscjava-vscode-java-debug-0.49.2023032407/share/vscode/extensions/vscjava.vscode-java-debug/server/com.microsoft.java.debug.plugin-0.44.0.jar"
|
|
||||||
"${javaTestPath}"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
#
|
|
||||||
# extraConfigLua = ''
|
|
||||||
# local jdtls = require("jdtls")
|
|
||||||
# local cmp_nvim_lsp = require("cmp_nvim_lsp")
|
|
||||||
#
|
|
||||||
# local root_dir = require("jdtls.setup").find_root({ "packageInfo" }, "Config")
|
|
||||||
# local home = os.getenv("HOME")
|
|
||||||
# local eclipse_workspace = home .. "/.local/share/eclipse/" .. vim.fn.fnamemodify(root_dir, ":p:h:t")
|
|
||||||
#
|
|
||||||
# local ws_folders_jdtls = {}
|
|
||||||
# if root_dir then
|
|
||||||
# local file = io.open(root_dir .. "/.bemol/ws_root_folders")
|
|
||||||
# if file then
|
|
||||||
# for line in file:lines() do
|
|
||||||
# table.insert(ws_folders_jdtls, "file://" .. line)
|
|
||||||
# end
|
|
||||||
# file:close()
|
|
||||||
# end
|
|
||||||
# end
|
|
||||||
#
|
|
||||||
# -- for completions
|
|
||||||
# local client_capabilities = vim.lsp.protocol.make_client_capabilities()
|
|
||||||
# local capabilities = cmp_nvim_lsp.default_capabilities(client_capabilities)
|
|
||||||
#
|
|
||||||
# local config = {
|
|
||||||
# capabilities = capabilities,
|
|
||||||
# cmd = {
|
|
||||||
# "${pkgs.jdt-language-server}/bin/jdt-language-server",
|
|
||||||
# "--jvm-arg=-javaagent:" .. home .. "/Developer/lombok.jar",
|
|
||||||
# "-data",
|
|
||||||
# eclipse_workspace,
|
|
||||||
# "--add-modules=ALL-SYSTEM",
|
|
||||||
# },
|
|
||||||
# root_dir = root_dir,
|
|
||||||
# init_options = {
|
|
||||||
# workspaceFolders = ws_folders_jdtls,
|
|
||||||
# },
|
|
||||||
# settings = {
|
|
||||||
# java = {
|
|
||||||
# signatureHelp = { enabled = true},
|
|
||||||
# completion = { enabled = true },
|
|
||||||
# },
|
|
||||||
# },
|
|
||||||
# on_attach = function(client, bufnr)
|
|
||||||
# local opts = { silent = true, buffer = bufnr }
|
|
||||||
# vim.keymap.set('n', "<leader>lo", jdtls.organize_imports, { desc = 'Organize imports', buffer = bufnr })
|
|
||||||
# vim.keymap.set('n', "<leader>df", jdtls.test_class, opts)
|
|
||||||
# vim.keymap.set('n', "<leader>dn", jdtls.test_nearest_method, opts)
|
|
||||||
# vim.keymap.set('n', '<leader>rv', jdtls.extract_variable_all, { desc = 'Extract variable', buffer = bufnr })
|
|
||||||
# vim.keymap.set('n', '<leader>rc', jdtls.extract_constant, { desc = 'Extract constant', buffer = bufnr })
|
|
||||||
# end
|
|
||||||
# }
|
|
||||||
#
|
|
||||||
# jdtls.start_or_attach(config)
|
|
||||||
# '';
|
|
||||||
|
|
@ -1,25 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
pkgsMaster,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
plugins.lint = {
|
|
||||||
enable = true;
|
|
||||||
lintersByFt = {
|
|
||||||
nix = ["statix"];
|
|
||||||
lua = ["selene"];
|
|
||||||
python = ["flake8"];
|
|
||||||
javascript = ["eslint_d"];
|
|
||||||
javascriptreact = ["eslint_d"];
|
|
||||||
typescript = ["eslint_d"];
|
|
||||||
typescriptreact = ["eslint_d"];
|
|
||||||
json = ["jsonlint"];
|
|
||||||
java = ["checkstyle"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
extraPackages = with pkgs; [
|
|
||||||
statix
|
|
||||||
pkgsMaster.eslint_d
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,9 +0,0 @@
|
|||||||
{
|
|
||||||
plugins = {
|
|
||||||
lsp.servers.pyright = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
conform-nvim.formattersByFt = ["black"];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,19 +0,0 @@
|
|||||||
{
|
|
||||||
filetype.extension.mdx = "mdx";
|
|
||||||
|
|
||||||
plugins.treesitter.languageRegister.markdown = ["mdx"];
|
|
||||||
|
|
||||||
# Tree Sitter Grammar
|
|
||||||
extraFiles."queries/markdown/injections.scm" = {
|
|
||||||
enable = true;
|
|
||||||
text = ''
|
|
||||||
; extends
|
|
||||||
((inline) @injection.content
|
|
||||||
(#lua-match? @injection.content "^%s*import")
|
|
||||||
(#set! injection.language "typescript"))
|
|
||||||
((inline) @injection.content
|
|
||||||
(#lua-match? @injection.content "^%s*export")
|
|
||||||
(#set! injection.language "typescript"))
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.treesitter-context = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,50 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.treesitter-textobjects = {
|
|
||||||
enable = false;
|
|
||||||
select = {
|
|
||||||
enable = true;
|
|
||||||
lookahead = true;
|
|
||||||
keymaps = {
|
|
||||||
"aa" = "@parameter.outer";
|
|
||||||
"ia" = "@parameter.inner";
|
|
||||||
"af" = "@function.outer";
|
|
||||||
"if" = "@function.inner";
|
|
||||||
"ac" = "@class.outer";
|
|
||||||
"ic" = "@class.inner";
|
|
||||||
"ii" = "@conditional.inner";
|
|
||||||
"ai" = "@conditional.outer";
|
|
||||||
"il" = "@loop.inner";
|
|
||||||
"al" = "@loop.outer";
|
|
||||||
"at" = "@comment.outer";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
move = {
|
|
||||||
enable = true;
|
|
||||||
gotoNextStart = {
|
|
||||||
"]m" = "@function.outer";
|
|
||||||
"]]" = "@class.outer";
|
|
||||||
};
|
|
||||||
gotoNextEnd = {
|
|
||||||
"]M" = "@function.outer";
|
|
||||||
"][" = "@class.outer";
|
|
||||||
};
|
|
||||||
gotoPreviousStart = {
|
|
||||||
"[m" = "@function.outer";
|
|
||||||
"[[" = "@class.outer";
|
|
||||||
};
|
|
||||||
gotoPreviousEnd = {
|
|
||||||
"[M" = "@function.outer";
|
|
||||||
"[]" = "@class.outer";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
swap = {
|
|
||||||
enable = true;
|
|
||||||
swapNext = {
|
|
||||||
"<leader>a" = "@parameters.inner";
|
|
||||||
};
|
|
||||||
swapPrevious = {
|
|
||||||
"<leader>A" = "@parameter.outer";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,11 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.treesitter = {
|
|
||||||
enable = true;
|
|
||||||
folding = true;
|
|
||||||
nixvimInjections = true;
|
|
||||||
settings = {
|
|
||||||
highlight.enable = true;
|
|
||||||
indent.enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.ts-autotag = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.ts-context-commentstring = {
|
|
||||||
enable = true;
|
|
||||||
disableAutoInitialization = false;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,50 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.typescript-tools = {
|
|
||||||
enable = false;
|
|
||||||
settings = {
|
|
||||||
tsserverFilePreferences = {
|
|
||||||
# Inlay Hints
|
|
||||||
includeInlayParameterNameHints = "all";
|
|
||||||
includeInlayParameterNameHintsWhenArgumentMatchesName = true;
|
|
||||||
includeInlayFunctionParameterTypeHints = true;
|
|
||||||
includeInlayVariableTypeHints = true;
|
|
||||||
includeInlayVariableTypeHintsWhenTypeMatchesName = true;
|
|
||||||
includeInlayPropertyDeclarationTypeHints = true;
|
|
||||||
includeInlayFunctionLikeReturnTypeHints = true;
|
|
||||||
includeInlayEnumMemberValueHints = true;
|
|
||||||
};
|
|
||||||
tsserverPlugins = [
|
|
||||||
"@vue/typescript-plugin"
|
|
||||||
];
|
|
||||||
on_attach = ''
|
|
||||||
function(client, bufnr)
|
|
||||||
client.server_capabilities.documentFormattingProvider = false
|
|
||||||
client.server_capabilities.documentRangeFormattingProvider = false
|
|
||||||
|
|
||||||
if vim.lsp.inlay_hint then
|
|
||||||
vim.lsp.inlay_hint(bufnr, true)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>co";
|
|
||||||
action = "<cmd>TSToolsOrganizeImports<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Organize Imports";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>cR";
|
|
||||||
action = "<cmd>TSToolsRemoveUnusedImports<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Remove Unused Imports";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,103 +0,0 @@
|
|||||||
{pkgs, ...}: {
|
|
||||||
plugins.conform-nvim = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
notify_on_error = true;
|
|
||||||
formatters_by_ft = {
|
|
||||||
html = [["prettierd" "prettier"]];
|
|
||||||
css = [["prettierd" "prettier"]];
|
|
||||||
javascript = [["prettierd" "prettier"]];
|
|
||||||
javascriptreact = [["prettierd" "prettier"]];
|
|
||||||
typescript = [["prettierd" "prettier"]];
|
|
||||||
typescriptreact = [["prettierd" "prettier"]];
|
|
||||||
astro = [["prettierd" "prettier"]];
|
|
||||||
vue = [["prettierd" "prettier"]];
|
|
||||||
json = [["prettierd" "prettier"]];
|
|
||||||
yaml = [["prettierd" "prettier"]];
|
|
||||||
java = ["google-java-format"];
|
|
||||||
python = ["black"];
|
|
||||||
lua = ["stylua"];
|
|
||||||
nix = ["alejandra"];
|
|
||||||
markdown = [["prettierd" "prettier"]];
|
|
||||||
rust = ["rustfmt"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
extraPackages = with pkgs; [
|
|
||||||
prettierd
|
|
||||||
alejandra
|
|
||||||
];
|
|
||||||
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>uf";
|
|
||||||
action = ":FormatToggle<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Toggle Format";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>cf";
|
|
||||||
action = "<cmd>lua require('conform').format()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Format Buffer";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "v";
|
|
||||||
key = "<leader>cF";
|
|
||||||
action = "<cmd>lua require('conform').format()<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Format Lines";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
|
|
||||||
extraConfigLua = ''
|
|
||||||
local conform = require("conform")
|
|
||||||
local notify = require("notify")
|
|
||||||
|
|
||||||
conform.setup({
|
|
||||||
format_on_save = function(bufnr)
|
|
||||||
-- Disable with a global or buffer-local variable
|
|
||||||
if vim.g.disable_autoformat or vim.b[bufnr].disable_autoformat then
|
|
||||||
return
|
|
||||||
end
|
|
||||||
return { timeout_ms = 500, lsp_fallback = true }
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
||||||
local function show_notification(message, level)
|
|
||||||
notify(message, level, { title = "conform.nvim" })
|
|
||||||
end
|
|
||||||
|
|
||||||
vim.api.nvim_create_user_command("FormatToggle", function(args)
|
|
||||||
local is_global = not args.bang
|
|
||||||
if is_global then
|
|
||||||
vim.g.disable_autoformat = not vim.g.disable_autoformat
|
|
||||||
if vim.g.disable_autoformat then
|
|
||||||
show_notification("Autoformat-on-save disabled globally", "info")
|
|
||||||
else
|
|
||||||
show_notification("Autoformat-on-save enabled globally", "info")
|
|
||||||
end
|
|
||||||
else
|
|
||||||
vim.b.disable_autoformat = not vim.b.disable_autoformat
|
|
||||||
if vim.b.disable_autoformat then
|
|
||||||
show_notification("Autoformat-on-save disabled for this buffer", "info")
|
|
||||||
else
|
|
||||||
show_notification("Autoformat-on-save enabled for this buffer", "info")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end, {
|
|
||||||
desc = "Toggle autoformat-on-save",
|
|
||||||
bang = true,
|
|
||||||
})
|
|
||||||
'';
|
|
||||||
}
|
|
@ -1,99 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.fidget = {
|
|
||||||
enable = true;
|
|
||||||
logger = {
|
|
||||||
level = "warn"; # “off”, “error”, “warn”, “info”, “debug”, “trace”
|
|
||||||
floatPrecision = 0.01; # Limit the number of decimals displayed for floats
|
|
||||||
};
|
|
||||||
progress = {
|
|
||||||
pollRate = 0; # How and when to poll for progress messages
|
|
||||||
suppressOnInsert = true; # Suppress new messages while in insert mode
|
|
||||||
ignoreDoneAlready = false; # Ignore new tasks that are already complete
|
|
||||||
ignoreEmptyMessage = false; # Ignore new tasks that don't contain a message
|
|
||||||
clearOnDetach =
|
|
||||||
# Clear notification group when LSP server detaches
|
|
||||||
''
|
|
||||||
function(client_id)
|
|
||||||
local client = vim.lsp.get_client_by_id(client_id)
|
|
||||||
return client and client.name or nil
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
notificationGroup =
|
|
||||||
# How to get a progress message's notification group key
|
|
||||||
''
|
|
||||||
function(msg) return msg.lsp_client.name end
|
|
||||||
'';
|
|
||||||
ignore = []; # List of LSP servers to ignore
|
|
||||||
lsp = {
|
|
||||||
progressRingbufSize = 0; # Configure the nvim's LSP progress ring buffer size
|
|
||||||
};
|
|
||||||
display = {
|
|
||||||
renderLimit = 16; # How many LSP messages to show at once
|
|
||||||
doneTtl = 3; # How long a message should persist after completion
|
|
||||||
doneIcon = "✔"; # Icon shown when all LSP progress tasks are complete
|
|
||||||
doneStyle = "Constant"; # Highlight group for completed LSP tasks
|
|
||||||
progressTtl = "math.huge"; # How long a message should persist when in progress
|
|
||||||
progressIcon = {
|
|
||||||
pattern = "dots";
|
|
||||||
period = 1;
|
|
||||||
}; # Icon shown when LSP progress tasks are in progress
|
|
||||||
progressStyle = "WarningMsg"; # Highlight group for in-progress LSP tasks
|
|
||||||
groupStyle = "Title"; # Highlight group for group name (LSP server name)
|
|
||||||
iconStyle = "Question"; # Highlight group for group icons
|
|
||||||
priority = 30; # Ordering priority for LSP notification group
|
|
||||||
skipHistory = true; # Whether progress notifications should be omitted from history
|
|
||||||
formatMessage = ''
|
|
||||||
require ("fidget.progress.display").default_format_message
|
|
||||||
''; # How to format a progress message
|
|
||||||
formatAnnote = ''
|
|
||||||
function (msg) return msg.title end
|
|
||||||
''; # How to format a progress annotation
|
|
||||||
formatGroupName = ''
|
|
||||||
function (group) return tostring (group) end
|
|
||||||
''; # How to format a progress notification group's name
|
|
||||||
overrides = {
|
|
||||||
rust_analyzer = {
|
|
||||||
name = "rust-analyzer";
|
|
||||||
};
|
|
||||||
}; # Override options from the default notification config
|
|
||||||
};
|
|
||||||
};
|
|
||||||
notification = {
|
|
||||||
pollRate = 10; # How frequently to update and render notifications
|
|
||||||
filter = "info"; # “off”, “error”, “warn”, “info”, “debug”, “trace”
|
|
||||||
historySize = 128; # Number of removed messages to retain in history
|
|
||||||
overrideVimNotify = true;
|
|
||||||
redirect = ''
|
|
||||||
function(msg, level, opts)
|
|
||||||
if opts and opts.on_open then
|
|
||||||
return require("fidget.integration.nvim-notify").delegate(msg, level, opts)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
configs = {
|
|
||||||
default = "require('fidget.notification').default_config";
|
|
||||||
};
|
|
||||||
|
|
||||||
window = {
|
|
||||||
normalHl = "Comment";
|
|
||||||
winblend = 0;
|
|
||||||
border = "none"; # none, single, double, rounded, solid, shadow
|
|
||||||
zindex = 45;
|
|
||||||
maxWidth = 0;
|
|
||||||
maxHeight = 0;
|
|
||||||
xPadding = 1;
|
|
||||||
yPadding = 0;
|
|
||||||
align = "bottom";
|
|
||||||
relative = "editor";
|
|
||||||
};
|
|
||||||
view = {
|
|
||||||
stackUpwards = true; # Display notification items from bottom to top
|
|
||||||
iconSeparator = " "; # Separator between group name and icon
|
|
||||||
groupSeparator = "---"; # Separator between notification groups
|
|
||||||
groupSeparatorHl =
|
|
||||||
# Highlight group used for group separator
|
|
||||||
"Comment";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,188 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
icons,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
plugins = {
|
|
||||||
lsp-format = {
|
|
||||||
enable = false; # Enable it if you want lsp-format integration for none-ls
|
|
||||||
};
|
|
||||||
lsp = {
|
|
||||||
enable = true;
|
|
||||||
capabilities = "offsetEncoding = 'utf-16'";
|
|
||||||
servers = {
|
|
||||||
clangd = {enable = true;};
|
|
||||||
lua_ls = {
|
|
||||||
enable = true;
|
|
||||||
extraOptions = {
|
|
||||||
settings = {
|
|
||||||
Lua = {
|
|
||||||
completion = {
|
|
||||||
callSnippet = "Replace";
|
|
||||||
};
|
|
||||||
telemetry = {
|
|
||||||
enabled = false;
|
|
||||||
};
|
|
||||||
hint = {enable = true;};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
nil_ls = {enable = true;};
|
|
||||||
ts_ls = {
|
|
||||||
enable = true;
|
|
||||||
extraOptions = {
|
|
||||||
settings = {
|
|
||||||
javascript = {
|
|
||||||
inlayHints = {
|
|
||||||
includeInlayEnumMemberValueHints = true;
|
|
||||||
includeInlayFunctionLikeReturnTypeHints = true;
|
|
||||||
includeInlayFunctionParameterTypeHints = true;
|
|
||||||
includeInlayParameterNameHints = "all";
|
|
||||||
includeInlayParameterNameHintsWhenArgumentMatchesName = true;
|
|
||||||
includeInlayPropertyDeclarationTypeHints = true;
|
|
||||||
includeInlayVariableTypeHints = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
typescript = {
|
|
||||||
inlayHints = {
|
|
||||||
includeInlayEnumMemberValueHints = true;
|
|
||||||
includeInlayFunctionLikeReturnTypeHints = true;
|
|
||||||
includeInlayFunctionParameterTypeHints = true;
|
|
||||||
includeInlayParameterNameHints = "all";
|
|
||||||
includeInlayParameterNameHintsWhenArgumentMatchesName = true;
|
|
||||||
includeInlayPropertyDeclarationTypeHints = true;
|
|
||||||
includeInlayVariableTypeHints = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
astro = {enable = true;};
|
|
||||||
volar = {
|
|
||||||
enable = true;
|
|
||||||
package = pkgs.vue-language-server;
|
|
||||||
tslsIntegration = true;
|
|
||||||
rootDir = ''require("lspconfig.util").root_pattern("src/App.vue")'';
|
|
||||||
};
|
|
||||||
svelte = {enable = true;};
|
|
||||||
eslint = {enable = true;};
|
|
||||||
pyright = {enable = true;};
|
|
||||||
ruff_lsp = {enable = true;};
|
|
||||||
|
|
||||||
rust_analyzer = {
|
|
||||||
enable = true;
|
|
||||||
installCargo = false;
|
|
||||||
installRustc = false;
|
|
||||||
settings = {
|
|
||||||
checkOnSave = true;
|
|
||||||
check = {
|
|
||||||
command = "clippy";
|
|
||||||
};
|
|
||||||
# inlayHints = {
|
|
||||||
# enable = true;
|
|
||||||
# showParameterNames = true;
|
|
||||||
# parameterHintsPrefix = "<- ";
|
|
||||||
# otherHintsPrefix = "=> ";
|
|
||||||
# };
|
|
||||||
procMacro = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
dartls.enable = true;
|
|
||||||
};
|
|
||||||
# keymaps = {
|
|
||||||
# silent = true;
|
|
||||||
# lspBuf = {
|
|
||||||
# gd = {
|
|
||||||
# action = "definition";
|
|
||||||
# desc = "Goto Definition";
|
|
||||||
# };
|
|
||||||
# gr = {
|
|
||||||
# action = "references";
|
|
||||||
# desc = "Goto References";
|
|
||||||
# };
|
|
||||||
# gD = {
|
|
||||||
# action = "declaration";
|
|
||||||
# desc = "Goto Declaration";
|
|
||||||
# };
|
|
||||||
# gI = {
|
|
||||||
# action = "implementation";
|
|
||||||
# desc = "Goto Implementation";
|
|
||||||
# };
|
|
||||||
# gT = {
|
|
||||||
# action = "type_definition";
|
|
||||||
# desc = "Type Definition";
|
|
||||||
# };
|
|
||||||
# K = {
|
|
||||||
# action = "hover";
|
|
||||||
# desc = "Hover";
|
|
||||||
# };
|
|
||||||
# "<leader>cw" = {
|
|
||||||
# action = "workspace_symbol";
|
|
||||||
# desc = "Workspace Symbol";
|
|
||||||
# };
|
|
||||||
# "<leader>cr" = {
|
|
||||||
# action = "rename";
|
|
||||||
# desc = "Rename";
|
|
||||||
# };
|
|
||||||
# "<leader>ca" = {
|
|
||||||
# action = "code_action";
|
|
||||||
# desc = "Code Action";
|
|
||||||
# };
|
|
||||||
# "<C-k>" = {
|
|
||||||
# action = "signature_help";
|
|
||||||
# desc = "Signature Help";
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
# diagnostic = {
|
|
||||||
# "<leader>cd" = {
|
|
||||||
# action = "open_float";
|
|
||||||
# desc = "Line Diagnostics";
|
|
||||||
# };
|
|
||||||
# "[d" = {
|
|
||||||
# action = "goto_next";
|
|
||||||
# desc = "Next Diagnostic";
|
|
||||||
# };
|
|
||||||
# "]d" = {
|
|
||||||
# action = "goto_prev";
|
|
||||||
# desc = "Previous Diagnostic";
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
# };
|
|
||||||
};
|
|
||||||
};
|
|
||||||
extraConfigLua = ''
|
|
||||||
local _border = "rounded"
|
|
||||||
|
|
||||||
vim.lsp.handlers["textDocument/hover"] = vim.lsp.with(
|
|
||||||
vim.lsp.handlers.hover, {
|
|
||||||
border = _border
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
vim.lsp.handlers["textDocument/signatureHelp"] = vim.lsp.with(
|
|
||||||
vim.lsp.handlers.signature_help, {
|
|
||||||
border = _border
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
||||||
vim.diagnostic.config({
|
|
||||||
float={border=_border},
|
|
||||||
signs = {
|
|
||||||
text = {
|
|
||||||
[vim.diagnostic.severity.ERROR] = "${icons.diagnostics.Error}",
|
|
||||||
[vim.diagnostic.severity.WARN] = "${icons.diagnostics.Warn}",
|
|
||||||
[vim.diagnostic.severity.HINT] = "${icons.diagnostics.Hint}",
|
|
||||||
[vim.diagnostic.severity.INFO] = "${icons.diagnostics.Info}",
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
require('lspconfig.ui.windows').default_options = {
|
|
||||||
border = _border
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
}
|
|
@ -1,186 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.lspsaga = {
|
|
||||||
enable = true;
|
|
||||||
beacon = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
ui = {
|
|
||||||
border = "rounded"; # One of none, single, double, rounded, solid, shadow
|
|
||||||
codeAction = "💡"; # Can be any symbol you want 💡
|
|
||||||
};
|
|
||||||
hover = {
|
|
||||||
openCmd = "!floorp"; # Choose your browser
|
|
||||||
openLink = "gx";
|
|
||||||
};
|
|
||||||
diagnostic = {
|
|
||||||
borderFollow = true;
|
|
||||||
diagnosticOnlyCurrent = false;
|
|
||||||
showCodeAction = true;
|
|
||||||
};
|
|
||||||
symbolInWinbar = {
|
|
||||||
enable = false; # Breadcrumbs
|
|
||||||
};
|
|
||||||
codeAction = {
|
|
||||||
extendGitSigns = false;
|
|
||||||
showServerName = true;
|
|
||||||
onlyInCursor = true;
|
|
||||||
numShortcut = true;
|
|
||||||
keys = {
|
|
||||||
exec = "<CR>";
|
|
||||||
quit = ["<Esc>" "q"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
lightbulb = {
|
|
||||||
enable = false;
|
|
||||||
sign = false;
|
|
||||||
virtualText = true;
|
|
||||||
};
|
|
||||||
implement = {
|
|
||||||
enable = false;
|
|
||||||
};
|
|
||||||
rename = {
|
|
||||||
autoSave = false;
|
|
||||||
keys = {
|
|
||||||
exec = "<CR>";
|
|
||||||
quit = ["<C-k>" "<Esc>"];
|
|
||||||
select = "x";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
outline = {
|
|
||||||
autoClose = true;
|
|
||||||
autoPreview = true;
|
|
||||||
closeAfterJump = true;
|
|
||||||
layout = "normal"; # normal or float
|
|
||||||
winPosition = "right"; # left or right
|
|
||||||
keys = {
|
|
||||||
jump = "e";
|
|
||||||
quit = "q";
|
|
||||||
toggleOrJump = "o";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
scrollPreview = {
|
|
||||||
scrollDown = "<C-f>";
|
|
||||||
scrollUp = "<C-b>";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "gd";
|
|
||||||
action = "<cmd>Lspsaga finder def<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Goto Definition";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "gr";
|
|
||||||
action = "<cmd>Lspsaga finder ref<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Goto References";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# {
|
|
||||||
# mode = "n";
|
|
||||||
# key = "gD";
|
|
||||||
# action = "<cmd>Lspsaga show_line_diagnostics<CR>";
|
|
||||||
# options = {
|
|
||||||
# desc = "Goto Declaration";
|
|
||||||
# silent = true;
|
|
||||||
# };
|
|
||||||
# }
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "gI";
|
|
||||||
action = "<cmd>Lspsaga finder imp<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Goto Implementation";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "gT";
|
|
||||||
action = "<cmd>Lspsaga peek_type_definition<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Type Definition";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "K";
|
|
||||||
action = "<cmd>Lspsaga hover_doc<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Hover";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>cw";
|
|
||||||
action = "<cmd>Lspsaga outline<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Outline";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>cr";
|
|
||||||
action = "<cmd>Lspsaga rename<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Rename";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>ca";
|
|
||||||
action = "<cmd>Lspsaga code_action<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Code Action";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>cd";
|
|
||||||
action = "<cmd>Lspsaga show_line_diagnostics<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Line Diagnostics";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "[d";
|
|
||||||
action = "<cmd>Lspsaga diagnostic_jump_next<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Next Diagnostic";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "]d";
|
|
||||||
action = "<cmd>Lspsaga diagnostic_jump_prev<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Previous Diagnostic";
|
|
||||||
silent = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,52 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.trouble = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
auto_close = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
# TODO: Add keybinds to close trouble (q would be nice), rn I need to use :x to close it...
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>x";
|
|
||||||
action = "+diagnostics/quickfix";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>xx";
|
|
||||||
action = "<cmd>TroubleToggle<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Document Diagnostics (Trouble)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>xX";
|
|
||||||
action = "<cmd>TroubleToggle workspace_diagnostics<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Workspace Diagnostics (Trouble)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>xt";
|
|
||||||
action = "<cmd>TroubleToggle todo<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Todo (Trouble)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>xQ";
|
|
||||||
action = "<cmd>TodoQuickFix<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Quickfix List (Trouble)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
@ -1,71 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.none-ls = {
|
|
||||||
enable = false;
|
|
||||||
enableLspFormat = false;
|
|
||||||
settings = {
|
|
||||||
update_in_insert = false;
|
|
||||||
on_attach = ''
|
|
||||||
function(client, bufnr)
|
|
||||||
if client.supports_method "textDocument/formatting" then
|
|
||||||
vim.api.nvim_clear_autocmds { group = augroup, buffer = bufnr }
|
|
||||||
vim.api.nvim_create_autocmd("BufWritePre", {
|
|
||||||
group = augroup,
|
|
||||||
buffer = bufnr,
|
|
||||||
callback = function()
|
|
||||||
vim.lsp.buf.format { bufnr = bufnr }
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
end
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
sources = {
|
|
||||||
code_actions = {
|
|
||||||
gitsigns.enable = true;
|
|
||||||
statix.enable = true;
|
|
||||||
};
|
|
||||||
diagnostics = {
|
|
||||||
checkstyle = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
statix = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
formatting = {
|
|
||||||
alejandra = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
prettier = {
|
|
||||||
enable = true;
|
|
||||||
disableTsServerFormatter = true;
|
|
||||||
};
|
|
||||||
google_java_format = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
stylua = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
black = {
|
|
||||||
enable = true;
|
|
||||||
settings = ''
|
|
||||||
{
|
|
||||||
extra_args = { "--fast" },
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
# keymaps = [
|
|
||||||
# {
|
|
||||||
# mode = [ "n" "v" ];
|
|
||||||
# key = "<leader>cf";
|
|
||||||
# action = "<cmd>lua vim.lsp.buf.format()<cr>";
|
|
||||||
# options = {
|
|
||||||
# silent = true;
|
|
||||||
# desc = "Format";
|
|
||||||
# };
|
|
||||||
# }
|
|
||||||
# ];
|
|
||||||
}
|
|
@ -1,167 +0,0 @@
|
|||||||
{
|
|
||||||
config = {
|
|
||||||
# Set colorscheme
|
|
||||||
colorscheme = "gruvbox";
|
|
||||||
|
|
||||||
# Enable experimental lua loader
|
|
||||||
luaLoader.enable = true;
|
|
||||||
|
|
||||||
opts = {
|
|
||||||
# Autosave when changing buffers
|
|
||||||
autowrite = true;
|
|
||||||
|
|
||||||
# Enable relative line numbers
|
|
||||||
number = true;
|
|
||||||
relativenumber = true;
|
|
||||||
|
|
||||||
# Set tabs to 2 spaces
|
|
||||||
tabstop = 2;
|
|
||||||
softtabstop = 2;
|
|
||||||
showtabline = 2;
|
|
||||||
expandtab = true;
|
|
||||||
|
|
||||||
# Enable auto indenting and set it to spaces
|
|
||||||
smartindent = true;
|
|
||||||
shiftwidth = 2;
|
|
||||||
|
|
||||||
# Enable smart indenting (see https://stackoverflow.com/questions/1204149/smart-wrap-in-vim)
|
|
||||||
breakindent = true;
|
|
||||||
|
|
||||||
# Enable incremental searching
|
|
||||||
hlsearch = true;
|
|
||||||
incsearch = true;
|
|
||||||
|
|
||||||
# Enable text wrap
|
|
||||||
wrap = true;
|
|
||||||
|
|
||||||
# Better splitting
|
|
||||||
splitbelow = true;
|
|
||||||
splitright = true;
|
|
||||||
|
|
||||||
# Enable mouse mode
|
|
||||||
mouse = "a"; # Mouse
|
|
||||||
|
|
||||||
# Enable ignorecase + smartcase for better searching
|
|
||||||
ignorecase = true;
|
|
||||||
smartcase = true; # Don't ignore case with capitals
|
|
||||||
grepprg = "rg --vimgrep";
|
|
||||||
grepformat = "%f:%l:%c:%m";
|
|
||||||
|
|
||||||
# Decrease updatetime
|
|
||||||
updatetime = 50; # faster completion (4000ms default)
|
|
||||||
|
|
||||||
# Set completeopt to have a better completion experience
|
|
||||||
completeopt = ["menuone" "noselect" "noinsert"]; # mostly just for cmp
|
|
||||||
|
|
||||||
# Enable persistent undo history
|
|
||||||
swapfile = false;
|
|
||||||
backup = false;
|
|
||||||
undofile = true;
|
|
||||||
|
|
||||||
# Enable 24-bit colors
|
|
||||||
termguicolors = true;
|
|
||||||
|
|
||||||
# Enable the sign column to prevent the screen from jumping
|
|
||||||
signcolumn = "yes";
|
|
||||||
|
|
||||||
# Enable cursor line highlight
|
|
||||||
cursorline = true; # Highlight the line where the cursor is located
|
|
||||||
|
|
||||||
# Set fold settings
|
|
||||||
# These options were reccommended by nvim-ufo
|
|
||||||
# See: https://github.com/kevinhwang91/nvim-ufo#minimal-configuration
|
|
||||||
foldcolumn = "0";
|
|
||||||
foldlevel = 99;
|
|
||||||
foldlevelstart = 99;
|
|
||||||
foldenable = true;
|
|
||||||
|
|
||||||
# Always keep 8 lines above/below cursor unless at start/end of file
|
|
||||||
scrolloff = 8;
|
|
||||||
|
|
||||||
# Place a column line
|
|
||||||
colorcolumn = "80";
|
|
||||||
|
|
||||||
# Customize sidebar characters
|
|
||||||
fillchars = {
|
|
||||||
foldopen = "";
|
|
||||||
foldclose = "";
|
|
||||||
fold = " ";
|
|
||||||
foldsep = " ";
|
|
||||||
diff = "╱";
|
|
||||||
eob = " ";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Reduce which-key timeout to 10ms
|
|
||||||
timeoutlen = 10;
|
|
||||||
|
|
||||||
# Set encoding type
|
|
||||||
encoding = "utf-8";
|
|
||||||
fileencoding = "utf-8";
|
|
||||||
|
|
||||||
# Change cursor options
|
|
||||||
guicursor = [
|
|
||||||
"n-v-c:block" # Normal, visual, command-line: block cursor
|
|
||||||
"i-ci-ve:ver25" # Insert, command-line insert, visual-exclude: vertical bar cursor with block cursor, use "ver25" for 25% width
|
|
||||||
"r-cr:hor20" # Replace, command-line replace: horizontal bar cursor with 20% height
|
|
||||||
"o:hor50" # Operator-pending: horizontal bar cursor with 50% height
|
|
||||||
"a:blinkwait700-blinkoff400-blinkon250-Cursor/lCursor" # All modes: blinking settings
|
|
||||||
"sm:block-blinkwait175-blinkoff150-blinkon175" # Showmatch: block cursor with specific blinking settings
|
|
||||||
];
|
|
||||||
|
|
||||||
# Enable chars list
|
|
||||||
list = false; # Show invisible characters (tabs, eol, ...)
|
|
||||||
listchars = "eol:↲,tab:|->,lead:·,space: ,trail:•,extends:→,precedes:←,nbsp:␣";
|
|
||||||
|
|
||||||
# More space in the neovim command line for displaying messages
|
|
||||||
cmdheight = 2;
|
|
||||||
|
|
||||||
# We don't need to see things like INSERT anymore
|
|
||||||
showmode = false;
|
|
||||||
|
|
||||||
# Maximum number of items to show in the popup menu (0 means "use available screen space")
|
|
||||||
pumheight = 0;
|
|
||||||
|
|
||||||
# Use conform-nvim for gq formatting. ('formatexpr' is set to vim.lsp.formatexpr(), so you can format lines via gq if the language server supports it)
|
|
||||||
formatexpr = "v:lua.require'conform'.formatexpr()";
|
|
||||||
|
|
||||||
laststatus = 3; # (https://neovim.io/doc/user/options.html#'laststatus')
|
|
||||||
};
|
|
||||||
|
|
||||||
extraFiles = {
|
|
||||||
"lua/helpers.lua".source = ./helpers.lua;
|
|
||||||
};
|
|
||||||
|
|
||||||
extraConfigLuaPre = ''
|
|
||||||
require "helpers"
|
|
||||||
'';
|
|
||||||
|
|
||||||
extraConfigLua = ''
|
|
||||||
local opt = vim.opt
|
|
||||||
local g = vim.g
|
|
||||||
local o = vim.o
|
|
||||||
-- Neovide
|
|
||||||
if g.neovide then
|
|
||||||
-- Neovide options
|
|
||||||
g.neovide_fullscreen = false
|
|
||||||
g.neovide_hide_mouse_when_typing = false
|
|
||||||
g.neovide_refresh_rate = 165
|
|
||||||
g.neovide_cursor_vfx_mode = "ripple"
|
|
||||||
g.neovide_cursor_animate_command_line = true
|
|
||||||
g.neovide_cursor_animate_in_insert_mode = true
|
|
||||||
g.neovide_cursor_vfx_particle_lifetime = 5.0
|
|
||||||
g.neovide_cursor_vfx_particle_density = 14.0
|
|
||||||
g.neovide_cursor_vfx_particle_speed = 12.0
|
|
||||||
g.neovide_transparency = 0.8
|
|
||||||
|
|
||||||
-- Neovide Fonts
|
|
||||||
o.guifont = "MonoLisa Trial:Medium:h15"
|
|
||||||
-- o.guifont = "CommitMono:Medium:h15"
|
|
||||||
-- o.guifont = "JetBrainsMono Nerd Font:h14:Medium:i"
|
|
||||||
-- o.guifont = "FiraMono Nerd Font:Medium:h14"
|
|
||||||
-- o.guifont = "CaskaydiaCove Nerd Font:h14:b:i"
|
|
||||||
-- o.guifont = "BlexMono Nerd Font Mono:h14:Medium:i"
|
|
||||||
-- o.guifont = "Liga SFMono Nerd Font:b:h15"
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,15 +0,0 @@
|
|||||||
{pkgs, ...}: {
|
|
||||||
plugins.luasnip = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
enable_autosnippets = true;
|
|
||||||
store_selection_keys = "<Tab>";
|
|
||||||
};
|
|
||||||
fromVscode = [
|
|
||||||
{
|
|
||||||
lazyLoad = true;
|
|
||||||
paths = "${pkgs.vimPlugins.friendly-snippets}";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,93 +0,0 @@
|
|||||||
{icons, ...}: {
|
|
||||||
plugins.lualine = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
options = {
|
|
||||||
always_divide_middle = true;
|
|
||||||
globalstatus = true;
|
|
||||||
ignore_focus = ["neo-tree"];
|
|
||||||
theme = "auto";
|
|
||||||
component_separators = {
|
|
||||||
left = "·";
|
|
||||||
right = "·";
|
|
||||||
};
|
|
||||||
section_separators = {
|
|
||||||
left = ""; #
|
|
||||||
right = ""; #
|
|
||||||
};
|
|
||||||
};
|
|
||||||
extensions = ["fzf"];
|
|
||||||
sections = let
|
|
||||||
mkColor = color: {
|
|
||||||
__raw = ''function() return MVim.fg("${color}") end'';
|
|
||||||
};
|
|
||||||
in {
|
|
||||||
lualine_a = ["mode"];
|
|
||||||
lualine_b = ["branch"];
|
|
||||||
lualine_c = [
|
|
||||||
{
|
|
||||||
__unkeyed-1 = "diagnostics";
|
|
||||||
symbols = {
|
|
||||||
error = icons.diagnostics.Error;
|
|
||||||
warn = icons.diagnostics.Warn;
|
|
||||||
info = icons.diagnostics.Info;
|
|
||||||
hint = icons.diagnostics.Hint;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
__unkeyed-1 = "filetype";
|
|
||||||
icon_only = true;
|
|
||||||
separator = {
|
|
||||||
left = "";
|
|
||||||
right = "";
|
|
||||||
};
|
|
||||||
padding = {
|
|
||||||
left = 1;
|
|
||||||
right = 0;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
"filename"
|
|
||||||
];
|
|
||||||
|
|
||||||
lualine_x = [
|
|
||||||
# Command
|
|
||||||
{
|
|
||||||
__unkeyed-1.__raw = ''function() return require("noice").api.status.command.get() end'';
|
|
||||||
color = mkColor "Statement";
|
|
||||||
cond.__raw = ''function() return package.loaded["noice"] and require("noice").api.status.command.has() end'';
|
|
||||||
}
|
|
||||||
# Mode
|
|
||||||
{
|
|
||||||
__unkeyed-1.__raw = ''function() return require("noice").api.status.mode.get() end'';
|
|
||||||
color = mkColor "Constant";
|
|
||||||
cond.__raw = ''function() return package.loaded["noice"] and require("noice").api.status.mode.has() end'';
|
|
||||||
}
|
|
||||||
];
|
|
||||||
lualine_y = [
|
|
||||||
{
|
|
||||||
__unkeyed-1 = "progress";
|
|
||||||
separator = {
|
|
||||||
left = " ";
|
|
||||||
right = " ";
|
|
||||||
};
|
|
||||||
padding = {
|
|
||||||
left = 1;
|
|
||||||
right = 1;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
__unkeyed-1 = "location";
|
|
||||||
padding = {
|
|
||||||
left = 0;
|
|
||||||
right = 1;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
lualine_z = [''" " .. os.date("%I:%M %p"):gsub("0*", "", 1)''];
|
|
||||||
};
|
|
||||||
disabled_filetypes = {
|
|
||||||
statusline = ["dashboard" "alpha" "starter"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,65 +0,0 @@
|
|||||||
{pkgs, ...}: {
|
|
||||||
extraPlugins = with pkgs.vimUtils; [
|
|
||||||
(buildVimPlugin {
|
|
||||||
pname = "staline.nvim";
|
|
||||||
version = "2024-02-05";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "tamton-aquib";
|
|
||||||
repo = "staline.nvim";
|
|
||||||
rev = "a53f869278b8b186a5afd6f21680cd103c381599";
|
|
||||||
hash = "sha256-GDMKzxFDtQk5LL+rMsxTGTyLv69w5NUd+u19noeO5ws=";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
|
||||||
extraConfigLua = ''
|
|
||||||
require("staline").setup({
|
|
||||||
sections = {
|
|
||||||
left = { "-mode", " ", "branch" },
|
|
||||||
mid = { "lsp_name" },
|
|
||||||
right = { "file_name", "line_column" },
|
|
||||||
},
|
|
||||||
inactive_sections = {
|
|
||||||
left = { "-mode", " ", "branch" },
|
|
||||||
mid = { "lsp_name" },
|
|
||||||
right = { "file_name", "line_column" },
|
|
||||||
},
|
|
||||||
defaults = {
|
|
||||||
left_separator = " ",
|
|
||||||
right_separator = " ",
|
|
||||||
branch_symbol = " ",
|
|
||||||
mod_symbol = "",
|
|
||||||
line_column = "[%l/%L]",
|
|
||||||
inactive_color = "#80a6f2", --#303030 is the default
|
|
||||||
inactive_bgcolor = "none",
|
|
||||||
},
|
|
||||||
special_table = {
|
|
||||||
lazy = { "Plugins", "💤 " },
|
|
||||||
TelescopePrompt = { "Telescope", " " },
|
|
||||||
oil = { "Oil", " " },
|
|
||||||
lazygit = { "LazyGit", " " },
|
|
||||||
},
|
|
||||||
mode_icons = {
|
|
||||||
["n"] = "NORMAL",
|
|
||||||
["no"] = "NORMAL",
|
|
||||||
["nov"] = "NORMAL",
|
|
||||||
["noV"] = "NORMAL",
|
|
||||||
["niI"] = "NORMAL",
|
|
||||||
["niR"] = "NORMAL",
|
|
||||||
["niV"] = "NORMAL",
|
|
||||||
["i"] = "INSERT",
|
|
||||||
["ic"] = "INSERT",
|
|
||||||
["ix"] = "INSERT",
|
|
||||||
["s"] = "INSERT",
|
|
||||||
["S"] = "INSERT",
|
|
||||||
["v"] = "VISUAL",
|
|
||||||
["V"] = "VISUAL",
|
|
||||||
[""] = "VISUAL",
|
|
||||||
["r"] = "REPLACE",
|
|
||||||
["r?"] = "REPLACE",
|
|
||||||
["R"] = "REPLACE",
|
|
||||||
["c"] = "COMMAND",
|
|
||||||
["t"] = "TERMINAL",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
'';
|
|
||||||
}
|
|
@ -1,178 +0,0 @@
|
|||||||
{
|
|
||||||
plugins.telescope = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
extensions = {
|
|
||||||
fzf-native = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
ui-select = {
|
|
||||||
settings = {
|
|
||||||
specific_opts = {
|
|
||||||
codeactions = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
undo = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
# If you'd prefer Telescope not to enter a normal-like mode when hitting escape (and instead exiting), you can map <Esc> to do so via:
|
|
||||||
settings = {
|
|
||||||
defaults = {
|
|
||||||
mappings = {
|
|
||||||
i = {
|
|
||||||
"<esc>" = {
|
|
||||||
__raw = ''
|
|
||||||
function(...)
|
|
||||||
return require("telescope.actions").close(...)
|
|
||||||
end'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
keymaps = {
|
|
||||||
"<leader><space>" = {
|
|
||||||
action = "find_files";
|
|
||||||
options.desc = "Find project files";
|
|
||||||
};
|
|
||||||
"<leader>/" = {
|
|
||||||
action = "live_grep";
|
|
||||||
options.desc = "Grep (root dir)";
|
|
||||||
};
|
|
||||||
"<leader>:" = {
|
|
||||||
action = "command_history";
|
|
||||||
options.desc = "Command History";
|
|
||||||
};
|
|
||||||
"<leader>b" = {
|
|
||||||
action = "buffers";
|
|
||||||
options.desc = "+buffer";
|
|
||||||
};
|
|
||||||
"<leader>ff" = {
|
|
||||||
action = "find_files";
|
|
||||||
options.desc = "Find project files";
|
|
||||||
};
|
|
||||||
"<leader>fr" = {
|
|
||||||
action = "oldfiles";
|
|
||||||
options.desc = "Recent";
|
|
||||||
};
|
|
||||||
"<leader>fb" = {
|
|
||||||
action = "buffers";
|
|
||||||
options.desc = "Buffers";
|
|
||||||
};
|
|
||||||
"<C-p>" = {
|
|
||||||
action = "git_files";
|
|
||||||
options.desc = "Search git files";
|
|
||||||
};
|
|
||||||
"<leader>gc" = {
|
|
||||||
action = "git_commits";
|
|
||||||
options.desc = "Commits";
|
|
||||||
};
|
|
||||||
"<leader>gs" = {
|
|
||||||
action = "git_status";
|
|
||||||
options.desc = "Status";
|
|
||||||
};
|
|
||||||
"<leader>sa" = {
|
|
||||||
action = "autocommands";
|
|
||||||
options.desc = "Auto Commands";
|
|
||||||
};
|
|
||||||
"<leader>sb" = {
|
|
||||||
action = "current_buffer_fuzzy_find";
|
|
||||||
options.desc = "Buffer";
|
|
||||||
};
|
|
||||||
"<leader>sc" = {
|
|
||||||
action = "command_history";
|
|
||||||
options.desc = "Command History";
|
|
||||||
};
|
|
||||||
"<leader>sC" = {
|
|
||||||
action = "commands";
|
|
||||||
options.desc = "Commands";
|
|
||||||
};
|
|
||||||
"<leader>sD" = {
|
|
||||||
action = "diagnostics";
|
|
||||||
options.desc = "Workspace diagnostics";
|
|
||||||
};
|
|
||||||
"<leader>sh" = {
|
|
||||||
action = "help_tags";
|
|
||||||
options.desc = "Help pages";
|
|
||||||
};
|
|
||||||
"<leader>sH" = {
|
|
||||||
action = "highlights";
|
|
||||||
options.desc = "Search Highlight Groups";
|
|
||||||
};
|
|
||||||
"<leader>sk" = {
|
|
||||||
action = "keymaps";
|
|
||||||
options.desc = "Keymaps";
|
|
||||||
};
|
|
||||||
"<leader>sM" = {
|
|
||||||
action = "man_pages";
|
|
||||||
options.desc = "Man pages";
|
|
||||||
};
|
|
||||||
"<leader>sm" = {
|
|
||||||
action = "marks";
|
|
||||||
options.desc = "Jump to Mark";
|
|
||||||
};
|
|
||||||
"<leader>so" = {
|
|
||||||
action = "vim_options";
|
|
||||||
options.desc = "Options";
|
|
||||||
};
|
|
||||||
"<leader>sR" = {
|
|
||||||
action = "resume";
|
|
||||||
options.desc = "Resume";
|
|
||||||
};
|
|
||||||
"<leader>uC" = {
|
|
||||||
action = "colorscheme";
|
|
||||||
options.desc = "Colorscheme preview";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
keymaps = [
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>fp";
|
|
||||||
action = "<cmd>Telescope projects<CR>";
|
|
||||||
options = {
|
|
||||||
desc = "Projects";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>sd";
|
|
||||||
action = "<cmd>Telescope diagnostics bufnr=0<cr>";
|
|
||||||
options = {
|
|
||||||
desc = "Document diagnostics";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
{
|
|
||||||
mode = "n";
|
|
||||||
key = "<leader>st";
|
|
||||||
action = "<cmd>TodoTelescope<cr>";
|
|
||||||
options = {
|
|
||||||
silent = true;
|
|
||||||
desc = "Todo (Telescope)";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
# {
|
|
||||||
# mode = "n";
|
|
||||||
# key = "<leader>,";
|
|
||||||
# action = "<cmd>Telescope buffers sort_mru=true sort_lastused=true<cr>";
|
|
||||||
# options = {
|
|
||||||
# desc = "Switch Buffer";
|
|
||||||
# };
|
|
||||||
# }
|
|
||||||
];
|
|
||||||
extraConfigLua = ''
|
|
||||||
local telescope = require('telescope')
|
|
||||||
telescope.setup{
|
|
||||||
pickers = {
|
|
||||||
colorscheme = {
|
|
||||||
enable_preview = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
}
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user