mirror of
https://github.com/nmasur/dotfiles
synced 2025-07-06 22:30:13 +00:00
Compare commits
2 Commits
e7bbf68dde
...
keyd-2.4.3
Author | SHA1 | Date | |
---|---|---|---|
1c9bd21ced | |||
14d2cbfdfb |
11
.github/workflows/update.yml
vendored
11
.github/workflows/update.yml
vendored
@ -8,7 +8,6 @@ on:
|
||||
permissions:
|
||||
contents: write
|
||||
pull-requests: write
|
||||
checks: write
|
||||
|
||||
jobs:
|
||||
lockfile:
|
||||
@ -32,17 +31,7 @@ jobs:
|
||||
dependencies
|
||||
automated
|
||||
- name: Check the Flake
|
||||
id: check
|
||||
run: nix flake check
|
||||
- name: Update Check Status
|
||||
uses: LouisBrunner/checks-action@v1.6.1
|
||||
if: always()
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
name: Update Flake
|
||||
conclusion: ${{ job.status }}
|
||||
output: |
|
||||
{"summary":"${{ steps.check.outputs.stdout }}"}
|
||||
- name: Enable Pull Request Automerge
|
||||
if: success()
|
||||
run: |
|
||||
|
24
README.md
24
README.md
@ -41,30 +41,6 @@ configuration may be difficult to translate to a non-Nix system.
|
||||
| --- | --- | --- |
|
||||
| Keybinds | [Hammerspoon](https://www.hammerspoon.org/) | [Link](./modules/darwin/hammerspoon) |
|
||||
|
||||
# Diagram
|
||||
|
||||

|
||||
|
||||
- [flake.nix](./flake.nix)
|
||||
- [hosts](./hosts/)
|
||||
- [modules](./modules/)
|
||||
|
||||
---
|
||||
|
||||
# Unique Configurations
|
||||
|
||||
This repo contains a few more elaborate elements of configuration.
|
||||
|
||||
- [Neovim config](./modules/common/neovim/default.nix) generated with Nix2Vim
|
||||
and source-controlled plugins, differing based on installed LSPs, for example.
|
||||
- [Caddy JSON](./modules/nixos/services/caddy.nix) file (routes, etc.) based
|
||||
dynamically on enabled services rendered with Nix.
|
||||
- [Grafana config](./modules/nixos/services/grafana.nix) rendered with Nix.
|
||||
- Custom [secrets deployment](./modules/nixos/services/secrets.nix) similar to
|
||||
agenix.
|
||||
- Base16 [colorschemes](./colorscheme/) applied to multiple applications,
|
||||
including Firefox userChrome.
|
||||
|
||||
---
|
||||
|
||||
# Installation
|
||||
|
249
flake.lock
generated
249
flake.lock
generated
@ -37,11 +37,11 @@
|
||||
"baleia-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1704551058,
|
||||
"narHash": "sha256-0NmiGzMFvL1awYOVtiaSd+O4sAR524x68xwWLgArlqs=",
|
||||
"lastModified": 1681806450,
|
||||
"narHash": "sha256-jxRlIzWbnSj89032msc5w+2TVt7zVyzlxdXxiH1dQqY=",
|
||||
"owner": "m00qek",
|
||||
"repo": "baleia.nvim",
|
||||
"rev": "6d9cbdaca3a428bc7296f838fdfce3ad01ee7495",
|
||||
"rev": "00bb4af31c8c3865b735d40ebefa6c3f07b2dd16",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -53,44 +53,28 @@
|
||||
"bufferline-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1695205521,
|
||||
"narHash": "sha256-MQMpXMgUpZA0E9TunzjXeOQxDWSCTogXbvi9VJnv4Kw=",
|
||||
"lastModified": 1687763763,
|
||||
"narHash": "sha256-wbOeylzjjScQXkrDbBU2HtrOZrp2YUK+wQ2aOkgxmRQ=",
|
||||
"owner": "akinsho",
|
||||
"repo": "bufferline.nvim",
|
||||
"rev": "6ecd37e0fa8b156099daedd2191130e083fb1490",
|
||||
"rev": "bf2f6b7edd0abf6b0732f5e5c0a8f30e51611c75",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "akinsho",
|
||||
"ref": "v4.4.0",
|
||||
"ref": "v4.2.0",
|
||||
"repo": "bufferline.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"bypass-paywalls-clean": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1704880831,
|
||||
"narHash": "sha256-KXYpzI/xzn9mUc7FoCewssvBUkHBv2pQ7m/4krqHFHg=",
|
||||
"owner": "magnolia1234",
|
||||
"repo": "bpc-uploads",
|
||||
"rev": "fc34b6b8e2d79af62ef9cf8222daeb0eb4b785a4",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
"owner": "magnolia1234",
|
||||
"repo": "bpc-uploads",
|
||||
"type": "gitlab"
|
||||
}
|
||||
},
|
||||
"cmp-nvim-lsp-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1702205473,
|
||||
"narHash": "sha256-/0sh9vJBD9pUuD7q3tNSQ1YLvxFMNykdg5eG+LjZAA8=",
|
||||
"lastModified": 1687494203,
|
||||
"narHash": "sha256-mU0soCz79erJXMMqD/FyrJZ0mu2n6fE0deymPzQlxts=",
|
||||
"owner": "hrsh7th",
|
||||
"repo": "cmp-nvim-lsp",
|
||||
"rev": "5af77f54de1b16c34b23cba810150689a3a90312",
|
||||
"rev": "44b16d11215dce86f253ce0c30949813c0a90765",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -106,11 +90,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704277720,
|
||||
"narHash": "sha256-meAKNgmh3goankLGWqqpw73pm9IvXjEENJloF0coskE=",
|
||||
"lastModified": 1696043447,
|
||||
"narHash": "sha256-VbJ1dY5pVH2fX1bS+cT2+4+BYEk4lMHRP0+udu9G6tk=",
|
||||
"owner": "lnl7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "0dd382b70c351f528561f71a0a7df82c9d2be9a4",
|
||||
"rev": "792c2e01347cb1b2e7ec84a1ef73453ca86537d8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -127,11 +111,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705075138,
|
||||
"narHash": "sha256-0slYsXoR1Sd5FwTfFZLYxAsI015+J4lvgvo55u4Gw1A=",
|
||||
"lastModified": 1695864092,
|
||||
"narHash": "sha256-Hu1SkFPqO7ND95AOzBkZE2jGXSYhfZ965C03O72Kbu8=",
|
||||
"owner": "nix-community",
|
||||
"repo": "disko",
|
||||
"rev": "f78b6498f69e04514cb84393e5daba669198c1c1",
|
||||
"rev": "19b62324663b6b9859caf7f335d232cf4f1f6a32",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -140,23 +124,6 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"fidget-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1702031048,
|
||||
"narHash": "sha256-wbjQuOFd/2339TIrUA97PYsV8N3PZsS+xbyMsyZmki8=",
|
||||
"owner": "j-hui",
|
||||
"repo": "fidget.nvim",
|
||||
"rev": "300018af4abd00610a345e382ca1f4b7ba420f77",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "j-hui",
|
||||
"ref": "v1.1.0",
|
||||
"repo": "fidget.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"firefox-darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@ -164,11 +131,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705193299,
|
||||
"narHash": "sha256-Hapo/l2byyBlCviP+/DNO6xS7/79oqfPb6K9DL/ddD8=",
|
||||
"lastModified": 1696034364,
|
||||
"narHash": "sha256-7giewUYqKhhfhKRxe2EPHCpSM0oMLuByW4RTRZl6Jfc=",
|
||||
"owner": "bandithedoge",
|
||||
"repo": "nixpkgs-firefox-darwin",
|
||||
"rev": "0d1ff8fb805bfaecfd9a05f788fcd08ca8af38e8",
|
||||
"rev": "b1e4d451a15c34d45bfefb05137a20469399a2df",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -180,11 +147,11 @@
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696426674,
|
||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
||||
"lastModified": 1673956053,
|
||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -234,11 +201,11 @@
|
||||
"systems": "systems_3"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1701680307,
|
||||
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
|
||||
"lastModified": 1694529238,
|
||||
"narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
|
||||
"rev": "ff7b65b44d01cf9ba6a71320833626af21126384",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -270,11 +237,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705169127,
|
||||
"narHash": "sha256-j9OEtNxOIPWZWjbECVMkI1TO17SzlpHMm0LnVWKOR/g=",
|
||||
"lastModified": 1696063111,
|
||||
"narHash": "sha256-F2IJEbyH3xG0eqyAYn9JoV+niqNz+xb4HICYNkkviNI=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "f2942f3385f1b35cc8a1abb03a45e29c9cb4d3c8",
|
||||
"rev": "ae896c810f501bf0c3a2fd7fc2de094dd0addf01",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -287,40 +254,37 @@
|
||||
"nextcloud-cookbook": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1702545935,
|
||||
"narHash": "sha256-19LN1nYJJ0RMWj6DrYPvHzocTyhMfYdpdhBFch3fpHE=",
|
||||
"narHash": "sha256-XgBwUr26qW6wvqhrnhhhhcN4wkI+eXDHnNSm1HDbP6M=",
|
||||
"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/nextcloud/cookbook/releases/download/v0.10.2/Cookbook-0.10.2.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/nextcloud/cookbook/releases/download/v0.10.2/Cookbook-0.10.2.tar.gz"
|
||||
}
|
||||
},
|
||||
"nextcloud-external": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1699624334,
|
||||
"narHash": "sha256-RCL2RP5twRDLxI/KfAX6QLYQOzqZmSWsfrC5ZQIwTD4=",
|
||||
"narHash": "sha256-X7eC8T8wSZGVwCQp6U/WxjMC7aIj39osgHotaUoRNSQ=",
|
||||
"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.2.1/external-v5.2.1.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.2.1/external-v5.2.1.tar.gz"
|
||||
}
|
||||
},
|
||||
"nextcloud-news": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1703426420,
|
||||
"narHash": "sha256-AENBJH/bEob5JQvw4WEi864mdLYJ5Mqe78HJH6ceCpI=",
|
||||
"narHash": "sha256-cfJkKRNSz15L4E3w1tnEb+t4MrVwVzb8lb6vCOA4cK4=",
|
||||
"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/24.0.0/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/24.0.0/news.tar.gz"
|
||||
}
|
||||
},
|
||||
"nil": {
|
||||
@ -390,11 +354,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1701689616,
|
||||
"narHash": "sha256-ewnfgvRy73HoP5KnYmy1Rcr4m4yShvsb6TCCaKoW8pc=",
|
||||
"lastModified": 1696058303,
|
||||
"narHash": "sha256-eNqKWpF5zG0SrgbbtljFOrRgFgRzCc4++TMFADBMLnc=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixos-generators",
|
||||
"rev": "246219bc21b943c6f6812bb7744218ba0df08600",
|
||||
"rev": "150f38bd1e09e20987feacb1b0d5991357532fb5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -405,11 +369,11 @@
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1704722960,
|
||||
"narHash": "sha256-mKGJ3sPsT6//s+Knglai5YflJUF2DGj7Ai6Ynopz0kI=",
|
||||
"lastModified": 1695830400,
|
||||
"narHash": "sha256-gToZXQVr0G/1WriO83olnqrLSHF2Jb8BPcmCt497ro0=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "317484b1ead87b9c1b8ac5261a8d2dd748a0492d",
|
||||
"rev": "8a86b98f0ba1c405358f1b71ff8b5e1d317f5db2",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -419,6 +383,38 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-keyd": {
|
||||
"locked": {
|
||||
"lastModified": 1690363189,
|
||||
"narHash": "sha256-Zs0VkngOtQz7nIEO7Wi8AwGB4TBSex2KZAw784aOm2M=",
|
||||
"owner": "JohnAZoidberg",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "6591d332f93422e388ef6337f6b362b4ff8d0724",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "JohnAZoidberg",
|
||||
"ref": "keyd-2.4.3",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1695825837,
|
||||
"narHash": "sha256-4Ne11kNRnQsmSJCRSSNkFRSnHC4Y5gPDBIQGjjPfJiU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "5cfafa12d57374f48bcc36fda3274ada276cf69e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"null-ls-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
@ -437,11 +433,11 @@
|
||||
},
|
||||
"nur": {
|
||||
"locked": {
|
||||
"lastModified": 1705197850,
|
||||
"narHash": "sha256-WtgOcadsR2/4ArDfYLEezIo99JrvZ0uVpxNwH66dXmM=",
|
||||
"lastModified": 1696080597,
|
||||
"narHash": "sha256-fhf7+NT/xMwPZ/sRT30lnI04AHgf7tLPU4ClMux1nWA=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nur",
|
||||
"rev": "7a24ce86be38634afc3c82caccefc2059bdf935b",
|
||||
"rev": "8783c360abc69f58d46a2929534ddd91eb41f3c6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -470,11 +466,11 @@
|
||||
"nvim-tree-lua-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1705190895,
|
||||
"narHash": "sha256-BfB4q4nRBotjopq/35rI2jXrNub2uriZIPznMPGq2lc=",
|
||||
"lastModified": 1695716495,
|
||||
"narHash": "sha256-Fkchn7UuIHPmVFFrx1kzsE2lviJrAFAe9tHu73HnS/w=",
|
||||
"owner": "kyazdani42",
|
||||
"repo": "nvim-tree.lua",
|
||||
"rev": "f24afa2cef551122b8bd53bb2e4a7df42343ce2e",
|
||||
"rev": "934469b9b6df369e198fb3016969e56393b0dc07",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -486,11 +482,11 @@
|
||||
"nvim-treesitter-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1704630521,
|
||||
"narHash": "sha256-Xc5XqHy3Yk82BFZjeLRSoaN4U4v46FAclFcjoRHZ9no=",
|
||||
"lastModified": 1696061053,
|
||||
"narHash": "sha256-KR+VMYTVM2qsLPx412gySAKiGObhs+awbDJhWX72/wY=",
|
||||
"owner": "nvim-treesitter",
|
||||
"repo": "nvim-treesitter",
|
||||
"rev": "8cd2b230174efbf7b5d9f49fe2f90bda6b5eb16e",
|
||||
"rev": "dd4e2dbc002dfce109d621e8bdcd9d89438b0a32",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -503,14 +499,13 @@
|
||||
"proton-ge": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1700610476,
|
||||
"narHash": "sha256-IoClZ6hl2lsz9OGfFgnz7vEAGlSY2+1K2lDEEsJQOfU=",
|
||||
"narHash": "sha256-75A0VCVdYkiMQ1duE9r2+DLBJzV02vUozoVLeo/TIWQ=",
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-25/GE-Proton8-25.tar.gz"
|
||||
"url": "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-16/GE-Proton8-16.tar.gz"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-25/GE-Proton8-25.tar.gz"
|
||||
"url": "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-16/GE-Proton8-16.tar.gz"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
@ -519,11 +514,9 @@
|
||||
"age": "age",
|
||||
"baleia-nvim-src": "baleia-nvim-src",
|
||||
"bufferline-nvim-src": "bufferline-nvim-src",
|
||||
"bypass-paywalls-clean": "bypass-paywalls-clean",
|
||||
"cmp-nvim-lsp-src": "cmp-nvim-lsp-src",
|
||||
"darwin": "darwin",
|
||||
"disko": "disko",
|
||||
"fidget-nvim-src": "fidget-nvim-src",
|
||||
"firefox-darwin": "firefox-darwin",
|
||||
"hmts-nvim-src": "hmts-nvim-src",
|
||||
"home-manager": "home-manager",
|
||||
@ -534,6 +527,7 @@
|
||||
"nix2vim": "nix2vim",
|
||||
"nixos-generators": "nixos-generators",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs-keyd": "nixpkgs-keyd",
|
||||
"null-ls-nvim-src": "null-ls-nvim-src",
|
||||
"nur": "nur",
|
||||
"nvim-lspconfig-src": "nvim-lspconfig-src",
|
||||
@ -549,6 +543,7 @@
|
||||
"tree-sitter-puppet": "tree-sitter-puppet",
|
||||
"tree-sitter-python": "tree-sitter-python",
|
||||
"tree-sitter-rasi": "tree-sitter-rasi",
|
||||
"vscode-terraform-snippets": "vscode-terraform-snippets",
|
||||
"wallpapers": "wallpapers",
|
||||
"wsl": "wsl",
|
||||
"zenyd-mpv-scripts": "zenyd-mpv-scripts"
|
||||
@ -627,16 +622,16 @@
|
||||
"telescope-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1697004956,
|
||||
"narHash": "sha256-7SqYFnfCjotOBhuX6Wx1IOhgMKoxaoI1a4SKz1d5RVM=",
|
||||
"lastModified": 1686302912,
|
||||
"narHash": "sha256-fV3LLRwAPykVGc4ImOnUSP+WTrPp9Ad9OTfBJ6wqTMk=",
|
||||
"owner": "nvim-telescope",
|
||||
"repo": "telescope.nvim",
|
||||
"rev": "7011eaae0ac1afe036e30c95cf80200b8dc3f21a",
|
||||
"rev": "776b509f80dd49d8205b9b0d94485568236d1192",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nvim-telescope",
|
||||
"ref": "0.1.4",
|
||||
"ref": "0.1.2",
|
||||
"repo": "telescope.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
@ -644,11 +639,11 @@
|
||||
"telescope-project-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1701464478,
|
||||
"narHash": "sha256-touMCltcnqkrQYV1NtNeWLQeFVGt+WM3aIWIdKilA7w=",
|
||||
"lastModified": 1682606566,
|
||||
"narHash": "sha256-H6lrPjpOUVleKHB0ziI+6dthg9ymitHhEWtcgYJTrKo=",
|
||||
"owner": "nvim-telescope",
|
||||
"repo": "telescope-project.nvim",
|
||||
"rev": "1aaf16580a614601a7f7077d9639aeb457dc5559",
|
||||
"rev": "7c64b181dd4e72deddcf6f319e3bf1e95b2a2f30",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -660,16 +655,16 @@
|
||||
"toggleterm-nvim-src": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1695636777,
|
||||
"narHash": "sha256-o8xzoo7OuYrPnKlfrupQ24Ja9hZy1qQVnvwO0FO+4zM=",
|
||||
"lastModified": 1685434104,
|
||||
"narHash": "sha256-oiCnBrvft6XxiQtQH8E4F842xhh348SaTpHzaeb+iDY=",
|
||||
"owner": "akinsho",
|
||||
"repo": "toggleterm.nvim",
|
||||
"rev": "faee9d60428afc7857e0927fdc18daa6c409fa64",
|
||||
"rev": "95204ece0f2a54c89c4395295432f9aeedca7b5f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "akinsho",
|
||||
"ref": "v2.8.0",
|
||||
"ref": "v2.7.0",
|
||||
"repo": "toggleterm.nvim",
|
||||
"type": "github"
|
||||
}
|
||||
@ -677,11 +672,11 @@
|
||||
"tree-sitter-bash": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696959291,
|
||||
"narHash": "sha256-VP7rJfE/k8KV1XN1w5f0YKjCnDMYU1go/up0zj1mabM=",
|
||||
"lastModified": 1695263734,
|
||||
"narHash": "sha256-dJUJGrpBWBLjcqiqxCnJ/MENwa2+uxAmQD71aYloxsw=",
|
||||
"owner": "tree-sitter",
|
||||
"repo": "tree-sitter-bash",
|
||||
"rev": "7331995b19b8f8aba2d5e26deb51d2195c18bc94",
|
||||
"rev": "fd4e40dab883d6456da4d847de8321aee9c80805",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -694,11 +689,11 @@
|
||||
"tree-sitter-ini": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1699877527,
|
||||
"narHash": "sha256-dYPeVTNWO4apY5dsjsKViavU7YtLeGTp6BzEemXhsEU=",
|
||||
"lastModified": 1690815608,
|
||||
"narHash": "sha256-IIpKzpA4q1jpYVZ75VZaxWHaqNt8TA427eMOui2s71M=",
|
||||
"owner": "justinmk",
|
||||
"repo": "tree-sitter-ini",
|
||||
"rev": "bcb84a2d4bcd6f55b911c42deade75c8f90cb0c5",
|
||||
"rev": "7f11a02fb8891482068e0fe419965d7bade81a68",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -743,11 +738,11 @@
|
||||
"tree-sitter-python": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1700218345,
|
||||
"narHash": "sha256-hXNxa895SyNOG7PH2vAIkWbcMjZDjWYDsCafBZuvnT0=",
|
||||
"lastModified": 1695282953,
|
||||
"narHash": "sha256-gRhD3M1DkmwYQDDnyRq6QMTWUJUY0vbetGnN+pBTd84=",
|
||||
"owner": "tree-sitter",
|
||||
"repo": "tree-sitter-python",
|
||||
"rev": "4bfdd9033a2225cc95032ce77066b7aeca9e2efc",
|
||||
"rev": "a901729099257aac932d79c60adb5e8a53fa7e6c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@ -773,6 +768,22 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"vscode-terraform-snippets": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1614849738,
|
||||
"narHash": "sha256-v392tyzXV+zyBNt5OCB2NBCK7JcByrTa5Ne/nFtSCJI=",
|
||||
"owner": "run-at-scale",
|
||||
"repo": "vscode-terraform-doc-snippets",
|
||||
"rev": "6ab3e44b566e660f38922cf908e6e547eaa5d4b4",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "run-at-scale",
|
||||
"repo": "vscode-terraform-doc-snippets",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"wallpapers": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
@ -793,16 +804,14 @@
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-utils": "flake-utils_3",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
"nixpkgs": "nixpkgs_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705003621,
|
||||
"narHash": "sha256-bnQKeNbNYyKfmJN2/KD+t8gDKA0uU8Ak4/sV4gvlA2E=",
|
||||
"lastModified": 1696053802,
|
||||
"narHash": "sha256-8TTbJbtGDz1MstExrVQe56eXZpovvZv6G6L6q/4NOKg=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NixOS-WSL",
|
||||
"rev": "0fa9268bf9a903498cb567e6d4d01eb945f36f6e",
|
||||
"rev": "cadde47d123d1a534c272b04a7582f1d11474c48",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
50
flake.nix
50
flake.nix
@ -7,17 +7,18 @@
|
||||
# Used for system packages
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
|
||||
# Update to keyd 2.4.3 not yet in nixpkgs-unstable
|
||||
# https://github.com/NixOS/nixpkgs/pull/245327
|
||||
nixpkgs-keyd.url = "github:JohnAZoidberg/nixpkgs/keyd-2.4.3";
|
||||
|
||||
# Used for MacOS system config
|
||||
darwin = {
|
||||
url = "github:lnl7/nix-darwin/master";
|
||||
url = "github:/lnl7/nix-darwin/master";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
# Used for Windows Subsystem for Linux compatibility
|
||||
wsl = {
|
||||
url = "github:nix-community/NixOS-WSL";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
wsl.url = "github:nix-community/NixOS-WSL";
|
||||
|
||||
# Used for user packages and dotfiles
|
||||
home-manager = {
|
||||
@ -80,7 +81,6 @@
|
||||
flake = false;
|
||||
};
|
||||
baleia-nvim-src = {
|
||||
# https://github.com/m00qek/baleia.nvim/tags
|
||||
url = "github:m00qek/baleia.nvim";
|
||||
flake = false;
|
||||
};
|
||||
@ -94,7 +94,7 @@
|
||||
flake = false;
|
||||
};
|
||||
telescope-nvim-src = {
|
||||
url = "github:nvim-telescope/telescope.nvim/0.1.4";
|
||||
url = "github:nvim-telescope/telescope.nvim/0.1.2";
|
||||
flake = false;
|
||||
};
|
||||
telescope-project-nvim-src = {
|
||||
@ -102,24 +102,23 @@
|
||||
flake = false;
|
||||
};
|
||||
toggleterm-nvim-src = {
|
||||
url = "github:akinsho/toggleterm.nvim/v2.8.0";
|
||||
url = "github:akinsho/toggleterm.nvim/v2.7.0";
|
||||
flake = false;
|
||||
};
|
||||
bufferline-nvim-src = {
|
||||
url = "github:akinsho/bufferline.nvim/v4.4.0";
|
||||
url = "github:akinsho/bufferline.nvim/v4.2.0";
|
||||
flake = false;
|
||||
};
|
||||
nvim-tree-lua-src = {
|
||||
url = "github:kyazdani42/nvim-tree.lua";
|
||||
flake = false;
|
||||
};
|
||||
hmts-nvim-src = {
|
||||
url = "github:calops/hmts.nvim";
|
||||
vscode-terraform-snippets = {
|
||||
url = "github:run-at-scale/vscode-terraform-doc-snippets";
|
||||
flake = false;
|
||||
};
|
||||
fidget-nvim-src = {
|
||||
# https://github.com/j-hui/fidget.nvim/tags
|
||||
url = "github:j-hui/fidget.nvim/v1.1.0";
|
||||
hmts-nvim-src = {
|
||||
url = "github:calops/hmts.nvim";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
@ -166,14 +165,7 @@
|
||||
proton-ge = {
|
||||
# https://github.com/GloriousEggroll/proton-ge-custom/releases
|
||||
url =
|
||||
"https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-25/GE-Proton8-25.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
# Firefox addon from outside the extension store
|
||||
bypass-paywalls-clean = {
|
||||
# https://gitlab.com/magnolia1234/bpc-uploads/-/commits/master/?ref_type=HEADS
|
||||
url = "gitlab:magnolia1234/bpc-uploads";
|
||||
"https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-16/GE-Proton8-16.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
@ -181,19 +173,19 @@
|
||||
nextcloud-news = {
|
||||
# https://github.com/nextcloud/news/releases
|
||||
url =
|
||||
"https://github.com/nextcloud/news/releases/download/25.0.0-alpha3/news.tar.gz";
|
||||
"https://github.com/nextcloud/news/releases/download/24.0.0/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";
|
||||
"https://github.com/nextcloud-releases/external/releases/download/v5.2.1/external-v5.2.1.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
nextcloud-cookbook = {
|
||||
# https://github.com/christianlupus-nextcloud/cookbook-releases/releases/
|
||||
# https://github.com/nextcloud/cookbook/releases
|
||||
url =
|
||||
"https://github.com/christianlupus-nextcloud/cookbook-releases/releases/download/v0.11.0/cookbook-0.11.0.tar.gz";
|
||||
"https://github.com/nextcloud/cookbook/releases/download/v0.10.2/Cookbook-0.10.2.tar.gz";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
@ -216,10 +208,8 @@
|
||||
dotfilesRepo = "https://github.com/nmasur/dotfiles";
|
||||
hostnames = {
|
||||
git = "git.${baseName}";
|
||||
influxdb = "influxdb.${baseName}";
|
||||
metrics = "metrics.${baseName}";
|
||||
prometheus = "prom.${baseName}";
|
||||
paperless = "paper.${baseName}";
|
||||
secrets = "vault.${baseName}";
|
||||
stream = "stream.${baseName}";
|
||||
content = "cloud.${baseName}";
|
||||
@ -242,9 +232,7 @@
|
||||
(import ./overlays/betterlockscreen.nix)
|
||||
(import ./overlays/age.nix inputs)
|
||||
(import ./overlays/proton-ge.nix inputs)
|
||||
(import ./overlays/gh-collaborators.nix)
|
||||
(import ./overlays/bypass-paywalls-clean.nix inputs)
|
||||
(import ./overlays/terraform.nix)
|
||||
(import ./overlays/keyd.nix inputs)
|
||||
];
|
||||
|
||||
# System types to support.
|
||||
|
@ -12,15 +12,3 @@ These are the individual machines managed by this flake.
|
||||
| [swan](./swan/default.nix) | Home server |
|
||||
| [tempest](./tempest/default.nix) | Linux desktop |
|
||||
|
||||
## NixOS Workflow
|
||||
|
||||
Each hosts file is imported into [nixosConfigurations](../flake.nix) and passed
|
||||
the arguments from the flake (inputs, globals, overlays). The `nixosSystem`
|
||||
function in that hosts file will be called by the NixOS module system during a
|
||||
nixos-rebuild.
|
||||
|
||||
Each module in the each host's `modules` list is either a function or an
|
||||
attrset. The attrsets will simply apply values to options that have been
|
||||
declared in the config by other modules. Meanwhile, the functions will be
|
||||
passed various arguments, several of which you will see listed at the top of
|
||||
each of their files.
|
||||
|
@ -26,7 +26,7 @@ data "aws_iam_policy_document" "vmimport" {
|
||||
actions = [
|
||||
"s3:GetBucketLocation",
|
||||
"s3:GetObject",
|
||||
"s3:ListBucket",
|
||||
"s3:ListBucket",
|
||||
]
|
||||
resources = [
|
||||
"arn:aws:s3:::${aws_s3_object.image.bucket}",
|
||||
|
@ -1,8 +1,6 @@
|
||||
# The Flame
|
||||
# System configuration for an Oracle free server
|
||||
|
||||
# See [readme](../README.md) to explain how this file works.
|
||||
|
||||
# How to install:
|
||||
# https://blog.korfuri.fr/posts/2022/08/nixos-on-an-oracle-free-tier-ampere-machine/
|
||||
# These days, probably use nixos-anywhere instead.
|
||||
@ -60,7 +58,6 @@ inputs.nixpkgs.lib.nixosSystem {
|
||||
services.grafana.enable = true;
|
||||
services.openssh.enable = true;
|
||||
services.victoriametrics.enable = true;
|
||||
services.influxdb2.enable = true;
|
||||
services.gitea.enable = true;
|
||||
services.vaultwarden.enable = true;
|
||||
services.minecraft-server.enable = true; # Setup Minecraft server
|
||||
|
@ -1,8 +1,6 @@
|
||||
# The Hydra
|
||||
# System configuration for WSL
|
||||
|
||||
# See [readme](../README.md) to explain how this file works.
|
||||
|
||||
{ inputs, globals, overlays, ... }:
|
||||
|
||||
inputs.nixpkgs.lib.nixosSystem {
|
||||
|
@ -37,7 +37,6 @@ inputs.darwin.lib.darwinSystem {
|
||||
nixlang.enable = true;
|
||||
terraform.enable = true;
|
||||
python.enable = true;
|
||||
rust.enable = true;
|
||||
lua.enable = true;
|
||||
kubernetes.enable = true;
|
||||
_1password.enable = true;
|
||||
|
@ -1,8 +1,6 @@
|
||||
# The Swan
|
||||
# System configuration for my home NAS server
|
||||
|
||||
# See [readme](../README.md) to explain how this file works.
|
||||
|
||||
{ inputs, globals, overlays, ... }:
|
||||
|
||||
inputs.nixpkgs.lib.nixosSystem {
|
||||
@ -81,8 +79,6 @@ inputs.nixpkgs.lib.nixosSystem {
|
||||
services.prometheus.enable = false;
|
||||
services.vmagent.enable = true;
|
||||
services.samba.enable = true;
|
||||
services.paperless.enable = true;
|
||||
services.postgresql.enable = true;
|
||||
|
||||
# Allows private remote access over the internet
|
||||
cloudflareTunnel = {
|
||||
|
@ -1,8 +1,6 @@
|
||||
# The Tempest
|
||||
# System configuration for my desktop
|
||||
|
||||
# See [readme](../README.md) to explain how this file works.
|
||||
|
||||
{ inputs, globals, overlays, ... }:
|
||||
|
||||
inputs.nixpkgs.lib.nixosSystem {
|
||||
@ -101,7 +99,6 @@ inputs.nixpkgs.lib.nixosSystem {
|
||||
keybase.enable = true;
|
||||
mullvad.enable = false;
|
||||
nixlang.enable = true;
|
||||
rust.enable = true;
|
||||
yt-dlp.enable = true;
|
||||
gaming = {
|
||||
dwarf-fortress.enable = true;
|
||||
|
@ -30,21 +30,20 @@
|
||||
name = "default";
|
||||
isDefault = true;
|
||||
extensions = with pkgs.nur.repos.rycee.firefox-addons; [
|
||||
(lib.mkIf config._1password.enable onepassword-password-manager)
|
||||
pkgs.bypass-paywalls-clean
|
||||
darkreader
|
||||
don-t-fuck-with-paste
|
||||
facebook-container
|
||||
markdownload
|
||||
ublock-origin
|
||||
vimium
|
||||
multi-account-containers
|
||||
facebook-container
|
||||
(lib.mkIf config._1password.enable onepassword-password-manager)
|
||||
okta-browser-plugin
|
||||
sponsorblock
|
||||
reddit-enhancement-suite
|
||||
return-youtube-dislikes
|
||||
markdownload
|
||||
darkreader
|
||||
snowflake
|
||||
sponsorblock
|
||||
ublock-origin
|
||||
ublacklist
|
||||
vimium
|
||||
don-t-fuck-with-paste
|
||||
i-dont-care-about-cookies
|
||||
wappalyzer
|
||||
];
|
||||
settings = {
|
||||
@ -75,8 +74,6 @@
|
||||
"media.ffmpeg.vaapi.enabled" =
|
||||
true; # Enable hardware video acceleration
|
||||
"cookiebanners.ui.desktop.enabled" = true; # Reject cookie popups
|
||||
"devtools.command-button-screenshot.enabled" =
|
||||
true; # Scrolling screenshot of entire page
|
||||
"svg.context-properties.content.enabled" = true; # Sidebery styling
|
||||
};
|
||||
userChrome = ''
|
||||
@ -118,7 +115,7 @@
|
||||
background-color: ${config.theme.colors.base00};
|
||||
color: ${config.theme.colors.base06} !important;
|
||||
}
|
||||
.tab-content[selected] {
|
||||
.tab-content[selected=true] {
|
||||
border-bottom: 2px solid color-mix(in srgb, var(--identity-tab-color) 25%, transparent);
|
||||
background-color: ${config.theme.colors.base01} !important;
|
||||
color: ${config.theme.colors.base07} !important;
|
||||
|
@ -15,9 +15,8 @@
|
||||
home.packages = with pkgs; [ obsidian ];
|
||||
};
|
||||
|
||||
# Broken on 2023-12-11
|
||||
# https://forum.obsidian.md/t/electron-25-is-now-eol-please-upgrade-to-a-newer-version/72878/8
|
||||
nixpkgs.config.permittedInsecurePackages = [ "electron-25.9.0" ];
|
||||
# Broken on 2023-04-16
|
||||
nixpkgs.config.permittedInsecurePackages = [ "electron-21.4.0" ];
|
||||
|
||||
};
|
||||
|
||||
|
@ -75,18 +75,10 @@
|
||||
type = lib.types.str;
|
||||
description = "Hostname for metrics server.";
|
||||
};
|
||||
paperless = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Hostname for document server (paperless-ngx).";
|
||||
};
|
||||
prometheus = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Hostname for Prometheus server.";
|
||||
};
|
||||
influxdb = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Hostname for InfluxDB2 server.";
|
||||
};
|
||||
secrets = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
description = "Hostname for passwords and secrets (Vaultwarden).";
|
||||
|
@ -68,7 +68,7 @@
|
||||
"!" = ":term<space>";
|
||||
"|" = ":pipe<space>";
|
||||
|
||||
"/" = ":search<space>-a<space>";
|
||||
"/" = ":search<space>";
|
||||
"\\" = ":filter <space>";
|
||||
n = ":next-result<Enter>";
|
||||
N = ":prev-result<Enter>";
|
||||
|
@ -9,6 +9,7 @@
|
||||
pkgs.vimPlugins.luasnip
|
||||
pkgs.vimPlugins.cmp_luasnip
|
||||
pkgs.vimPlugins.cmp-rg
|
||||
pkgs.vimPlugins.friendly-snippets
|
||||
];
|
||||
|
||||
use.cmp.setup = dsl.callWith {
|
||||
@ -23,6 +24,13 @@
|
||||
end
|
||||
'';
|
||||
|
||||
# Enable Luasnip snippet completion
|
||||
snippet.expand = dsl.rawLua ''
|
||||
function(args)
|
||||
require("luasnip").lsp_expand(args.body)
|
||||
end
|
||||
'';
|
||||
|
||||
# Basic completion keybinds
|
||||
mapping = {
|
||||
"['<C-n>']" = dsl.rawLua
|
||||
@ -62,6 +70,7 @@
|
||||
sources = [
|
||||
{ name = "nvim_lua"; } # Fills in common Neovim lua functions
|
||||
{ name = "nvim_lsp"; } # LSP results
|
||||
{ name = "luasnip"; } # Snippets
|
||||
{ name = "path"; } # Shell completion from current PATH
|
||||
{
|
||||
name = "buffer"; # Grep for text from the current text buffer
|
||||
@ -110,6 +119,7 @@
|
||||
}
|
||||
vim_item.kind = string.format("%s", kind_icons[vim_item.kind])
|
||||
vim_item.menu = ({
|
||||
luasnip = "[Snippet]",
|
||||
buffer = "[Buffer]",
|
||||
path = "[Path]",
|
||||
rg = "[Grep]",
|
||||
@ -129,6 +139,13 @@
|
||||
};
|
||||
|
||||
lua = ''
|
||||
-- Load snippets
|
||||
-- Check status: :lua require("luasnip").log.open()
|
||||
require("luasnip.loaders.from_vscode").lazy_load()
|
||||
require("luasnip.loaders.from_vscode").lazy_load({ paths = { "${
|
||||
builtins.toString pkgs.vscode-terraform-snippets
|
||||
}" } })
|
||||
|
||||
-- Use buffer source for `/`
|
||||
require('cmp').setup.cmdline("/", {
|
||||
sources = {
|
||||
|
@ -1,14 +0,0 @@
|
||||
-- Keymap to open file in GitHub web
|
||||
vim.keymap.set("n", "<Leader>gr", ":!gh browse %<CR><CR>", { silent = true })
|
||||
|
||||
-- Pop a terminal to watch the current run
|
||||
local gitwatch =
|
||||
require("toggleterm.terminal").Terminal:new({ cmd = "fish --interactive --init-command 'gh run watch'" })
|
||||
|
||||
-- Set a toggle for this terminal
|
||||
function GITWATCH_TOGGLE()
|
||||
gitwatch:toggle()
|
||||
end
|
||||
|
||||
-- Keymap to toggle the run
|
||||
vim.keymap.set("n", "<Leader>gw", GITWATCH_TOGGLE)
|
@ -1,6 +0,0 @@
|
||||
local k9s = require("toggleterm.terminal").Terminal:new({ cmd = "k9s" })
|
||||
function K9S_TOGGLE()
|
||||
k9s:toggle()
|
||||
end
|
||||
|
||||
vim.keymap.set("n", "<Leader>9", K9S_TOGGLE)
|
@ -1,110 +1,76 @@
|
||||
{ pkgs, lib, config, dsl, ... }: {
|
||||
{ pkgs, dsl, ... }: {
|
||||
|
||||
# Terraform optional because non-free
|
||||
options.terraform = lib.mkEnableOption "Whether to enable Terraform LSP";
|
||||
options.github = lib.mkEnableOption "Whether to enable GitHub features";
|
||||
options.kubernetes =
|
||||
lib.mkEnableOption "Whether to enable Kubernetes features";
|
||||
plugins = [
|
||||
pkgs.vimPlugins.nvim-lspconfig
|
||||
pkgs.vimPlugins.lsp-colors-nvim
|
||||
pkgs.vimPlugins.null-ls-nvim
|
||||
];
|
||||
|
||||
config =
|
||||
use.lspconfig.lua_ls.setup = dsl.callWith {
|
||||
settings = { Lua = { diagnostics = { globals = [ "vim" "hs" ]; }; }; };
|
||||
capabilities = dsl.rawLua "require('cmp_nvim_lsp').default_capabilities()";
|
||||
cmd = [ "${pkgs.lua-language-server}/bin/lua-language-server" ];
|
||||
};
|
||||
|
||||
let
|
||||
use.lspconfig.nil_ls.setup = dsl.callWith {
|
||||
cmd = [ "${pkgs.nil}/bin/nil" ];
|
||||
capabilities = dsl.rawLua "require('cmp_nvim_lsp').default_capabilities()";
|
||||
};
|
||||
|
||||
terraformFormat = if config.terraform then ''
|
||||
require("null-ls").builtins.formatting.terraform_fmt.with({
|
||||
command = "${pkgs.terraform}/bin/terraform",
|
||||
extra_filetypes = { "hcl" },
|
||||
}),
|
||||
'' else
|
||||
"";
|
||||
use.lspconfig.pyright.setup = dsl.callWith {
|
||||
cmd = [ "${pkgs.pyright}/bin/pyright-langserver" "--stdio" ];
|
||||
};
|
||||
|
||||
in {
|
||||
plugins = [
|
||||
pkgs.vimPlugins.nvim-lspconfig
|
||||
pkgs.vimPlugins.null-ls-nvim
|
||||
pkgs.vimPlugins.fidget-nvim
|
||||
];
|
||||
use.lspconfig.terraformls.setup =
|
||||
dsl.callWith { cmd = [ "${pkgs.terraform-ls}/bin/terraform-ls" "serve" ]; };
|
||||
|
||||
setup.fidget = { };
|
||||
vim.api.nvim_create_augroup = dsl.callWith [ "LspFormatting" { } ];
|
||||
|
||||
use.lspconfig.lua_ls.setup = dsl.callWith {
|
||||
settings = { Lua = { diagnostics = { globals = [ "vim" "hs" ]; }; }; };
|
||||
capabilities =
|
||||
dsl.rawLua "require('cmp_nvim_lsp').default_capabilities()";
|
||||
cmd = [ "${pkgs.lua-language-server}/bin/lua-language-server" ];
|
||||
};
|
||||
lua = ''
|
||||
${builtins.readFile ./lsp.lua}
|
||||
|
||||
use.lspconfig.nil_ls.setup = dsl.callWith {
|
||||
cmd = [ "${pkgs.nil}/bin/nil" ];
|
||||
capabilities =
|
||||
dsl.rawLua "require('cmp_nvim_lsp').default_capabilities()";
|
||||
};
|
||||
-- Prevent infinite log size (change this when debugging)
|
||||
vim.lsp.set_log_level("off")
|
||||
|
||||
use.lspconfig.pyright.setup = dsl.callWith {
|
||||
cmd = [ "${pkgs.pyright}/bin/pyright-langserver" "--stdio" ];
|
||||
};
|
||||
require("null-ls").setup({
|
||||
sources = {
|
||||
require("null-ls").builtins.formatting.stylua.with({ command = "${pkgs.stylua}/bin/stylua" }),
|
||||
require("null-ls").builtins.formatting.black.with({ command = "${pkgs.black}/bin/black" }),
|
||||
require("null-ls").builtins.diagnostics.ruff.with({ command = "${pkgs.ruff}/bin/ruff" }),
|
||||
require("null-ls").builtins.formatting.fish_indent.with({ command = "${pkgs.fish}/bin/fish_indent" }),
|
||||
require("null-ls").builtins.formatting.nixfmt.with({ command = "${pkgs.nixfmt}/bin/nixfmt" }),
|
||||
require("null-ls").builtins.formatting.rustfmt.with({ command = "${pkgs.rustfmt}/bin/rustfmt" }),
|
||||
require("null-ls").builtins.diagnostics.shellcheck.with({ command = "${pkgs.shellcheck}/bin/shellcheck" }),
|
||||
require("null-ls").builtins.formatting.shfmt.with({
|
||||
command = "${pkgs.shfmt}/bin/shfmt",
|
||||
extra_args = { "-i", "4", "-ci" },
|
||||
}),
|
||||
require("null-ls").builtins.formatting.terraform_fmt.with({
|
||||
command = "${pkgs.terraform}/bin/terraform",
|
||||
extra_filetypes = { "hcl" },
|
||||
}),
|
||||
},
|
||||
|
||||
use.lspconfig.terraformls.setup = dsl.callWith {
|
||||
cmd = if config.terraform then [
|
||||
"${pkgs.terraform-ls}/bin/terraform-ls"
|
||||
"serve"
|
||||
] else
|
||||
[ "echo" ];
|
||||
};
|
||||
|
||||
use.lspconfig.rust_analyzer.setup = dsl.callWith {
|
||||
cmd = [ "${pkgs.rust-analyzer}/bin/rust-analyzer" ];
|
||||
settings = {
|
||||
"['rust-analyzer']" = { check = { command = "clippy"; }; };
|
||||
};
|
||||
};
|
||||
|
||||
vim.api.nvim_create_augroup = dsl.callWith [ "LspFormatting" { } ];
|
||||
|
||||
lua = ''
|
||||
${builtins.readFile ./lsp.lua}
|
||||
|
||||
-- Prevent infinite log size (change this when debugging)
|
||||
vim.lsp.set_log_level("off")
|
||||
|
||||
require("null-ls").setup({
|
||||
sources = {
|
||||
require("null-ls").builtins.formatting.stylua.with({ command = "${pkgs.stylua}/bin/stylua" }),
|
||||
require("null-ls").builtins.formatting.black.with({ command = "${pkgs.black}/bin/black" }),
|
||||
require("null-ls").builtins.diagnostics.ruff.with({ command = "${pkgs.ruff}/bin/ruff" }),
|
||||
require("null-ls").builtins.formatting.fish_indent.with({ command = "${pkgs.fish}/bin/fish_indent" }),
|
||||
require("null-ls").builtins.formatting.nixfmt.with({ command = "${pkgs.nixfmt}/bin/nixfmt" }),
|
||||
require("null-ls").builtins.formatting.rustfmt.with({ command = "${pkgs.rustfmt}/bin/rustfmt" }),
|
||||
require("null-ls").builtins.diagnostics.shellcheck.with({ command = "${pkgs.shellcheck}/bin/shellcheck" }),
|
||||
require("null-ls").builtins.formatting.shfmt.with({
|
||||
command = "${pkgs.shfmt}/bin/shfmt",
|
||||
extra_args = { "-i", "4", "-ci" },
|
||||
}),
|
||||
${terraformFormat}
|
||||
},
|
||||
|
||||
on_attach = function(client, bufnr)
|
||||
if client.supports_method("textDocument/formatting") then
|
||||
-- Auto-format on save
|
||||
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,
|
||||
})
|
||||
-- Use internal formatting for bindings like gq.
|
||||
vim.api.nvim_create_autocmd("LspAttach", {
|
||||
callback = function(args)
|
||||
vim.bo[args.buf].formatexpr = nil
|
||||
end,
|
||||
})
|
||||
end
|
||||
end,
|
||||
})
|
||||
'';
|
||||
|
||||
};
|
||||
on_attach = function(client, bufnr)
|
||||
if client.supports_method("textDocument/formatting") then
|
||||
-- Auto-format on save
|
||||
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,
|
||||
})
|
||||
-- Use internal formatting for bindings like gq.
|
||||
vim.api.nvim_create_autocmd("LspAttach", {
|
||||
callback = function(args)
|
||||
vim.bo[args.buf].formatexpr = nil
|
||||
end,
|
||||
})
|
||||
end
|
||||
end,
|
||||
})
|
||||
'';
|
||||
|
||||
}
|
||||
|
@ -12,7 +12,7 @@
|
||||
|
||||
# Initialize some plugins
|
||||
setup.Comment = { };
|
||||
setup.colorizer = { user_default_options = { names = false; }; };
|
||||
setup.colorizer = { };
|
||||
setup.glow = { };
|
||||
setup.which-key = { };
|
||||
|
||||
@ -69,6 +69,10 @@
|
||||
" Remember last position when reopening file
|
||||
au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$") | exe "normal! g`\"" | endif
|
||||
|
||||
" LaTeX options
|
||||
au FileType tex inoremap ;bf \textbf{}<Esc>i
|
||||
au BufWritePost *.tex silent! execute "!pdflatex -output-directory=%:p:h % >/dev/null 2>&1" | redraw!
|
||||
|
||||
" Flash highlight when yanking
|
||||
au TextYankPost * silent! lua vim.highlight.on_yank { timeout = 250 }
|
||||
'';
|
||||
|
@ -4,7 +4,6 @@
|
||||
(pkgs.vimPlugins.nvim-treesitter.withPlugins (_plugins:
|
||||
with pkgs.tree-sitter-grammars; [
|
||||
tree-sitter-bash
|
||||
# tree-sitter-c
|
||||
tree-sitter-fish
|
||||
tree-sitter-hcl
|
||||
tree-sitter-ini
|
||||
@ -25,7 +24,7 @@
|
||||
pkgs.vimPlugins.vim-helm
|
||||
pkgs.baleia-nvim # Clean ANSI from kitty scrollback
|
||||
# pkgs.hmts-nvim # Tree-sitter injections for home-manager
|
||||
(pkgs.vimUtils.buildVimPlugin {
|
||||
(pkgs.vimUtils.buildVimPluginFrom2Nix {
|
||||
pname = "nmasur";
|
||||
version = "0.1";
|
||||
src = ../plugin;
|
||||
|
@ -26,5 +26,17 @@ function NIXPKGS_TOGGLE()
|
||||
nixpkgs:toggle()
|
||||
end
|
||||
|
||||
local gitwatch = terminal:new({ cmd = "fish --interactive --init-command 'gh run watch'" })
|
||||
function GITWATCH_TOGGLE()
|
||||
gitwatch:toggle()
|
||||
end
|
||||
|
||||
local k9s = terminal:new({ cmd = "k9s" })
|
||||
function K9S_TOGGLE()
|
||||
k9s:toggle()
|
||||
end
|
||||
|
||||
vim.keymap.set("n", "<Leader>t", TERM_TOGGLE)
|
||||
vim.keymap.set("n", "<Leader>P", NIXPKGS_TOGGLE)
|
||||
vim.keymap.set("n", "<Leader>gw", GITWATCH_TOGGLE)
|
||||
vim.keymap.set("n", "<Leader>9", K9S_TOGGLE)
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ pkgs, dsl, config, ... }: {
|
||||
{ pkgs, dsl, ... }: {
|
||||
|
||||
# Toggleterm provides a floating terminal inside the editor for quick access
|
||||
|
||||
@ -10,10 +10,6 @@
|
||||
direction = "float";
|
||||
};
|
||||
|
||||
lua = ''
|
||||
${builtins.readFile ./toggleterm.lua}
|
||||
${if config.github then (builtins.readFile ./github.lua) else ""}
|
||||
${if config.kubernetes then (builtins.readFile ./kubernetes.lua) else ""}
|
||||
'';
|
||||
lua = builtins.readFile ./toggleterm.lua;
|
||||
|
||||
}
|
||||
|
@ -63,6 +63,7 @@
|
||||
'';
|
||||
view = { # Set look and feel
|
||||
width = 30;
|
||||
hide_root_folder = false;
|
||||
side = "left";
|
||||
number = false;
|
||||
relativenumber = false;
|
||||
|
@ -5,9 +5,6 @@ let
|
||||
neovim = import ./package {
|
||||
inherit pkgs;
|
||||
colors = config.theme.colors;
|
||||
terraform = config.terraform.enable;
|
||||
github = true;
|
||||
kubernetes = config.kubernetes.enable;
|
||||
};
|
||||
|
||||
in {
|
||||
|
@ -39,6 +39,7 @@ key("n", "<Leader>fs", ":write<CR>")
|
||||
key("n", "<Leader>fd", ":lcd %:p:h<CR>", { silent = true })
|
||||
key("n", "<Leader>fu", ":lcd ..<CR>", { silent = true })
|
||||
key("n", "<Leader><Tab>", ":b#<CR>", { silent = true })
|
||||
key("n", "<Leader>gr", ":!gh browse %<CR><CR>", { silent = true })
|
||||
key("n", "<Leader>tt", [[<Cmd>exe 'edit $NOTES_PATH/journal/'.strftime("%Y-%m-%d_%a").'.md'<CR>]])
|
||||
key("n", "<Leader>jj", ":!journal<CR>:e<CR>")
|
||||
|
||||
|
@ -26,13 +26,13 @@
|
||||
# ] ++ extraConfig;
|
||||
# }
|
||||
|
||||
{ pkgs, colors, terraform ? false, github ? false, kubernetes ? false, ... }:
|
||||
{ pkgs, colors, ... }:
|
||||
|
||||
# Comes from nix2vim overlay:
|
||||
# https://github.com/gytis-ivaskevicius/nix2vim/blob/master/lib/neovim-builder.nix
|
||||
pkgs.neovimBuilder {
|
||||
package = pkgs.neovim-unwrapped;
|
||||
inherit colors terraform github kubernetes;
|
||||
inherit colors;
|
||||
imports = [
|
||||
../config/align.nix
|
||||
../config/bufferline.nix
|
||||
|
@ -6,7 +6,6 @@
|
||||
./lua.nix
|
||||
./nix.nix
|
||||
./python.nix
|
||||
./rust.nix
|
||||
./terraform.nix
|
||||
];
|
||||
|
||||
|
@ -1,17 +0,0 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.rust.enable = lib.mkEnableOption "Rust programming language.";
|
||||
|
||||
config = lib.mkIf config.rust.enable {
|
||||
|
||||
home-manager.users.${config.user} = {
|
||||
|
||||
programs.fish.shellAbbrs = { ca = "cargo"; };
|
||||
|
||||
home.packages = with pkgs; [ cargo rustc clippy gcc ];
|
||||
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
}
|
@ -3,7 +3,6 @@
|
||||
options.terraform.enable = lib.mkEnableOption "Terraform tools.";
|
||||
|
||||
config = lib.mkIf config.terraform.enable {
|
||||
unfreePackages = [ "terraform" ];
|
||||
|
||||
home-manager.users.${config.user} = {
|
||||
programs.fish.shellAbbrs = {
|
||||
|
@ -7,22 +7,6 @@
|
||||
config = { whitelist = { prefix = [ config.dotfilesPath ]; }; };
|
||||
};
|
||||
|
||||
# programs.direnv.direnvrcExtra = ''
|
||||
# layout_postgres() {
|
||||
# export PGDATA="$(direnv_layout_dir)/postgres"
|
||||
# export PGHOST="$PGDATA"
|
||||
#
|
||||
# if [[ ! -d "PGDATA" ]]; then
|
||||
# initdb
|
||||
# cat >> "$PGDATA/postgres.conf" <<- EOF
|
||||
# listen_addresses = '''
|
||||
# unix_socket_directories = '$PGHOST'
|
||||
# EOF
|
||||
# echo "CREATE DATABASE $USER;" | postgres --single -E postgres
|
||||
# fi
|
||||
# }
|
||||
# '';
|
||||
|
||||
# Prevent garbage collection
|
||||
nix.extraOptions = ''
|
||||
keep-outputs = true
|
||||
|
@ -123,6 +123,9 @@
|
||||
dr = "docker run --rm -it";
|
||||
db = "docker build . -t";
|
||||
|
||||
# Rust
|
||||
ca = "cargo";
|
||||
|
||||
};
|
||||
shellInit = "";
|
||||
};
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ config, pkgs, ... }: {
|
||||
{ config, ... }: {
|
||||
|
||||
# FZF is a fuzzy-finder for the terminal
|
||||
|
||||
@ -16,9 +16,10 @@
|
||||
--search-path $HOME/dev \
|
||||
--type directory \
|
||||
--exact-depth 2 \
|
||||
| ${pkgs.proximity-sort}/bin/proximity-sort . \
|
||||
| sed 's/\\/$//' \
|
||||
| fzf --tiebreak=index \
|
||||
| fzf \
|
||||
--delimiter '/' \
|
||||
--with-nth 6.. \
|
||||
)
|
||||
and cd $projdir
|
||||
and commandline -f execute
|
||||
|
@ -58,7 +58,6 @@ in {
|
||||
git switch (git symbolic-ref refs/remotes/origin/HEAD | cut -d"/" -f4)'';
|
||||
gcob = "git switch -c";
|
||||
gb = "git branch";
|
||||
gpd = "git push origin -d";
|
||||
gbd = "git branch -d";
|
||||
gbD = "git branch -D";
|
||||
gr = "git reset";
|
||||
|
@ -7,7 +7,6 @@
|
||||
enable = true;
|
||||
gitCredentialHelper.enable = true;
|
||||
settings.git_protocol = "https";
|
||||
extensions = [ pkgs.gh-collaborators ];
|
||||
};
|
||||
|
||||
programs.fish =
|
||||
@ -15,7 +14,7 @@
|
||||
shellAbbrs = {
|
||||
ghr = "gh repo view -w";
|
||||
gha =
|
||||
"gh run list | head -1 | awk '{ print \\$\\(NF-2\\) }' | xargs gh run view";
|
||||
"gh run list | head -1 | awk '{ print $(NF-2) }' | xargs gh run view";
|
||||
grw = "gh run watch";
|
||||
grf = "gh run view --log-failed";
|
||||
grl = "gh run view --log";
|
||||
|
@ -25,8 +25,6 @@ in {
|
||||
htop # Show system processes
|
||||
killall # Force quit
|
||||
inetutils # Includes telnet, whois
|
||||
jless # JSON viewer
|
||||
jo # JSON output
|
||||
jq # JSON manipulation
|
||||
lf # File viewer
|
||||
qrencode # Generate qr codes
|
||||
@ -46,11 +44,10 @@ in {
|
||||
|
||||
home.file = {
|
||||
".rgignore".text = ignorePatterns;
|
||||
".fdignore".text = ignorePatterns;
|
||||
".digrc".text = "+noall +answer"; # Cleaner dig commands
|
||||
};
|
||||
|
||||
xdg.configFile."fd/ignore".text = ignorePatterns;
|
||||
|
||||
programs.bat = {
|
||||
enable = true; # cat replacement
|
||||
config = {
|
||||
|
@ -54,19 +54,14 @@ function obj:init()
|
||||
end)
|
||||
|
||||
-- Launcher shortcuts
|
||||
self.launcher:bind("ctrl", "space", function() end)
|
||||
self.launcher:bind("ctrl", "space", function()
|
||||
end)
|
||||
self.launcher:bind("", "return", function()
|
||||
self:switch("@kitty@")
|
||||
end)
|
||||
self.launcher:bind("", "C", function()
|
||||
self:switch("Calendar.app")
|
||||
end)
|
||||
self.launcher:bind("shift", "D", function()
|
||||
hs.execute("launchctl remove com.paloaltonetworks.gp.pangps")
|
||||
hs.execute("launchctl remove com.paloaltonetworks.gp.pangpa")
|
||||
hs.alert.show("Disconnected from GlobalProtect", nil, nil, 4)
|
||||
self.launcher:exit()
|
||||
end)
|
||||
self.launcher:bind("", "E", function()
|
||||
self:switch("Mail.app")
|
||||
end)
|
||||
@ -85,12 +80,6 @@ function obj:init()
|
||||
self.launcher:bind("", "P", function()
|
||||
self:switch("System Preferences.app")
|
||||
end)
|
||||
self.launcher:bind("shift", "P", function()
|
||||
hs.execute("launchctl load /Library/LaunchAgents/com.paloaltonetworks.gp.pangps.plist")
|
||||
hs.execute("launchctl load /Library/LaunchAgents/com.paloaltonetworks.gp.pangpa.plist")
|
||||
hs.alert.show("Reconnecting to GlobalProtect", nil, nil, 4)
|
||||
self.launcher:exit()
|
||||
end)
|
||||
self.launcher:bind("", "R", function()
|
||||
hs.console.clearConsole()
|
||||
hs.reload()
|
||||
|
@ -38,7 +38,6 @@
|
||||
"gitify" # Git notifications in menu bar
|
||||
"keybase" # GUI on Nix not available for macOS
|
||||
"logitech-g-hub" # Mouse and keyboard management
|
||||
"logitune" # Logitech webcam firmware
|
||||
"meetingbar" # Show meetings in menu bar
|
||||
"obsidian" # Obsidian packaging on Nix is not available for macOS
|
||||
"scroll-reverser" # Different scroll style for mouse vs. trackpad
|
||||
|
@ -10,7 +10,11 @@
|
||||
};
|
||||
|
||||
# Used for aerc
|
||||
home-manager.users.${config.user}.xdg.enable = true;
|
||||
home-manager.users.${config.user} = {
|
||||
home.sessionVariables = {
|
||||
XDG_CONFIG_HOME = "${config.homePath}/.config";
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
|
@ -2,8 +2,6 @@
|
||||
|
||||
{
|
||||
|
||||
unfreePackages = [ "consul" "vault-bin" ];
|
||||
|
||||
home-manager.users.${config.user} = lib.mkIf pkgs.stdenv.isDarwin {
|
||||
|
||||
home.packages = with pkgs; [
|
||||
@ -13,12 +11,11 @@
|
||||
youtube-dl # Convert web videos
|
||||
pandoc # Convert text documents
|
||||
mpd # TUI slideshows
|
||||
mpv # Video player
|
||||
awscli2
|
||||
awslogs
|
||||
google-cloud-sdk
|
||||
ansible
|
||||
vault-bin
|
||||
vault
|
||||
consul
|
||||
noti # Create notifications programmatically
|
||||
ipcalc # Make IP network calculations
|
||||
|
@ -95,15 +95,13 @@ in {
|
||||
|
||||
# Adjust screen brightness
|
||||
"Shift+F12" =
|
||||
# Disable dynamic sleep
|
||||
# https://github.com/rockowitz/ddcutil/issues/323
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 + 30";
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 + 30";
|
||||
"Shift+F11" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 - 30";
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 - 30";
|
||||
"XF86MonBrightnessUp" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 + 30";
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 + 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 + 30";
|
||||
"XF86MonBrightnessDown" =
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 - 30";
|
||||
"exec ${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 - 30 && sleep 1; exec ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 - 30";
|
||||
|
||||
# Media player controls
|
||||
"XF86AudioPlay" = "exec ${pkgs.playerctl}/bin/playerctl play-pause";
|
||||
|
@ -36,7 +36,7 @@
|
||||
module-margin = 1;
|
||||
modules-left = "i3";
|
||||
modules-center = "xwindow";
|
||||
modules-right = "mailcount network pulseaudio date keyboard power";
|
||||
modules-right = "mailcount network pulseaudio date power";
|
||||
cursor-click = "pointer";
|
||||
cursor-scroll = "ns-resize";
|
||||
enable-ipc = true;
|
||||
@ -200,17 +200,10 @@
|
||||
label-foreground = config.theme.colors.base0A;
|
||||
# format-background = colors.background;
|
||||
};
|
||||
"module/keyboard" = {
|
||||
type = "custom/text";
|
||||
content = "";
|
||||
click-left = "doas systemctl restart keyd";
|
||||
content-foreground = config.theme.colors.base04;
|
||||
};
|
||||
"module/power" = {
|
||||
type = "custom/text";
|
||||
content = " ";
|
||||
click-left = config.powerCommand;
|
||||
click-right = "polybar-msg cmd restart";
|
||||
content-foreground = config.theme.colors.base04;
|
||||
};
|
||||
"settings" = {
|
||||
|
@ -28,18 +28,17 @@ in {
|
||||
-sep ';' \
|
||||
-selected-row 1)
|
||||
|
||||
|
||||
case "$chosen" in
|
||||
"$dimmer")
|
||||
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 25; ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 25
|
||||
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 25; ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 25
|
||||
;;
|
||||
|
||||
"$medium")
|
||||
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 75; ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 75
|
||||
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 75; ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 75
|
||||
;;
|
||||
|
||||
"$brighter")
|
||||
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 100; ${pkgs.ddcutil}/bin/ddcutil --disable-dynamic-sleep --display 2 setvcp 10 100
|
||||
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 100; ${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 100
|
||||
;;
|
||||
|
||||
*) exit 1 ;;
|
||||
|
@ -31,17 +31,15 @@ in {
|
||||
-sep ';' \
|
||||
-selected-row 2)
|
||||
|
||||
confirm () {
|
||||
${builtins.readFile ./rofi-prompt.sh}
|
||||
}
|
||||
|
||||
case "$chosen" in
|
||||
"$power_off")
|
||||
confirm 'Shutdown?' && doas shutdown now
|
||||
${
|
||||
builtins.toString ./rofi-prompt.sh
|
||||
} 'Shutdown?' && doas shutdown now
|
||||
;;
|
||||
|
||||
"$reboot")
|
||||
confirm 'Reboot?' && doas reboot
|
||||
${builtins.toString ./rofi-prompt.sh} 'Reboot?' && doas reboot
|
||||
;;
|
||||
|
||||
"$lock")
|
||||
@ -53,7 +51,7 @@ in {
|
||||
;;
|
||||
|
||||
"$log_out")
|
||||
confirm 'Logout?' && i3-msg exit
|
||||
${builtins.toString ./rofi-prompt.sh} 'Logout?' && i3-msg exit
|
||||
;;
|
||||
|
||||
*) exit 1 ;;
|
||||
|
@ -42,6 +42,6 @@ chosen=$(printf '%s;%s\n' "$yes" "$no" |
|
||||
-selected-row 1)
|
||||
|
||||
case "$chosen" in
|
||||
"$yes") return 0 ;;
|
||||
*) return 1 ;;
|
||||
"$yes") exit 0 ;;
|
||||
*) exit 1 ;;
|
||||
esac
|
||||
|
@ -18,7 +18,14 @@
|
||||
keyboards = {
|
||||
default = {
|
||||
ids = [ "*" ];
|
||||
settings = { main = { capslock = "overload(control, esc)"; }; };
|
||||
settings = {
|
||||
main = { capslock = "overload(control, esc)"; };
|
||||
|
||||
# Fix: ctrl-click sends escape afterwards
|
||||
# Suppresses escape if held for more than 500ms
|
||||
# https://github.com/rvaiya/keyd/issues/424
|
||||
global = { overload_tap_timeout = 500; };
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -12,7 +12,7 @@
|
||||
domainName = "local";
|
||||
ipv6 = false; # Should work either way
|
||||
# Resolve local hostnames using Avahi DNS
|
||||
nssmdns4 = true;
|
||||
nssmdns = true;
|
||||
publish = {
|
||||
enable = true;
|
||||
addresses = true;
|
||||
|
@ -2,7 +2,6 @@
|
||||
|
||||
let
|
||||
|
||||
# This config specifies ports for Prometheus to scrape information
|
||||
arrConfig = {
|
||||
radarr = {
|
||||
exportarrPort = "9707";
|
||||
@ -42,8 +41,6 @@ in {
|
||||
sabnzbd = {
|
||||
enable = true;
|
||||
group = "media";
|
||||
# The config file must be editable within the application
|
||||
# It contains server configs and credentials
|
||||
configFile = "/data/downloads/sabnzbd/sabnzbd.ini";
|
||||
};
|
||||
sonarr = {
|
||||
@ -56,23 +53,16 @@ in {
|
||||
};
|
||||
};
|
||||
|
||||
# Create a media group to be shared between services
|
||||
users.groups.media = { };
|
||||
|
||||
# Give the human user access to the media group
|
||||
users.users.${config.user}.extraGroups = [ "media" ];
|
||||
|
||||
# Allows media group to read/write the sabnzbd directory
|
||||
users.users.sabnzbd.homeMode = "0770";
|
||||
|
||||
unfreePackages = [ "unrar" ]; # Required as a dependency for sabnzbd
|
||||
unfreePackages = [ "unrar" ]; # Required for sabnzbd
|
||||
|
||||
# Requires updating the base_url config value in each service
|
||||
# If you try to rewrite the URL, the service won't redirect properly
|
||||
caddy.routes = [
|
||||
{
|
||||
# Group means that routes with the same name are mutually exclusive,
|
||||
# so they are split between the appropriate services.
|
||||
group = "download";
|
||||
match = [{
|
||||
host = [ config.hostnames.download ];
|
||||
@ -80,7 +70,6 @@ in {
|
||||
}];
|
||||
handle = [{
|
||||
handler = "reverse_proxy";
|
||||
# We're able to reference the url and port of the service dynamically
|
||||
upstreams = [{ dial = arrConfig.sonarr.url; }];
|
||||
}];
|
||||
}
|
||||
@ -103,7 +92,6 @@ in {
|
||||
}];
|
||||
handle = [{
|
||||
handler = "reverse_proxy";
|
||||
# Prowlarr doesn't offer a dynamic config, so we have to hardcode it
|
||||
upstreams = [{ dial = "localhost:9696"; }];
|
||||
}];
|
||||
}
|
||||
@ -116,7 +104,6 @@ in {
|
||||
handle = [{
|
||||
handler = "reverse_proxy";
|
||||
upstreams = [{
|
||||
# Bazarr only dynamically sets the port, not the host
|
||||
dial = "localhost:${
|
||||
builtins.toString config.services.bazarr.listenPort
|
||||
}";
|
||||
@ -158,12 +145,10 @@ in {
|
||||
Type = "simple";
|
||||
DynamicUser = true;
|
||||
ExecStart = let
|
||||
# Sabnzbd doesn't accept the URI path, unlike the others
|
||||
url = if name != "sabnzbd" then
|
||||
"http://${attrs.url}/${name}"
|
||||
else
|
||||
"http://${attrs.url}";
|
||||
# Exportarr is trained to pull from the arr services
|
||||
in ''
|
||||
${pkgs.exportarr}/bin/exportarr ${name} \
|
||||
--url ${url} \
|
||||
@ -212,7 +197,7 @@ in {
|
||||
prefix = "API_KEY=";
|
||||
};
|
||||
|
||||
# Prometheus scrape targets (expose Exportarr to Prometheus)
|
||||
# Prometheus scrape targets
|
||||
prometheus.scrapeTargets = map (key:
|
||||
"127.0.0.1:${
|
||||
lib.attrsets.getAttrFromPath [ key "exportarrPort" ] arrConfig
|
||||
|
@ -1,6 +1,3 @@
|
||||
# This is my setup for backing up SQlite databases and other systems to S3 or
|
||||
# S3-equivalent services (like Backblaze B2).
|
||||
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options = {
|
||||
|
@ -1,10 +1,3 @@
|
||||
# Bind is a DNS service. This allows me to resolve public domains locally so
|
||||
# when I'm at home, I don't have to travel over the Internet to reach my
|
||||
# server.
|
||||
|
||||
# To set this on all home machines, I point my router's DNS resolver to the
|
||||
# local IP address of the machine running this service (swan).
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
@ -23,19 +16,11 @@ in {
|
||||
|
||||
config = lib.mkIf config.services.bind.enable {
|
||||
|
||||
# Normally I block all requests not coming from Cloudflare, so I have to also
|
||||
# allow my local network.
|
||||
caddy.cidrAllowlist = [ "192.168.0.0/16" ];
|
||||
|
||||
services.bind = {
|
||||
|
||||
# Allow requests coming from these IPs. This way I don't somehow get
|
||||
# spammed with DNS requests coming from the Internet.
|
||||
cacheNetworks = [ "127.0.0.0/24" "192.168.0.0/16" ];
|
||||
|
||||
# When making normal DNS requests, forward them to Cloudflare to resolve.
|
||||
forwarders = [ "1.1.1.1" "1.0.0.1" ];
|
||||
|
||||
ipv4Only = true;
|
||||
|
||||
# Use rpz zone as an override
|
||||
@ -62,7 +47,6 @@ in {
|
||||
|
||||
};
|
||||
|
||||
# We must allow DNS traffic to hit our machine as well
|
||||
networking.firewall.allowedTCPPorts = [ 53 ];
|
||||
networking.firewall.allowedUDPPorts = [ 53 ];
|
||||
|
||||
|
@ -1,14 +1,3 @@
|
||||
# Caddy is a reverse proxy, like Nginx or Traefik. This creates an ingress
|
||||
# point from my local network or the public (via Cloudflare). Instead of a
|
||||
# Caddyfile, I'm using the more expressive JSON config file format. This means
|
||||
# I can source routes from other areas in my config and build the JSON file
|
||||
# using the result of the expression.
|
||||
|
||||
# Caddy helpfully provides automatic ACME cert generation and management, but
|
||||
# it requires a form of validation. We are using a custom build of Caddy
|
||||
# (compiled with an overlay) to insert a plugin for managing DNS validation
|
||||
# with Cloudflare's DNS API.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options = {
|
||||
@ -53,17 +42,12 @@
|
||||
configFile = pkgs.writeText "Caddyfile" (builtins.toJSON {
|
||||
apps.http.servers.main = {
|
||||
listen = [ ":443" ];
|
||||
|
||||
# These routes are pulled from the rest of this repo
|
||||
routes = config.caddy.routes;
|
||||
errors.routes = config.caddy.blocks;
|
||||
|
||||
logs = { }; # Uncommenting collects access logs
|
||||
logs = { }; # Uncomment to collect access logs
|
||||
};
|
||||
apps.http.servers.metrics = { }; # Enables Prometheus metrics
|
||||
apps.tls.automation.policies = config.caddy.tlsPolicies;
|
||||
|
||||
# Setup logging to file
|
||||
logging.logs.main = {
|
||||
encoder = { format = "console"; };
|
||||
writer = {
|
||||
@ -74,23 +58,13 @@
|
||||
};
|
||||
level = "INFO";
|
||||
};
|
||||
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
# Allows Caddy to serve lower ports (443, 80)
|
||||
systemd.services.caddy.serviceConfig.AmbientCapabilities =
|
||||
"CAP_NET_BIND_SERVICE";
|
||||
|
||||
# Required for web traffic to reach this machine
|
||||
networking.firewall.allowedTCPPorts = [ 80 443 ];
|
||||
|
||||
# HTTP/3 QUIC uses UDP (not sure if being used)
|
||||
networking.firewall.allowedUDPPorts = [ 443 ];
|
||||
|
||||
# Caddy exposes Prometheus metrics with the admin API
|
||||
# https://caddyserver.com/docs/api
|
||||
prometheus.scrapeTargets = [ "127.0.0.1:2019" ];
|
||||
|
||||
};
|
||||
|
@ -1,9 +1,3 @@
|
||||
# Calibre-web is an E-Book library and management tool.
|
||||
|
||||
# - Exposed to the public via Caddy.
|
||||
# - Hostname defined with config.hostnames.books
|
||||
# - File directory backed up to S3 on a cron schedule.
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
@ -32,7 +26,6 @@ in {
|
||||
};
|
||||
};
|
||||
|
||||
# Allow web traffic to Caddy
|
||||
caddy.routes = [{
|
||||
match = [{ host = [ config.hostnames.books ]; }];
|
||||
handle = [{
|
||||
@ -42,8 +35,6 @@ in {
|
||||
builtins.toString config.services.calibre-web.listen.port
|
||||
}";
|
||||
}];
|
||||
# This is required when calibre-web is behind a reverse proxy
|
||||
# https://github.com/janeczku/calibre-web/issues/19
|
||||
headers.request.add."X-Script-Name" = [ "/calibre-web" ];
|
||||
}];
|
||||
}];
|
||||
|
@ -1,12 +1,3 @@
|
||||
# Cloudflare Tunnel is a service for accessing the network even behind a
|
||||
# firewall, through outbound-only requests. It works by installing an agent on
|
||||
# our machines that exposes services through Cloudflare Access (Zero Trust),
|
||||
# similar to something like Tailscale.
|
||||
|
||||
# In this case, we're using Cloudflare Tunnel to enable SSH access over a web
|
||||
# browser even when outside of my network. This is probably not the safest
|
||||
# choice but I feel comfortable enough with it anyway.
|
||||
|
||||
{ config, lib, ... }:
|
||||
|
||||
# First time setup:
|
||||
@ -49,28 +40,23 @@
|
||||
tunnels = {
|
||||
"${config.cloudflareTunnel.id}" = {
|
||||
credentialsFile = config.secrets.cloudflared.dest;
|
||||
# Catch-all if no match (should never happen anyway)
|
||||
default = "http_status:404";
|
||||
# Match from ingress of any valid server name to SSH access
|
||||
ingress = { "*.masu.rs" = "ssh://localhost:22"; };
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Grant Cloudflare access to SSH into this server
|
||||
environment.etc = {
|
||||
"ssh/ca.pub".text = ''
|
||||
${config.cloudflareTunnel.ca}
|
||||
'';
|
||||
|
||||
# Must match the username portion of the email address in Cloudflare
|
||||
# Access
|
||||
# Must match the username of the email address in Cloudflare Access
|
||||
"ssh/authorized_principals".text = ''
|
||||
${config.user}
|
||||
'';
|
||||
};
|
||||
|
||||
# Adjust SSH config to allow access from Cloudflare's certificate
|
||||
services.openssh.extraConfig = ''
|
||||
PubkeyAuthentication yes
|
||||
TrustedUserCAKeys /etc/ssh/ca.pub
|
||||
|
@ -1,13 +1,5 @@
|
||||
# This module is necessary for hosts that are serving through Cloudflare.
|
||||
|
||||
# Cloudflare is a CDN service that is used to serve the domain names and
|
||||
# caching for my websites and services. Since Cloudflare acts as our proxy, we
|
||||
# must allow access over the Internet from Cloudflare's IP ranges.
|
||||
|
||||
# We also want to validate our HTTPS certificates from Caddy. We'll use Caddy's
|
||||
# DNS validation plugin to connect to Cloudflare and automatically create
|
||||
# validation DNS records for our generated certificates.
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
@ -67,9 +59,10 @@ in {
|
||||
};
|
||||
}];
|
||||
}];
|
||||
# Allow Caddy to read Cloudflare API key for DNS validation
|
||||
systemd.services.caddy.serviceConfig.EnvironmentFile =
|
||||
config.secrets.cloudflareApi.dest;
|
||||
systemd.services.caddy.serviceConfig.AmbientCapabilities =
|
||||
"CAP_NET_BIND_SERVICE";
|
||||
|
||||
# API key must have access to modify Cloudflare DNS records
|
||||
secrets.cloudflareApi = {
|
||||
@ -80,7 +73,7 @@ in {
|
||||
};
|
||||
|
||||
# Allows Nextcloud to trust Cloudflare IPs
|
||||
services.nextcloud.extraOptions.trusted_proxies = cloudflareIpRanges;
|
||||
services.nextcloud.config.trustedProxies = cloudflareIpRanges;
|
||||
|
||||
};
|
||||
}
|
||||
|
@ -1,6 +1,3 @@
|
||||
# This file imports all the other files in this directory for use as modules in
|
||||
# my config.
|
||||
|
||||
{ ... }: {
|
||||
|
||||
imports = [
|
||||
@ -16,15 +13,12 @@
|
||||
./gnupg.nix
|
||||
./grafana.nix
|
||||
./honeypot.nix
|
||||
./influxdb2.nix
|
||||
./jellyfin.nix
|
||||
./keybase.nix
|
||||
./mullvad.nix
|
||||
./n8n.nix
|
||||
./netdata.nix
|
||||
./nextcloud.nix
|
||||
./paperless.nix
|
||||
./postgresql.nix
|
||||
./prometheus.nix
|
||||
./samba.nix
|
||||
./secrets.nix
|
||||
|
@ -1,9 +1,3 @@
|
||||
# Gitea Actions is a CI/CD service for the Gitea source code server, meaning it
|
||||
# allows us to run code operations (such as testing or deploys) when our git
|
||||
# repositories are updated. Any machine can act as a Gitea Action Runner, so
|
||||
# the Runners don't necessarily need to be running Gitea. All we need is an API
|
||||
# key for Gitea to connect to it and register ourselves as a Runner.
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
|
@ -11,21 +11,11 @@ in {
|
||||
actions.ENABLED = true;
|
||||
metrics.ENABLED = true;
|
||||
repository = {
|
||||
# Pushing to a repo that doesn't exist automatically creates one as
|
||||
# private.
|
||||
DEFAULT_PUSH_CREATE_PRIVATE = true;
|
||||
|
||||
# Allow git over HTTP.
|
||||
DISABLE_HTTP_GIT = false;
|
||||
|
||||
# Allow requests hitting the specified hostname.
|
||||
ACCESS_CONTROL_ALLOW_ORIGIN = config.hostnames.git;
|
||||
|
||||
# Automatically create viable users/orgs on push.
|
||||
ENABLE_PUSH_CREATE_USER = true;
|
||||
ENABLE_PUSH_CREATE_ORG = true;
|
||||
|
||||
# Default when creating new repos.
|
||||
DEFAULT_BRANCH = "main";
|
||||
};
|
||||
server = {
|
||||
@ -35,15 +25,11 @@ in {
|
||||
SSH_PORT = 22;
|
||||
START_SSH_SERVER = false; # Use sshd instead
|
||||
DISABLE_SSH = false;
|
||||
# SSH_LISTEN_HOST = "0.0.0.0";
|
||||
# SSH_LISTEN_PORT = 122;
|
||||
};
|
||||
|
||||
# Don't allow public users to register accounts.
|
||||
service.DISABLE_REGISTRATION = true;
|
||||
|
||||
# Force using HTTPS for all session access.
|
||||
session.COOKIE_SECURE = true;
|
||||
|
||||
# Hide users' emails.
|
||||
ui.SHOW_USER_EMAIL = false;
|
||||
};
|
||||
extraConfig = null;
|
||||
@ -53,7 +39,6 @@ in {
|
||||
users.users.${config.user}.extraGroups = [ "gitea" ];
|
||||
|
||||
caddy.routes = [
|
||||
# Prevent public access to Prometheus metrics.
|
||||
{
|
||||
match = [{
|
||||
host = [ config.hostnames.git ];
|
||||
@ -64,7 +49,6 @@ in {
|
||||
status_code = "403";
|
||||
}];
|
||||
}
|
||||
# Allow access to primary server.
|
||||
{
|
||||
match = [{ host = [ config.hostnames.git ]; }];
|
||||
handle = [{
|
||||
@ -79,7 +63,6 @@ in {
|
||||
}
|
||||
];
|
||||
|
||||
# Scrape the metrics endpoint for Prometheus.
|
||||
prometheus.scrapeTargets = [
|
||||
"127.0.0.1:${
|
||||
builtins.toString config.services.gitea.settings.server.HTTP_PORT
|
||||
|
@ -1,5 +1,3 @@
|
||||
# GPG is an encryption tool. This isn't really in use for me at the moment.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.gpg.enable = lib.mkEnableOption "GnuPG encryption.";
|
||||
|
@ -7,7 +7,6 @@ in {
|
||||
|
||||
config = lib.mkIf config.services.grafana.enable {
|
||||
|
||||
# Allow Grafana to connect to email service
|
||||
secrets.mailpass-grafana = {
|
||||
source = ../../../private/mailpass-grafana.age;
|
||||
dest = "${config.secretsDirectory}/mailpass-grafana";
|
||||
|
@ -1,10 +1,7 @@
|
||||
# This is a tool for blocking IPs of anyone who attempts to scan all of my
|
||||
# ports.
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
# Currently has some issues that don't make this viable.
|
||||
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
# Taken from:
|
||||
# https://dataswamp.org/~solene/2022-09-29-iblock-implemented-in-nixos.html
|
||||
|
||||
|
@ -1,61 +0,0 @@
|
||||
# InfluxDB is a timeseries database similar to Prometheus. While
|
||||
# VictoriaMetrics can also act as an InfluxDB, this version of it allows for
|
||||
# infinite retention separate from our other metrics, which can be nice for
|
||||
# recording health information, for example.
|
||||
|
||||
{ config, lib, ... }: {
|
||||
|
||||
config = {
|
||||
|
||||
services.influxdb2 = {
|
||||
provision = {
|
||||
enable = true;
|
||||
initialSetup = {
|
||||
bucket = "default";
|
||||
organization = "main";
|
||||
passwordFile = config.secrets.influxdb2Password.dest;
|
||||
retention = 0; # Keep data forever
|
||||
tokenFile = config.secrets.influxdb2Token.dest;
|
||||
username = "admin";
|
||||
};
|
||||
};
|
||||
settings = { };
|
||||
};
|
||||
|
||||
# Create credentials file for InfluxDB admin
|
||||
secrets.influxdb2Password = lib.mkIf config.services.influxdb2.enable {
|
||||
source = ../../../private/influxdb2-password.age;
|
||||
dest = "${config.secretsDirectory}/influxdb2-password";
|
||||
owner = "influxdb2";
|
||||
group = "influxdb2";
|
||||
permissions = "0440";
|
||||
};
|
||||
systemd.services.influxdb2Password-secret =
|
||||
lib.mkIf config.services.influxdb2.enable {
|
||||
requiredBy = [ "influxdb2.service" ];
|
||||
before = [ "influxdb2.service" ];
|
||||
};
|
||||
secrets.influxdb2Token = lib.mkIf config.services.influxdb2.enable {
|
||||
source = ../../../private/influxdb2-token.age;
|
||||
dest = "${config.secretsDirectory}/influxdb2-token";
|
||||
owner = "influxdb2";
|
||||
group = "influxdb2";
|
||||
permissions = "0440";
|
||||
};
|
||||
systemd.services.influxdb2Token-secret =
|
||||
lib.mkIf config.services.influxdb2.enable {
|
||||
requiredBy = [ "influxdb2.service" ];
|
||||
before = [ "influxdb2.service" ];
|
||||
};
|
||||
|
||||
caddy.routes = lib.mkIf config.services.influxdb2.enable [{
|
||||
match = [{ host = [ config.hostnames.influxdb ]; }];
|
||||
handle = [{
|
||||
handler = "reverse_proxy";
|
||||
upstreams = [{ dial = "localhost:8086"; }];
|
||||
}];
|
||||
}];
|
||||
|
||||
};
|
||||
|
||||
}
|
@ -1,6 +1,3 @@
|
||||
# Jellyfin is a self-hosted video streaming service. This means I can play my
|
||||
# server's videos from a webpage, mobile app, or TV client.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
config = lib.mkIf config.services.jellyfin.enable {
|
||||
@ -9,7 +6,6 @@
|
||||
users.users.jellyfin = { isSystemUser = true; };
|
||||
|
||||
caddy.routes = [
|
||||
# Prevent public access to Prometheus metrics.
|
||||
{
|
||||
match = [{
|
||||
host = [ config.hostnames.stream ];
|
||||
@ -20,7 +16,6 @@
|
||||
status_code = "403";
|
||||
}];
|
||||
}
|
||||
# Allow access to normal route.
|
||||
{
|
||||
match = [{ host = [ config.hostnames.stream ]; }];
|
||||
handle = [{
|
||||
@ -52,9 +47,6 @@
|
||||
users.users.jellyfin.extraGroups =
|
||||
[ "render" "video" ]; # Access to /dev/dri
|
||||
|
||||
# Fix issue where Jellyfin-created directories don't allow access for media group
|
||||
systemd.services.jellyfin.serviceConfig.UMask = lib.mkForce "0007";
|
||||
|
||||
# Requires MetricsEnable is true in /var/lib/jellyfin/config/system.xml
|
||||
prometheus.scrapeTargets = [ "127.0.0.1:8096" ];
|
||||
|
||||
|
@ -1,23 +1,23 @@
|
||||
# Keybase is an encrypted communications tool with a synchronized encrypted
|
||||
# filestore that can be mounted onto a machine's filesystem.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.keybase.enable = lib.mkEnableOption "Keybase.";
|
||||
|
||||
config = lib.mkIf config.keybase.enable {
|
||||
|
||||
home-manager.users.${config.user} = lib.mkIf config.keybase.enable {
|
||||
|
||||
services.keybase.enable = true;
|
||||
services.kbfs = {
|
||||
enable = true;
|
||||
mountPoint = "keybase";
|
||||
};
|
||||
|
||||
# https://github.com/nix-community/home-manager/issues/4722
|
||||
systemd.user.services.kbfs.Service.PrivateTmp = lib.mkForce false;
|
||||
services.keybase.enable = true;
|
||||
services.kbfs = {
|
||||
enable = true;
|
||||
# enableRedirector = true;
|
||||
mountPoint = "/run/user/1000/keybase/kbfs";
|
||||
};
|
||||
security.wrappers.keybase-redirector = {
|
||||
setuid = true;
|
||||
owner = "root";
|
||||
group = "root";
|
||||
source = "${pkgs.kbfs}/bin/redirector";
|
||||
};
|
||||
|
||||
home-manager.users.${config.user} = {
|
||||
home.packages = [ (lib.mkIf config.gui.enable pkgs.keybase-gui) ];
|
||||
home.file = let
|
||||
ignorePatterns = ''
|
||||
|
@ -1,5 +1,3 @@
|
||||
# Mullvad is a VPN service. This isn't currently in use for me at the moment.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.mullvad.enable = lib.mkEnableOption "Mullvad VPN.";
|
||||
|
@ -1,6 +1,3 @@
|
||||
# n8n is an automation integration tool for connecting data from services
|
||||
# together with triggers.
|
||||
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options = {
|
||||
|
@ -1,6 +1,3 @@
|
||||
# Netdata is an out-of-the-box monitoring tool that exposes many different
|
||||
# metrics. Not currently in use, in favor of VictoriaMetrics and Grafana.
|
||||
|
||||
{ config, lib, ... }: {
|
||||
|
||||
options.netdata.enable = lib.mkEnableOption "Netdata metrics.";
|
||||
|
@ -3,7 +3,7 @@
|
||||
config = lib.mkIf config.services.nextcloud.enable {
|
||||
|
||||
services.nextcloud = {
|
||||
package = pkgs.nextcloud28; # Required to specify
|
||||
package = pkgs.nextcloud27; # Required to specify
|
||||
configureRedis = true;
|
||||
datadir = "/data/nextcloud";
|
||||
database.createLocally = true;
|
||||
@ -13,25 +13,18 @@
|
||||
config = {
|
||||
adminpassFile = config.secrets.nextcloud.dest;
|
||||
dbtype = "mysql";
|
||||
extraTrustedDomains = [ config.hostnames.content ];
|
||||
trustedProxies = [ "127.0.0.1" ];
|
||||
};
|
||||
extraOptions = {
|
||||
default_phone_region = "US";
|
||||
# Allow access when hitting either of these hosts or IPs
|
||||
trusted_domains = [ config.hostnames.content ];
|
||||
trusted_proxies = [ "127.0.0.1" ];
|
||||
};
|
||||
extraOptions = { default_phone_region = "US"; };
|
||||
extraAppsEnable = true;
|
||||
extraApps = with config.services.nextcloud.package.packages.apps; {
|
||||
inherit calendar contacts;
|
||||
# These apps are defined and pinned by overlay in flake.
|
||||
news = pkgs.nextcloudApps.news;
|
||||
external = pkgs.nextcloudApps.external;
|
||||
cookbook = pkgs.nextcloudApps.cookbook;
|
||||
};
|
||||
phpOptions = {
|
||||
"opcache.interned_strings_buffer" = "16";
|
||||
"output_buffering" = "0";
|
||||
};
|
||||
phpOptions = { "opcache.interned_strings_buffer" = "16"; };
|
||||
};
|
||||
|
||||
# Don't let Nginx use main ports (using Caddy instead)
|
||||
@ -54,10 +47,7 @@
|
||||
handle = [
|
||||
{
|
||||
handler = "vars";
|
||||
# Grab the webroot out of the written config
|
||||
# The webroot is a symlinked combined Nextcloud directory
|
||||
root =
|
||||
config.services.nginx.virtualHosts.${config.services.nextcloud.hostName}.root;
|
||||
root = config.services.nextcloud.package;
|
||||
}
|
||||
{
|
||||
handler = "headers";
|
||||
@ -66,6 +56,13 @@
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
match = [{ path = [ "/nix-apps*" "/store-apps*" ]; }];
|
||||
handle = [{
|
||||
handler = "vars";
|
||||
root = config.services.nextcloud.home;
|
||||
}];
|
||||
}
|
||||
# Reroute carddav and caldav traffic
|
||||
{
|
||||
match =
|
||||
|
@ -1,50 +0,0 @@
|
||||
# Paperless-ngx is a document scanning and management solution.
|
||||
|
||||
{ config, lib, ... }: {
|
||||
|
||||
config = lib.mkIf config.services.paperless.enable {
|
||||
|
||||
services.paperless = {
|
||||
mediaDir = "/data/generic/paperless";
|
||||
passwordFile = config.secrets.paperless.dest;
|
||||
settings = {
|
||||
PAPERLESS_OCR_USER_ARGS =
|
||||
builtins.toJSON { invalidate_digital_signatures = true; };
|
||||
|
||||
# Enable if changing the path name in Caddy
|
||||
# PAPERLESS_FORCE_SCRIPT_NAME = "/paperless";
|
||||
# PAPERLESS_STATIC_URL = "/paperless/static/";
|
||||
};
|
||||
};
|
||||
|
||||
users.users.paperless.extraGroups = [ "generic" ];
|
||||
|
||||
caddy.routes = [{
|
||||
match = [{
|
||||
host = [ config.hostnames.paperless ];
|
||||
# path = [ "/paperless*" ]; # Change path name in Caddy
|
||||
}];
|
||||
handle = [{
|
||||
handler = "reverse_proxy";
|
||||
upstreams = [{
|
||||
dial =
|
||||
"localhost:${builtins.toString config.services.paperless.port}";
|
||||
}];
|
||||
}];
|
||||
}];
|
||||
|
||||
secrets.paperless = {
|
||||
source = ../../../private/prometheus.age;
|
||||
dest = "${config.secretsDirectory}/paperless";
|
||||
owner = "paperless";
|
||||
group = "paperless";
|
||||
permissions = "0440";
|
||||
};
|
||||
systemd.services.paperless-secret = {
|
||||
requiredBy = [ "paperless.service" ];
|
||||
before = [ "paperless.service" ];
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
}
|
@ -1,22 +0,0 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
services.postgresql = {
|
||||
package = pkgs.postgresql_15;
|
||||
settings = { };
|
||||
identMap = "";
|
||||
ensureUsers = [{
|
||||
name = config.user;
|
||||
ensureClauses = {
|
||||
createdb = true;
|
||||
createrole = true;
|
||||
login = true;
|
||||
};
|
||||
}];
|
||||
};
|
||||
|
||||
home-manager.users.${config.user}.home.packages =
|
||||
lib.mkIf config.services.postgresql.enable [
|
||||
pkgs.pgcli # Postgres client with autocomplete
|
||||
];
|
||||
|
||||
}
|
@ -1,9 +1,3 @@
|
||||
# Prometheus is a timeseries database that exposes system and service metrics
|
||||
# for use in visualizing, monitoring, and alerting (with Grafana).
|
||||
|
||||
# Instead of running traditional Prometheus, I generally run VictoriaMetrics as
|
||||
# a more efficient drop-in replacement.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.prometheus = {
|
||||
|
@ -1,5 +1,3 @@
|
||||
# Samba is a Windows-compatible file-sharing service.
|
||||
|
||||
{ config, lib, ... }: {
|
||||
|
||||
config = {
|
||||
|
@ -1,5 +1,3 @@
|
||||
# SSHD service for allowing SSH access to my machines.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options = {
|
||||
|
@ -1,6 +1,3 @@
|
||||
# Transmission is a bittorrent client, which can run in the background for
|
||||
# automated downloads with a web GUI.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options = {
|
||||
|
@ -1,7 +1,3 @@
|
||||
# Vaultwarden is an implementation of the Bitwarden password manager backend
|
||||
# service, which allows for self-hosting the synchronization of a Bitwarden
|
||||
# password manager client.
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let vaultwardenPath = "/var/lib/bitwarden_rs"; # Default service directory
|
||||
|
@ -1,6 +1,3 @@
|
||||
# VictoriaMetrics is a more efficient drop-in replacement for Prometheus and
|
||||
# InfluxDB (timeseries databases built for monitoring system metrics).
|
||||
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
let
|
||||
|
@ -1,6 +1,3 @@
|
||||
# Wireguard is a VPN protocol that can be setup to create a mesh network
|
||||
# between machines on different LANs. This is currently not in use in my setup.
|
||||
|
||||
{ config, pkgs, lib, ... }: {
|
||||
|
||||
options.wireguard.enable = lib.mkEnableOption "Wireguard VPN setup.";
|
||||
|
@ -26,14 +26,9 @@
|
||||
};
|
||||
};
|
||||
|
||||
home-manager.users.${config.user}.programs = {
|
||||
|
||||
# Alias sudo to doas for convenience
|
||||
fish.shellAliases = { sudo = "doas"; };
|
||||
|
||||
# Disable overriding our sudo alias with a TERMINFO alias
|
||||
kitty.settings.shell_integration = "no-sudo";
|
||||
|
||||
# Alias sudo to doas for convenience
|
||||
home-manager.users.${config.user}.programs.fish.shellAliases = {
|
||||
sudo = "doas";
|
||||
};
|
||||
|
||||
};
|
||||
|
@ -1,9 +1,5 @@
|
||||
# Pin age because it is failing to build
|
||||
# https://github.com/NixOS/nixpkgs/pull/265753
|
||||
|
||||
inputs: _final: prev: {
|
||||
age = prev.age.overrideAttrs (old: {
|
||||
src = inputs.age;
|
||||
doCheck = false; # https://github.com/FiloSottile/age/issues/517
|
||||
});
|
||||
age = prev.age.overrideAttrs (old: { src = inputs.age; });
|
||||
}
|
||||
|
@ -1,20 +0,0 @@
|
||||
inputs: _final: prev: {
|
||||
|
||||
# Based on:
|
||||
# https://git.sr.ht/~rycee/nur-expressions/tree/master/item/pkgs/firefox-addons/default.nix#L34
|
||||
|
||||
bypass-paywalls-clean = let addonId = "magnolia@12.34";
|
||||
in prev.stdenv.mkDerivation rec {
|
||||
pname = "bypass-paywalls-clean";
|
||||
version = "3.4.9.0";
|
||||
src = inputs.bypass-paywalls-clean + "/bypass_paywalls_clean-latest.xpi";
|
||||
preferLocalBuild = true;
|
||||
allowSubstitutes = true;
|
||||
buildCommand = ''
|
||||
dst="$out/share/mozilla/extensions/{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"
|
||||
mkdir -p "$dst"
|
||||
install -v -m644 "${src}" "$dst/${addonId}.xpi"
|
||||
'';
|
||||
};
|
||||
|
||||
}
|
@ -31,7 +31,7 @@ in {
|
||||
|
||||
src = prev.caddy.src;
|
||||
|
||||
vendorHash = "sha256:pr2MI2Nv9y357lCEEh6aNdmD9FiCaJIkRfHaoWgdQIE=";
|
||||
vendorSha256 = "sha256:mwIsWJYKuEZpOU38qZOG1LEh4QpK4EO0/8l4UGsroU8=";
|
||||
|
||||
overrideModAttrs = (_: {
|
||||
preBuild = ''
|
||||
|
@ -1,8 +1,8 @@
|
||||
diff --git a/cps/__init__.py b/cps/__init__.py
|
||||
index f4f8dbf2..7377acdf 100644
|
||||
index 269e4aca..e2b828a9 100644
|
||||
--- a/cps/__init__.py
|
||||
+++ b/cps/__init__.py
|
||||
@@ -151,7 +151,6 @@ def create_app():
|
||||
@@ -150,7 +150,6 @@ def create_app():
|
||||
|
||||
lm.login_view = 'web.login'
|
||||
lm.anonymous_user = ub.Anonymous
|
||||
@ -11,17 +11,15 @@ index f4f8dbf2..7377acdf 100644
|
||||
db.CalibreDB.update_config(config)
|
||||
db.CalibreDB.setup_db(config.config_calibre_dir, cli_param.settings_path)
|
||||
diff --git a/cps/admin.py b/cps/admin.py
|
||||
index 045a9523..825a28af 100644
|
||||
index 20c58aac..99d2ad19 100644
|
||||
--- a/cps/admin.py
|
||||
+++ b/cps/admin.py
|
||||
@@ -102,10 +102,6 @@ def admin_required(f):
|
||||
@@ -101,8 +101,6 @@ def admin_required(f):
|
||||
|
||||
@admi.before_app_request
|
||||
def before_request():
|
||||
- if not ub.check_user_session(current_user.id,
|
||||
- flask_session.get('_id')) and 'opds' not in request.path \
|
||||
- and config.config_session == 1:
|
||||
- if not ub.check_user_session(current_user.id, flask_session.get('_id')) and 'opds' not in request.path:
|
||||
- logout_user()
|
||||
g.constants = constants
|
||||
g.google_site_verification = os.getenv('GOOGLE_SITE_VERIFICATION', '')
|
||||
g.google_site_verification = os.getenv('GOOGLE_SITE_VERIFICATION','')
|
||||
g.allow_registration = config.config_public_reg
|
||||
|
@ -1,25 +0,0 @@
|
||||
_final: prev: {
|
||||
|
||||
gh-collaborators = prev.buildGo120Module rec {
|
||||
pname = "gh-collaborators";
|
||||
version = "2.0.2";
|
||||
|
||||
src = prev.fetchFromGitHub {
|
||||
owner = "katiem0";
|
||||
repo = "gh-collaborators";
|
||||
rev = version;
|
||||
sha256 = "sha256-sz5LHkwZ28aA2vbMnFMzAlyGiJBDZm7jwDQYxgKBPLU=";
|
||||
};
|
||||
|
||||
vendorHash = "sha256-rsRDOgJBa8T6+bC/APcmuRmg6ykbIp9pwRnJ9rrfHEs=";
|
||||
|
||||
ldflags = [
|
||||
"-s"
|
||||
"-w"
|
||||
"-X github.com/katiem0/gh-collaborators/cmd.Version=${version}"
|
||||
# "-X main.Version=${version}"
|
||||
];
|
||||
|
||||
};
|
||||
|
||||
}
|
6
overlays/keyd.nix
Normal file
6
overlays/keyd.nix
Normal file
@ -0,0 +1,6 @@
|
||||
# Use latest PR of keyd to update to 2.4.3
|
||||
# https://github.com/NixOS/nixpkgs/pull/245327
|
||||
|
||||
inputs: _final: prev: {
|
||||
inherit (inputs.nixpkgs-keyd.legacyPackages.${prev.system}) keyd;
|
||||
}
|
@ -9,7 +9,7 @@ let
|
||||
|
||||
# Package plugin - for plugins not found in nixpkgs at all
|
||||
plugin = pname: src:
|
||||
prev.vimUtils.buildVimPlugin {
|
||||
prev.vimUtils.buildVimPluginFrom2Nix {
|
||||
inherit pname src;
|
||||
version = "master";
|
||||
};
|
||||
@ -17,6 +17,8 @@ let
|
||||
in {
|
||||
|
||||
nil = inputs.nil.packages.${prev.system}.nil;
|
||||
vscode-terraform-snippets = inputs.vscode-terraform-snippets;
|
||||
|
||||
nvim-lspconfig = withSrc prev.vimPlugins.nvim-lspconfig inputs.nvim-lspconfig;
|
||||
cmp-nvim-lsp = withSrc prev.vimPlugins.cmp-nvim-lsp inputs.cmp-nvim-lsp;
|
||||
null-ls-nvim = withSrc prev.vimPlugins.null-ls-nvim inputs.null-ls-nvim;
|
||||
@ -31,7 +33,6 @@ in {
|
||||
bufferline-nvim =
|
||||
withSrc prev.vimPlugins.bufferline-nvim inputs.bufferline-nvim;
|
||||
nvim-tree-lua = withSrc prev.vimPlugins.nvim-tree-lua inputs.nvim-tree-lua;
|
||||
fidget-nvim = withSrc prev.vimPlugins.fidget-nvim inputs.fidget-nvim;
|
||||
|
||||
# Packaging plugins entirely with Nix
|
||||
baleia-nvim = plugin "baleia-nvim" inputs.baleia-nvim-src;
|
||||
|
@ -1,12 +0,0 @@
|
||||
# Fix for Terraform and Consul on Darwin:
|
||||
# https://github.com/NixOS/nixpkgs/pull/275534/files
|
||||
_final: prev: {
|
||||
girara = prev.girara.overrideAttrs (old: {
|
||||
mesonFlags = [
|
||||
"-Ddocs=disabled"
|
||||
(prev.lib.mesonEnable "tests"
|
||||
((prev.stdenv.buildPlatform.canExecute prev.stdenv.hostPlatform)
|
||||
&& (!prev.stdenv.isDarwin)))
|
||||
];
|
||||
});
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IE1nSGFPdyBhUEdQ
|
||||
ejFtQWFabkl3YTJmUmRDS2M1elBrMU5yVHhWWlFLMHdOdlNsNEFRCmREU3ZZWlZi
|
||||
R1RLQVorT2dDbFRXc2toMExpNWR1WUEvaVlzUFJ5ZUU3azQKLT4gc3NoLWVkMjU1
|
||||
MTkgWXlTVU1RIDY5OGpSWlFTT2EvUzV4ajQwUG5YL3loSWhGbjV6U2J4TkFhQm5Y
|
||||
RWhvMXcKbUVpQm5wRmtLRGV2SWYzb2c3dnZYREdRSnRtdjJJcjRKTk0rbnMyZmVB
|
||||
cwotPiBzc2gtZWQyNTUxOSBuanZYNUEgd0o4WGhTQnlkVGhhWG44MmQ1UXFVWjFO
|
||||
MS9JcVpEOEIvd3ZuNmVmN2d3dwpYNXF5V05WbHRobVlIWVM2VHN1TjcyVG81cHp1
|
||||
V0pnWTduZFFWQks2ZFY0Ci0+IHNzaC1lZDI1NTE5IENxSU9VQSBkWXlRejFNdHJk
|
||||
azg0aUpzL1JMSWUvWkdXUmpLc3pVUEZTNGFwTG0rRlNrCjMyVTE5c1pjRlowVlJ4
|
||||
YmFtRzEzV1dCU0FoeUJPMjQzWHErc0h4RWhLbDgKLS0tIHhzK20vTzFPdVROVW44
|
||||
MkNhb2VWZHBqeXY0MWZuTDFUMXdNazMwTG8yZTQK1CrrD2tin/3ZhV2D1XJvkbUN
|
||||
2Nw4ASdPdRXaQJw5CMhlrW6rgSnC81j0249F7D7ZfAlo62ANOfLyL9Lv2FVGzg==
|
||||
-----END AGE ENCRYPTED FILE-----
|
@ -1,14 +0,0 @@
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IE1nSGFPdyBmTnVo
|
||||
eFlINGttSEZYTlZucVVWemlMMk0reHNKcjF3SmhCQllXdmw5RzBBCnl0NWZVb1ZW
|
||||
MWRzc05pNVVWTlRyNzNRaDlYTm5TSVF3ZGNMclhyY0R3bUkKLT4gc3NoLWVkMjU1
|
||||
MTkgWXlTVU1RIEppTjJPUmxlamdLY2xxRVBwcFBmTTdOM3dLU3h3YnA2TlhRWXRu
|
||||
OGJrR28KMW9JQUFDcXFLOTk4NDVHQmJucEZuOElLaG5Eb1lyK1NGTUJaMkFONit1
|
||||
dwotPiBzc2gtZWQyNTUxOSBuanZYNUEgZkF5MVNGK3FRV2JPVDFGMkY5SWxGWVVK
|
||||
YThUVFk2VGZZNXN6UWx3eFJ6MAp0d3NGWTRuLzNOb0VxdVUvZ1YwR0lWemc2NDR2
|
||||
VFI2eWRjS242SEJrQWx3Ci0+IHNzaC1lZDI1NTE5IENxSU9VQSBpY2JoaGRKY0ZR
|
||||
Y2txWFM1ODJyaW03b0xuRGlJMkVidEVZMGdiU1pTZ1hVCk0yeGF6VWU5LzF0Z1dL
|
||||
cnlDUCtLL01EWWo2Q0dYcjdtSjRtSnFjUHNWdzAKLS0tIEI4aWpNc0xqU3ZsLzcz
|
||||
TThFNXd0YjQ2MEMzc0JOQXZnTnBaTVg0V1hITzgK8GYZG8/fGXk6ELSB6rnLX0ke
|
||||
QqiztfVnV/fpgEgJ/K60Ea3aBe3ELpejzFKZfno+jesvnL5DCMGz7QRRpnThLQ==
|
||||
-----END AGE ENCRYPTED FILE-----
|
@ -1,15 +0,0 @@
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IHNzaC1lZDI1NTE5IE1nSGFPdyBWY3N0
|
||||
VkY0Y2tLQnNhZWdRVzFxU0plWThveUthK2NjZWNhZDd5ZGtXVVZ3CjVPc3YxbnBM
|
||||
MmozZFlORVppQmJrQ2ovWEFVVm81ZlBpRCtQQmRiNnBCaVUKLT4gc3NoLWVkMjU1
|
||||
MTkgWXlTVU1RIEtvRFJEQXJLNjlyRldpM2pMdXNxWVZmVFl2NVJjRUtuQzNtbmJq
|
||||
UTBDR2cKQ1J4cHVkWHJZU1M4dnFIekx2ejlua0NjUUtET0EwN24rY2NPcGQ5eEp1
|
||||
TQotPiBzc2gtZWQyNTUxOSBuanZYNUEgVnBQOHV5VUk0N2lyU2NkdXovQmJYVGhL
|
||||
dnUwTG9oZkZKOUxFWTNiZkhBbwo2WjgyNHBhaGtFREJGVDk5TzJhZjRzKytaLzZR
|
||||
TDQxeU9pY24zQnJBYmN3Ci0+IHNzaC1lZDI1NTE5IENxSU9VQSBQQ3I2YnNNZVlX
|
||||
TEhNbWhRSjJRbk9DYnJIRUFieDBMRUtBRVhxZ1RQcVNNClNzU0VPMnh5bUFGVTZm
|
||||
ekJLSzFjT3dHVVdoQ3A5ZStCUk83Qk5rcWZmN3MKLS0tIFdvRG1mYzdUenhndkY2
|
||||
amo0ZGpjQkdabUdNRUJwV29CRXByVk8ySEZzTzAKsDY+DVJqZb/jCn6Xa/OqNheR
|
||||
uNlV5vVKUaZu5F+MTZqZaRYdn66TJVXgz5GydbgwQGs3l0K67ikPiTOoln0FapnB
|
||||
TQ==
|
||||
-----END AGE ENCRYPTED FILE-----
|
@ -5,7 +5,7 @@
|
||||
inputs.nixpkgs.url = "github:NixOS/nixpkgs";
|
||||
inputs.poetry2nix.url = "github:nix-community/poetry2nix";
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils, poetry2nix }:
|
||||
outputs = { nixpkgs, flake-utils, poetry2nix }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = import nixpkgs {
|
||||
|
@ -11,7 +11,7 @@
|
||||
inputs.pypi-deps-db.follows = "pypi-deps-db";
|
||||
};
|
||||
|
||||
outputs = { nixpkgs, mach-nix, ... }:
|
||||
outputs = { nixpkgs, mach-nix }:
|
||||
let
|
||||
supportedSystems = [ "x86_64-linux" "x86_64-darwin" "aarch64-darwin" ];
|
||||
forAllSystems = f:
|
||||
|
@ -1,29 +0,0 @@
|
||||
{
|
||||
description = "Basic Rust project";
|
||||
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
outputs = { self, nixpkgs }:
|
||||
let
|
||||
forAllSystems = nixpkgs.lib.genAttrs [
|
||||
"x86_64-linux"
|
||||
"x86_64-darwin"
|
||||
"aarch64-linux"
|
||||
"aarch64-darwin"
|
||||
];
|
||||
in {
|
||||
devShells = forAllSystems (system:
|
||||
let pkgs = import nixpkgs { inherit system; };
|
||||
in {
|
||||
default = pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
gcc
|
||||
rustc
|
||||
cargo
|
||||
cargo-watch
|
||||
rustfmt
|
||||
pkg-config
|
||||
openssl
|
||||
];
|
||||
};
|
||||
});
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user