mirror of
https://github.com/nmasur/dotfiles
synced 2025-07-08 16:30:15 +00:00
Compare commits
11 Commits
eblume-mol
...
b4470727e5
Author | SHA1 | Date | |
---|---|---|---|
b4470727e5 | |||
126baae735 | |||
892dfbbee4 | |||
0198469b83 | |||
c89ca7ea94 | |||
0a98b72784 | |||
c7de16b14c | |||
1d405e1828 | |||
97f99a149e | |||
bc794f89bc | |||
63b90102f2 |
52
flake.lock
generated
52
flake.lock
generated
@ -304,55 +304,72 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"markview-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1719592662,
|
||||
"narHash": "sha256-E1lHSjbnOOIeieaFJ+INvxJHCbfVS3mwbQ6wrlKeGSQ=",
|
||||
"owner": "OXY2DEV",
|
||||
"repo": "markview.nvim",
|
||||
"rev": "f60219dce7283192d549f21847fcf8537bf6d260",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "OXY2DEV",
|
||||
"repo": "markview.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nextcloud-cookbook": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1702545935,
|
||||
"narHash": "sha256-19LN1nYJJ0RMWj6DrYPvHzocTyhMfYdpdhBFch3fpHE=",
|
||||
"lastModified": 1719431638,
|
||||
"narHash": "sha256-a8ekMnEzudHGiqHF53jPtgsVTOTc2QLuPg6YtTw5h68=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.0/cookbook-0.11.0.tar.gz"
|
||||
"url": "https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.1/cookbook-0.11.1.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.0/cookbook-0.11.0.tar.gz"
|
||||
"url": "https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.1/cookbook-0.11.1.tar.gz"
|
||||
}
|
||||
},
|
||||
"nextcloud-external": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1699624334,
|
||||
"narHash": "sha256-RCL2RP5twRDLxI/KfAX6QLYQOzqZmSWsfrC5ZQIwTD4=",
|
||||
"lastModified": 1710338675,
|
||||
"narHash": "sha256-bJJ/dVmE1o04QCyrxD0sko0okRsnxJmT6sOTOmBiifs=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/nextcloud-releases/external/releases/download/v5.3.1/external-v5.3.1.tar.gz"
|
||||
"url": "https://github.com/nextcloud-releases/external/releases/download/v5.4.0/external-v5.4.0.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/nextcloud-releases/external/releases/download/v5.3.1/external-v5.3.1.tar.gz"
|
||||
"url": "https://github.com/nextcloud-releases/external/releases/download/v5.4.0/external-v5.4.0.tar.gz"
|
||||
}
|
||||
},
|
||||
"nextcloud-news": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1703426420,
|
||||
"narHash": "sha256-AENBJH/bEob5JQvw4WEi864mdLYJ5Mqe78HJH6ceCpI=",
|
||||
"lastModified": 1718102703,
|
||||
"narHash": "sha256-XNGjf7SWgJYFdVNOh3ED0jxSG0GJwWImVQq4cJT1Lo4=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/nextcloud/news/releases/download/25.0.0-alpha3/news.tar.gz"
|
||||
"url": "https://github.com/nextcloud/news/releases/download/25.0.0-alpha7/news.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/nextcloud/news/releases/download/25.0.0-alpha3/news.tar.gz"
|
||||
"url": "https://github.com/nextcloud/news/releases/download/25.0.0-alpha7/news.tar.gz"
|
||||
}
|
||||
},
|
||||
"nextcloud-snappymail": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"narHash": "sha256-7oJEJ6t6iS/pcnSHashf1AkOEf+gKizpQHBy9XwY4Yo=",
|
||||
"type": "file",
|
||||
"url": "https://github.com/nmasur/snappymail-nextcloud/releases/download/v2.36.1/snappymail-2.36.1-nextcloud.tar.gz"
|
||||
"lastModified": 1719799046,
|
||||
"narHash": "sha256-1bPStkTKgVCc/puq0G7EiEZy/xrNlNXaO/tiOaZ/Ovw=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/nmasur/snappymail-nextcloud/releases/download/v2.36.3/snappymail-2.36.3-nextcloud.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "file",
|
||||
"url": "https://github.com/nmasur/snappymail-nextcloud/releases/download/v2.36.1/snappymail-2.36.1-nextcloud.tar.gz"
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/nmasur/snappymail-nextcloud/releases/download/v2.36.3/snappymail-2.36.3-nextcloud.tar.gz"
|
||||
}
|
||||
},
|
||||
"nix2vim": {
|
||||
@ -570,6 +587,7 @@
|
||||
"hmts-nvim-src": "hmts-nvim-src",
|
||||
"home-manager": "home-manager",
|
||||
"mac-app-util": "mac-app-util",
|
||||
"markview-nvim-src": "markview-nvim-src",
|
||||
"nextcloud-cookbook": "nextcloud-cookbook",
|
||||
"nextcloud-external": "nextcloud-external",
|
||||
"nextcloud-news": "nextcloud-news",
|
||||
|
13
flake.nix
13
flake.nix
@ -127,6 +127,10 @@
|
||||
url = "github:mfussenegger/nvim-lint";
|
||||
flake = false;
|
||||
};
|
||||
markview-nvim-src = {
|
||||
url = "github:OXY2DEV/markview.nvim";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
# Tree-Sitter Grammars
|
||||
tree-sitter-bash = {
|
||||
@ -177,23 +181,24 @@
|
||||
# Nextcloud Apps
|
||||
nextcloud-news = {
|
||||
# https://github.com/nextcloud/news/releases
|
||||
url = "https://github.com/nextcloud/news/releases/download/25.0.0-alpha3/news.tar.gz";
|
||||
url = "https://github.com/nextcloud/news/releases/download/25.0.0-alpha7/news.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
nextcloud-external = {
|
||||
# https://github.com/nextcloud-releases/external/releases
|
||||
url = "https://github.com/nextcloud-releases/external/releases/download/v5.3.1/external-v5.3.1.tar.gz";
|
||||
url = "https://github.com/nextcloud-releases/external/releases/download/v5.4.0/external-v5.4.0.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
nextcloud-cookbook = {
|
||||
# https://github.com/christianlupus-nextcloud/cookbook-releases/releases/
|
||||
url = "https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.0/cookbook-0.11.0.tar.gz";
|
||||
url = "https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.1/cookbook-0.11.1.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
nextcloud-snappymail = {
|
||||
# https://github.com/the-djmaze/snappymail/releases
|
||||
# https://snappymail.eu/repository/nextcloud
|
||||
url = "file+https://github.com/nmasur/snappymail-nextcloud/releases/download/v2.36.1/snappymail-2.36.1-nextcloud.tar.gz";
|
||||
# url = "https://snappymail.eu/repository/nextcloud/snappymail-2.36.3-nextcloud.tar.gz";
|
||||
url = "https://github.com/nmasur/snappymail-nextcloud/releases/download/v2.36.3/snappymail-2.36.3-nextcloud.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
|
@ -34,7 +34,6 @@ inputs.darwin.lib.darwinSystem {
|
||||
dark = true;
|
||||
};
|
||||
mail.user = globals.user;
|
||||
mole.enable = true;
|
||||
atuin.enable = true;
|
||||
charm.enable = true;
|
||||
neovim.enable = true;
|
||||
|
@ -8,7 +8,6 @@
|
||||
./firefox.nix
|
||||
./kitty.nix
|
||||
./media.nix
|
||||
./mole.nix
|
||||
./obsidian.nix
|
||||
./qbittorrent.nix
|
||||
./slack.nix
|
||||
|
@ -34,10 +34,13 @@
|
||||
programs.rofi.terminal = lib.mkIf pkgs.stdenv.isLinux (lib.mkDefault "${pkgs.kitty}/bin/kitty");
|
||||
|
||||
# Display images in the terminal
|
||||
programs.fish.shellAliases = {
|
||||
icat = "kitty +kitten icat";
|
||||
ssh = "kitty +kitten ssh";
|
||||
};
|
||||
programs.fish.interactiveShellInit = # fish
|
||||
''
|
||||
if test "$TERM" = "xterm-kitty"
|
||||
alias icat="kitty +kitten icat"
|
||||
alias ssh="kitty +kitten ssh"
|
||||
end
|
||||
'';
|
||||
|
||||
programs.kitty = {
|
||||
enable = true;
|
||||
|
@ -1,110 +0,0 @@
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
|
||||
# Build kdl-py
|
||||
kdl-py = pkgs.python311.pkgs.buildPythonPackage rec {
|
||||
pname = "kdl-py";
|
||||
version = "1.2.0";
|
||||
pyproject = true;
|
||||
src = pkgs.fetchPypi {
|
||||
inherit pname version;
|
||||
hash = "sha256-Y/P0bGJ33trc5E3PyUZyv25r8zMLkBIuATTCKFfimXM=";
|
||||
};
|
||||
build-system = [ pkgs.python311.pkgs.setuptools ];
|
||||
# has no tests
|
||||
doCheck = false;
|
||||
};
|
||||
|
||||
mole = pkgs.python311.pkgs.buildPythonPackage rec {
|
||||
pname = "mole";
|
||||
version = "0.7.1";
|
||||
pyproject = true;
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "eblume";
|
||||
repo = pname;
|
||||
rev = "30bb052a97050b1fa89c287855d834f7952b195a";
|
||||
sha256 = "sha256-DUWsfyICCfFQ2ZQBYSQVoA3eLdKC8djUylKgGdHIyJo=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(builtins.toString (
|
||||
pkgs.writeText "pyproject.toml.patch" ''
|
||||
diff --git a/pyproject.toml b/pyproject.toml
|
||||
index 12ce0f5..787e978 100644
|
||||
--- a/pyproject.toml
|
||||
+++ b/pyproject.toml
|
||||
@@ -12,11 +12,11 @@ packages = [
|
||||
[tool.poetry.dependencies]
|
||||
python = "^3.11"
|
||||
# Now back to the regular dependencies
|
||||
-typer = {extras = ["all"], version = "^0.9"}
|
||||
+typer = {extras = ["all"], version = "^0.12"}
|
||||
todoist-api-python = "^2.1.3"
|
||||
openai = "^1.2.4"
|
||||
rich = "^13.4.2"
|
||||
-watchdog = "^3.0.0"
|
||||
+watchdog = "^4.0.0"
|
||||
pydub = "^0.25.1"
|
||||
requests = "^2.31.0"
|
||||
pyyaml = "^6.0.1"
|
||||
''
|
||||
))
|
||||
];
|
||||
|
||||
# Used during build time
|
||||
nativeBuildInputs = [ pkgs.python311Packages.poetry-core ];
|
||||
|
||||
# Used during run time
|
||||
buildInputs = [
|
||||
pkgs._1password
|
||||
pkgs.nb-cli
|
||||
];
|
||||
|
||||
# Both build and run time
|
||||
propagatedBuildInputs = [
|
||||
pkgs.python311Packages.typer
|
||||
pkgs.python311Packages.todoist-api-python
|
||||
pkgs.python311Packages.openai
|
||||
pkgs.python311Packages.rich
|
||||
pkgs.python311Packages.watchdog
|
||||
pkgs.python311Packages.pydub
|
||||
pkgs.python311Packages.requests
|
||||
pkgs.python311Packages.pyyaml
|
||||
pkgs.python311Packages.pydantic
|
||||
pkgs.python311Packages.pendulum
|
||||
kdl-py
|
||||
pkgs.ffmpeg
|
||||
];
|
||||
|
||||
build-system = [ pkgs.python311.pkgs.setuptools ];
|
||||
|
||||
# has no tests
|
||||
doCheck = false;
|
||||
|
||||
};
|
||||
|
||||
in
|
||||
{
|
||||
|
||||
options = {
|
||||
mole = {
|
||||
enable = lib.mkEnableOption {
|
||||
description = "Enable Mole.";
|
||||
default = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.mole.enable {
|
||||
home-manager.users.${config.user} = {
|
||||
home.packages = [ mole ];
|
||||
};
|
||||
};
|
||||
}
|
@ -10,7 +10,7 @@
|
||||
pkgs.vimPlugins.vim-eunuch # File manipulation commands
|
||||
pkgs.vimPlugins.vim-fugitive # Git commands
|
||||
pkgs.vimPlugins.vim-repeat # Better repeat using .
|
||||
pkgs.vimPlugins.glow-nvim # Markdown preview popup
|
||||
pkgs.vimPlugins.markview-nvim # Markdown preview
|
||||
pkgs.vimPlugins.nvim-colorizer-lua # Hex color previews
|
||||
pkgs.vimPlugins.which-key-nvim # Keybind helper
|
||||
];
|
||||
@ -21,7 +21,7 @@
|
||||
names = false;
|
||||
};
|
||||
};
|
||||
setup.glow = { };
|
||||
setup.markview = { };
|
||||
setup.which-key = { };
|
||||
|
||||
vim.o = {
|
||||
|
@ -14,11 +14,6 @@
|
||||
open_mapping = dsl.rawLua "[[<c-\\>]]";
|
||||
hide_numbers = true;
|
||||
direction = "float";
|
||||
float_opts = {
|
||||
width = dsl.rawLua "vim.o.columns - 4";
|
||||
height = dsl.rawLua "vim.o.lines - 4";
|
||||
row = 0;
|
||||
};
|
||||
};
|
||||
|
||||
lua = ''
|
||||
|
@ -71,8 +71,8 @@ key("n", "co", ":copen<CR>")
|
||||
key("n", "cq", ":cclose<CR>")
|
||||
|
||||
-- Other
|
||||
key("n", "<A-CR>", ":noh<CR>", { silent = true }) --- Clear search in VimWiki
|
||||
key("n", "Y", "y$") --- Copy to end of line
|
||||
key("n", "<A-CR>", ":noh<CR>", { silent = true }) --- Clear search in VimWiki
|
||||
key("n", "Y", "y$") --- Copy to end of line
|
||||
key("v", "<C-r>", "y<Esc>:%s/<C-r>+//gc<left><left><left>") --- Substitute selected
|
||||
key("v", "D", "y'>gp") --- Duplicate selected
|
||||
key("x", "<Leader>p", '"_dP') --- Paste but keep register
|
||||
key("v", "D", "y'>gp") --- Duplicate selected
|
||||
key("x", "<Leader>p", '"_dP') --- Paste but keep register
|
||||
|
@ -885,6 +885,28 @@ in
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
matcher = {
|
||||
id = "byName";
|
||||
options = "localhost:8086";
|
||||
};
|
||||
properties = [
|
||||
{
|
||||
id = "displayName";
|
||||
value = "InfluxDB";
|
||||
}
|
||||
{
|
||||
id = "links";
|
||||
value = [
|
||||
{
|
||||
targetBlank = true;
|
||||
title = "";
|
||||
url = "https://${config.hostnames.influxdb}";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
matcher = {
|
||||
id = "byName";
|
||||
@ -929,6 +951,28 @@ in
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
matcher = {
|
||||
id = "byName";
|
||||
options = "localhost:9000";
|
||||
};
|
||||
properties = [
|
||||
{
|
||||
id = "displayName";
|
||||
value = "The Lounge";
|
||||
}
|
||||
{
|
||||
id = "links";
|
||||
value = [
|
||||
{
|
||||
targetBlank = true;
|
||||
title = "";
|
||||
url = "https://${config.hostnames.irc}";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
matcher = {
|
||||
id = "byName";
|
||||
@ -2321,7 +2365,7 @@ in
|
||||
datasourceUid = promUid;
|
||||
model = {
|
||||
editorMode = "code";
|
||||
expr = ''systemd_unit_state{name=~"cloudflared-tunnel-.*", state="active"}'';
|
||||
expr = ''systemd_unit_state{name=~"cloudflared-tunnel-.*", state="active", job!="tempest"}'';
|
||||
hide = false;
|
||||
instant = true;
|
||||
intervalMs = 1000;
|
||||
@ -2418,7 +2462,7 @@ in
|
||||
execErrState = "Error";
|
||||
for = "5m";
|
||||
annotations = {
|
||||
description = "Cloudflare Tunnel for {{ $job }}.";
|
||||
description = "Cloudflare Tunnel for {{ index $labels \"job\" }}.";
|
||||
summary = "Cloudflare Tunnel is down.";
|
||||
};
|
||||
isPaused = false;
|
||||
|
@ -26,6 +26,8 @@
|
||||
trusted_domains = [ config.hostnames.content ];
|
||||
trusted_proxies = [ "127.0.0.1" ];
|
||||
maintenance_window_start = 4; # Run jobs at 4am UTC
|
||||
log_type = "file";
|
||||
loglevel = 1; # Include all actions in the log
|
||||
};
|
||||
extraAppsEnable = true;
|
||||
extraApps = {
|
||||
|
@ -38,6 +38,10 @@ in
|
||||
|
||||
config = {
|
||||
|
||||
services.victoriametrics.extraOptions = [
|
||||
"-promscrape.config=${(pkgs.formats.yaml { }).generate "scrape.yml" prometheusConfig}"
|
||||
];
|
||||
|
||||
systemd.services.vmauth = lib.mkIf config.services.victoriametrics.enable {
|
||||
description = "VictoriaMetrics basic auth proxy";
|
||||
after = [ "network.target" ];
|
||||
|
@ -38,5 +38,6 @@ in
|
||||
base16-nvim = plugin "base16-nvim" inputs.base16-nvim-src;
|
||||
baleia-nvim = plugin "baleia-nvim" inputs.baleia-nvim-src;
|
||||
hmts-nvim = plugin "hmts-nvim" inputs.hmts-nvim-src;
|
||||
markview-nvim = plugin "markview-nvim" inputs.markview-nvim-src;
|
||||
};
|
||||
}
|
||||
|
Reference in New Issue
Block a user