13 Commits

Author SHA1 Message Date
d84be966fc auto close pr if check fails 2023-09-30 09:35:37 -04:00
c9aa20c703 initial attempt for declarative proton-ge 2023-09-16 11:15:41 -04:00
771d41254f partial fix to bash and tree-sitter
still not working in opening bash files but works for other files
2023-09-16 10:08:38 -04:00
90092c48ec update lockfile and reclassify steam in i3 2023-09-16 09:31:56 -04:00
159a6efe09 update lockfile, pin age with overlay 2023-09-15 08:46:28 -04:00
0008de7434 update lockfile and replace exa with eza 2023-09-11 23:18:22 -04:00
9826178c0e fix: rofi-calc live results 2023-09-10 17:34:46 -04:00
d2b1d95281 fix: caddy cloudflare build requires newer golang 2023-09-09 23:20:38 +00:00
4c71797818 fix: nextcloudapps now require specifying licenses 2023-09-09 21:27:15 +00:00
dba975fe86 update lockfile and fix nil build 2023-09-09 10:46:00 -04:00
1a9ab975d1 update darwin firefox and add small convenience tweaks 2023-09-06 15:21:59 -04:00
67251a6d8d add epic games store to macos 2023-08-19 10:49:54 -06:00
967175df70 flake.lock: Update
Flake lock file updates:

• Updated input 'darwin':
    'github:lnl7/nix-darwin/829041cf10c4f6751a53c0a11ca2fd22ff0918d6' (2023-08-05)
  → 'github:lnl7/nix-darwin/426d38710b656b0a31f8eaae6e0002206a3b96d7' (2023-08-10)
• Updated input 'disko':
    'github:nix-community/disko/4015740375676402a2ee6adebc3c30ea625b9a94' (2023-07-30)
  → 'github:nix-community/disko/241c878d4b542fea7c61ed4421e9224af054ff56' (2023-08-11)
• Updated input 'firefox-darwin':
    'github:bandithedoge/nixpkgs-firefox-darwin/6081c33185dba05da784d9f2a392861af025bf1a' (2023-08-05)
  → 'github:bandithedoge/nixpkgs-firefox-darwin/4011a1903422d241c0619f7c631a15d27643fa30' (2023-08-12)
• Updated input 'hmts-nvim-src':
    'github:calops/hmts.nvim/1d40963804925754672940d07ddb250d19efec2e' (2023-08-05)
  → 'github:calops/hmts.nvim/594dd17c870afb7f6517723c8963f6eb144e3c0d' (2023-08-08)
• Updated input 'home-manager':
    'github:nix-community/home-manager/0a014a729cdd54d9919ff36b714d047909d7a4c8' (2023-08-05)
  → 'github:nix-community/home-manager/406d34d919e9e8b831b531782cf5ef6995188566' (2023-08-12)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/18036c0be90f4e308ae3ebcab0e14aae0336fe42' (2023-08-04)
  → 'github:nixos/nixpkgs/ce5e4a6ef2e59d89a971bc434ca8ca222b9c7f5e' (2023-08-10)
• Updated input 'null-ls-nvim-src':
    'github:jose-elias-alvarez/null-ls.nvim/db09b6c691def0038c456551e4e2772186449f35' (2023-07-06)
  → 'github:jose-elias-alvarez/null-ls.nvim/0010ea927ab7c09ef0ce9bf28c2b573fc302f5a7' (2023-08-12)
• Updated input 'nur':
    'github:nix-community/nur/cf2f5d8ad452795e5aca290c95eedc829d3da7ec' (2023-08-06)
  → 'github:nix-community/nur/fe48fefbf13a75562599c1ab43871eb5c4274e1a' (2023-08-13)
• Updated input 'nvim-tree-lua-src':
    'github:kyazdani42/nvim-tree.lua/904f95cd9db31d1800998fa428e78e418a50181d' (2023-08-06)
  → 'github:kyazdani42/nvim-tree.lua/0a54dcb76b02f3a4e2da370c7a3f6f2b7b43ef01' (2023-08-13)
2023-08-13 03:52:18 +00:00
25 changed files with 395 additions and 273 deletions

View File

@ -33,6 +33,20 @@ jobs:
- name: Check the Flake
run: nix flake check
- name: Enable Pull Request Automerge
run: gh pr merge --rebase --auto ${{ steps.update.outputs.pull-request-number }}
if: success()
run: |
gh pr merge \
--rebase \
--auto \
${{ steps.update.outputs.pull-request-number }}
env:
GH_TOKEN: ${{ github.token }}
- name: Close Pull Request If Failed
if: failure()
run: |
gh pr close \
--comment "Auto-closing pull request" \
--delete-branch \
${{ steps.update.outputs.pull-request-number }}
env:
GH_TOKEN: ${{ github.token }}

173
flake.lock generated
View File

@ -17,6 +17,23 @@
"type": "github"
}
},
"age": {
"flake": false,
"locked": {
"lastModified": 1672087018,
"narHash": "sha256-LRxxJQLQkzoCNYGS/XBixVmYXoZ1mPHKvFicPGXYLcw=",
"owner": "FiloSottile",
"repo": "age",
"rev": "c6dcfa1efcaa27879762a934d5bea0d1b83a894c",
"type": "github"
},
"original": {
"owner": "FiloSottile",
"ref": "v1.1.1",
"repo": "age",
"type": "github"
}
},
"baleia-nvim-src": {
"flake": false,
"locked": {
@ -73,11 +90,11 @@
]
},
"locked": {
"lastModified": 1691275315,
"narHash": "sha256-9WN0IA0vNZSNxKHpy/bYvPnCw4VH/nr5iBv7c+7KUts=",
"lastModified": 1694810318,
"narHash": "sha256-LuvrVj2oj9TzdnnwtQUClqcXjpgwCP01FFVBM7azGV8=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "829041cf10c4f6751a53c0a11ca2fd22ff0918d6",
"rev": "80bb201f4925cdda5a7a3c7b1900fb26bb2af2e8",
"type": "github"
},
"original": {
@ -94,11 +111,11 @@
]
},
"locked": {
"lastModified": 1690739034,
"narHash": "sha256-roW02IaiQ3gnEEDMCDWL5YyN+C4nBf/te6vfL7rG0jk=",
"lastModified": 1694808292,
"narHash": "sha256-zSZ8IfZfv6nK0z+wNuM0Tqx6c9b4+Q5Xn9FIpunWBwA=",
"owner": "nix-community",
"repo": "disko",
"rev": "4015740375676402a2ee6adebc3c30ea625b9a94",
"rev": "0faae8adf6d790df2c3d00437ccad7cd5c531c70",
"type": "github"
},
"original": {
@ -114,11 +131,11 @@
]
},
"locked": {
"lastModified": 1691196340,
"narHash": "sha256-b1haFWCbFJkiUkeTQCkNjr8hFq/8JlMPaQwNpGlcvxI=",
"lastModified": 1694651982,
"narHash": "sha256-oI8jrtIvLll+ADzm+qQqy58ybFeA1J1GlNgL3Q5hvGs=",
"owner": "bandithedoge",
"repo": "nixpkgs-firefox-darwin",
"rev": "6081c33185dba05da784d9f2a392861af025bf1a",
"rev": "a376e3619b40947054e2c5e93fbcc00aa9e24477",
"type": "github"
},
"original": {
@ -144,12 +161,15 @@
}
},
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1678901627,
"narHash": "sha256-U02riOqrKKzwjsxc/400XnElV+UtPUQWpANPlyazjH0=",
"lastModified": 1687709756,
"narHash": "sha256-Y5wKlQSkgEK2weWdOu4J3riRd+kV/VCgHsqLNTTWQ/0=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "93a2b84fc4b70d9e089d029deacc3583435c2ed6",
"rev": "dbabf0ca0c0c4bce6ea5eaf65af5cb694d2082c7",
"type": "github"
},
"original": {
@ -160,7 +180,7 @@
},
"flake-utils_2": {
"inputs": {
"systems": "systems"
"systems": "systems_2"
},
"locked": {
"lastModified": 1685518550,
@ -178,14 +198,14 @@
},
"flake-utils_3": {
"inputs": {
"systems": "systems_2"
"systems": "systems_3"
},
"locked": {
"lastModified": 1689068808,
"narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=",
"lastModified": 1692799911,
"narHash": "sha256-3eihraek4qL744EvQXsK1Ha6C3CR7nnT8X2qWap4RNk=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "919d646de7be200f3bf08cb76ae1f09402b6f9b4",
"rev": "f9e7cf818399d17d347f847525c5a5a8032e4e44",
"type": "github"
},
"original": {
@ -197,11 +217,11 @@
"hmts-nvim-src": {
"flake": false,
"locked": {
"lastModified": 1691223193,
"narHash": "sha256-Zsl4s3e4upWiU2mXKqiQcUGxslPzzebKKXfzaHiNq48=",
"lastModified": 1693226725,
"narHash": "sha256-jUuztOqNBltC3axa7s3CPJz9Cmukfwkf846+Z/gAxCU=",
"owner": "calops",
"repo": "hmts.nvim",
"rev": "1d40963804925754672940d07ddb250d19efec2e",
"rev": "14fd941d7ec2bb98314a1aacaa2573d97f1629ab",
"type": "github"
},
"original": {
@ -217,11 +237,11 @@
]
},
"locked": {
"lastModified": 1691225770,
"narHash": "sha256-O5slH8nW8msTAqVAS5rkvdHSkjmrO+JauuSDzZCmv2M=",
"lastModified": 1694643239,
"narHash": "sha256-pv2k/5FvyirDE8g4TNehzwZ0T4UOMMmqWSQnM/luRtE=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "0a014a729cdd54d9919ff36b714d047909d7a4c8",
"rev": "d9b88b43524db1591fb3d9410a21428198d75d49",
"type": "github"
},
"original": {
@ -276,16 +296,16 @@
"rust-overlay": "rust-overlay"
},
"locked": {
"lastModified": 1680544266,
"narHash": "sha256-d/TusDXmIo8IT5DNRA21lN+nOVSER8atIx9TJteR6LQ=",
"lastModified": 1691372739,
"narHash": "sha256-fZ8KfBMcIFO/R7xaWtB85SFeuUjb9SCH8fxYBnY8068=",
"owner": "oxalica",
"repo": "nil",
"rev": "56a1fa87b98a9508920f4b0ab8fe36d5b54b2362",
"rev": "97abe7d3d48721d4e0fcc1876eea83bb4247825b",
"type": "github"
},
"original": {
"owner": "oxalica",
"ref": "2023-04-03",
"ref": "2023-08-09",
"repo": "nil",
"type": "github"
}
@ -313,11 +333,11 @@
},
"nixlib": {
"locked": {
"lastModified": 1689469483,
"narHash": "sha256-2SBhY7rZQ/iNCxe04Eqxlz9YK9KgbaTMBssq3/BgdWY=",
"lastModified": 1693701915,
"narHash": "sha256-waHPLdDYUOHSEtMKKabcKIMhlUOHPOOPQ9UyFeEoovs=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "02fea408f27186f139153e1ae88f8ab2abd9c22c",
"rev": "f5af57d3ef9947a70ac86e42695231ac1ad00c25",
"type": "github"
},
"original": {
@ -334,11 +354,11 @@
]
},
"locked": {
"lastModified": 1690133435,
"narHash": "sha256-YNZiefETggroaTLsLJG2M+wpF0pJPwiauKG4q48ddNU=",
"lastModified": 1693791338,
"narHash": "sha256-wHmtB5H8AJTUaeGHw+0hsQ6nU4VyvVrP2P4NeCocRzY=",
"owner": "nix-community",
"repo": "nixos-generators",
"rev": "b1171de4d362c022130c92d7c8adc4bf2b83d586",
"rev": "8ee78470029e641cddbd8721496da1316b47d3b4",
"type": "github"
},
"original": {
@ -349,11 +369,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1691186842,
"narHash": "sha256-wxBVCvZUwq+XS4N4t9NqsHV4E64cPVqQ2fdDISpjcw0=",
"lastModified": 1694767346,
"narHash": "sha256-5uH27SiVFUwsTsqC5rs3kS7pBoNhtoy9QfTP9BmknGk=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "18036c0be90f4e308ae3ebcab0e14aae0336fe42",
"rev": "ace5093e36ab1e95cb9463863491bee90d5a4183",
"type": "github"
},
"original": {
@ -365,11 +385,11 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1690470004,
"narHash": "sha256-l57RmPhPz9r1LGDg/0v8bYgJO8R+GGTQZtkIxE7negU=",
"lastModified": 1694048570,
"narHash": "sha256-PEQptwFCVaJ+jLFJgrZll2shQ9VI/7xVhrCYkJo8iIw=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "9462344318b376e157c94fa60c20a25b913b2381",
"rev": "4f77ea639305f1de0a14d9d41eef83313360638c",
"type": "github"
},
"original": {
@ -382,11 +402,11 @@
"null-ls-nvim-src": {
"flake": false,
"locked": {
"lastModified": 1688652536,
"narHash": "sha256-6KJtj9pbvBm6fOVpnyzO2fEVC+cVrw2XtZHOgq9ieIw=",
"lastModified": 1691810493,
"narHash": "sha256-cWA0rzkOp/ekVKaFee7iea1lhnqKtWUIU+fW5M950wI=",
"owner": "jose-elias-alvarez",
"repo": "null-ls.nvim",
"rev": "db09b6c691def0038c456551e4e2772186449f35",
"rev": "0010ea927ab7c09ef0ce9bf28c2b573fc302f5a7",
"type": "github"
},
"original": {
@ -397,11 +417,11 @@
},
"nur": {
"locked": {
"lastModified": 1691289987,
"narHash": "sha256-sbbDlVzxlP+bBTdhyyzJ6C0APUNU/sChuLmNU9ehkmg=",
"lastModified": 1694814340,
"narHash": "sha256-eo9444JGI/G9jZF+X3xmS5TMRuIT4VYPKyZQ11iF65Q=",
"owner": "nix-community",
"repo": "nur",
"rev": "cf2f5d8ad452795e5aca290c95eedc829d3da7ec",
"rev": "9b70f21fd41d3b96580e7ca4a3d1c29e87bdab36",
"type": "github"
},
"original": {
@ -430,11 +450,11 @@
"nvim-tree-lua-src": {
"flake": false,
"locked": {
"lastModified": 1691292370,
"narHash": "sha256-YQRirmp8QerxwF9qdrSrUKJZiVrBb6ZWpUTfM8H7fl4=",
"lastModified": 1694306329,
"narHash": "sha256-Rv3DdlqRppEum09N4cKRlj0xdPbf5QLYHzYDuxb55w8=",
"owner": "kyazdani42",
"repo": "nvim-tree.lua",
"rev": "904f95cd9db31d1800998fa428e78e418a50181d",
"rev": "94c7c810af205c0f00c8f105dcf490c8eb17658a",
"type": "github"
},
"original": {
@ -446,23 +466,36 @@
"nvim-treesitter-src": {
"flake": false,
"locked": {
"lastModified": 1681121236,
"narHash": "sha256-iPsPDLhVKJ14iP1/2cCgcY9SCKK/DQz9Y0mQB1DqNiM=",
"lastModified": 1691831669,
"narHash": "sha256-1Iuvq0hVQ7LyBYOkJ5d07NkwbGcR1K61ZZmAAA7ABGs=",
"owner": "nvim-treesitter",
"repo": "nvim-treesitter",
"rev": "cc360a9beb1b30d172438f640e2c3450358c4086",
"rev": "63260da18bf273c76b8e2ea0db84eb901cab49ce",
"type": "github"
},
"original": {
"owner": "nvim-treesitter",
"ref": "v0.9.0",
"ref": "v0.9.1",
"repo": "nvim-treesitter",
"type": "github"
}
},
"proton-ge": {
"flake": false,
"locked": {
"narHash": "sha256-/68J3aVmHqrrcNk4DkYSBzfNyIQmbcUGg3yOlDq1ts8=",
"type": "tarball",
"url": "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-14/GE-Proton8-14.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-14/GE-Proton8-14.tar.gz"
}
},
"root": {
"inputs": {
"Comment-nvim-src": "Comment-nvim-src",
"age": "age",
"baleia-nvim-src": "baleia-nvim-src",
"bufferline-nvim-src": "bufferline-nvim-src",
"cmp-nvim-lsp-src": "cmp-nvim-lsp-src",
@ -483,6 +516,7 @@
"nvim-lspconfig-src": "nvim-lspconfig-src",
"nvim-tree-lua-src": "nvim-tree-lua-src",
"nvim-treesitter-src": "nvim-treesitter-src",
"proton-ge": "proton-ge",
"telescope-nvim-src": "telescope-nvim-src",
"telescope-project-nvim-src": "telescope-project-nvim-src",
"toggleterm-nvim-src": "toggleterm-nvim-src",
@ -509,11 +543,11 @@
]
},
"locked": {
"lastModified": 1680488274,
"narHash": "sha256-0vYMrZDdokVmPQQXtFpnqA2wEgCCUXf5a3dDuDVshn0=",
"lastModified": 1688783586,
"narHash": "sha256-HHaM2hk2azslv1kH8zmQxXo2e7i5cKgzNIuK4yftzB0=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "7ec2ff598a172c6e8584457167575b3a1a5d80d8",
"rev": "7a29283cc242c2486fc67f60b431ef708046d176",
"type": "github"
},
"original": {
@ -552,6 +586,21 @@
"type": "github"
}
},
"systems_3": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"telescope-nvim-src": {
"flake": false,
"locked": {
@ -605,17 +654,17 @@
"tree-sitter-bash": {
"flake": false,
"locked": {
"lastModified": 1688032601,
"narHash": "sha256-gl5F3IeZa2VqyH/qFj8ey2pRbGq4X8DL5wiyvRrH56U=",
"lastModified": 1692987612,
"narHash": "sha256-SP6s1bUvh1cXt3xQzdY9yVWq0BstfP1tjBedSQPPDC4=",
"owner": "tree-sitter",
"repo": "tree-sitter-bash",
"rev": "493646764e7ad61ce63ce3b8c59ebeb37f71b841",
"rev": "cc65fbeb028e7892f59bf3a609212bb0afbaa2d0",
"type": "github"
},
"original": {
"owner": "tree-sitter",
"ref": "v0.20.3",
"repo": "tree-sitter-bash",
"rev": "493646764e7ad61ce63ce3b8c59ebeb37f71b841",
"type": "github"
}
},
@ -723,11 +772,11 @@
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1690553050,
"narHash": "sha256-pK3kF30OykL3v6P8UP6ipihlS34KoGq9SryCj3tHrFw=",
"lastModified": 1694522206,
"narHash": "sha256-mb34WlyHi/whE6gIMEtXKfGRALzvB6/U7CYdUnJKN+c=",
"owner": "nix-community",
"repo": "NixOS-WSL",
"rev": "f7a95a37306c46b42e9ce751977c44c752fd5eca",
"rev": "e7d93d0f478b6fbb47c00d03449dc3d08b90abb7",
"type": "github"
},
"original": {

View File

@ -58,12 +58,13 @@
# Nix language server
nil = {
url = "github:oxalica/nil/2023-04-03";
url = "github:oxalica/nil/2023-08-09";
inputs.nixpkgs.follows = "nixpkgs";
};
# Neovim plugins
nvim-lspconfig-src = {
# https://github.com/neovim/nvim-lspconfig/tags
url = "github:neovim/nvim-lspconfig/v0.1.6";
flake = false;
};
@ -84,7 +85,8 @@
flake = false;
};
nvim-treesitter-src = {
url = "github:nvim-treesitter/nvim-treesitter/v0.9.0";
# https://github.com/nvim-treesitter/nvim-treesitter/tags
url = "github:nvim-treesitter/nvim-treesitter/v0.9.1";
flake = false;
};
telescope-nvim-src = {
@ -120,8 +122,7 @@
tree-sitter-bash = {
# Fix: bash highlighting doesn't work as of this commit:
# https://github.com/NixOS/nixpkgs/commit/49cce41b7c5f6b88570a482355d9655ca19c1029
url =
"github:tree-sitter/tree-sitter-bash/493646764e7ad61ce63ce3b8c59ebeb37f71b841";
url = "github:tree-sitter/tree-sitter-bash/v0.20.3";
flake = false;
};
tree-sitter-python = {
@ -150,6 +151,20 @@
flake = false;
};
# Age encryption (pin because of failed builds)
age = {
url = "github:FiloSottile/age/v1.1.1";
flake = false;
};
# GE version of Proton for game compatibility
# Alternatively, could consider using https://github.com/fufexan/nix-gaming
proton-ge = {
url =
"https://github.com/GloriousEggroll/proton-ge-custom/releases/download/GE-Proton8-14/GE-Proton8-14.tar.gz";
flake = false;
};
# Nextcloud Apps
nextcloud-news = {
url =
@ -208,6 +223,8 @@
(import ./overlays/mpv-scripts.nix inputs)
(import ./overlays/nextcloud-apps.nix inputs)
(import ./overlays/betterlockscreen.nix)
(import ./overlays/age.nix inputs)
(import ./overlays/proton-ge.nix inputs)
];
# System types to support.

View File

@ -16,6 +16,7 @@
unfreePackages = [
(lib.mkIf config._1password.enable "onepassword-password-manager")
"okta-browser-plugin"
"wappalyzer"
];
home-manager.users.${config.user} = {

View File

@ -11,10 +11,23 @@
config = lib.mkIf (config.gui.enable && config.kitty.enable) {
terminal = "${pkgs.kitty}/bin/kitty";
# Set the Rofi-Systemd terminal for viewing logs
# Using optionalAttrs because only available in NixOS
environment = { } // lib.attrsets.optionalAttrs
(builtins.hasAttr "sessionVariables" config.environment) {
sessionVariables.ROFI_SYSTEMD_TERM = "${pkgs.kitty}/bin/kitty";
};
home-manager.users.${config.user} = {
# Set the i3 terminal
xsession.windowManager.i3.config.terminal =
lib.mkIf pkgs.stdenv.isLinux "kitty";
# Set the Rofi terminal for running programs
programs.rofi.terminal =
lib.mkIf pkgs.stdenv.isLinux "${pkgs.kitty}/bin/kitty";
# Display images in the terminal
programs.fish.shellAliases = {
icat = "kitty +kitten icat";

View File

@ -65,6 +65,12 @@ key("n", "<C-Down>", ":resize -2<CR>", { silent = true })
key("n", "<C-Left>", ":vertical resize -2<CR>", { silent = true })
key("n", "<C-Right>", ":vertical resize +2<CR>", { silent = true })
-- Quickfix
key("n", "]q", ":cnext<CR>")
key("n", "[q", ":cprevious<CR>")
key("n", "co", ":copen<CR>")
key("n", "cq", ":cclose<CR>")
-- Other
key("n", "<A-CR>", ":noh<CR>", { silent = true }) --- Clear search in VimWiki
key("n", "Y", "y$") --- Copy to end of line

View File

@ -10,6 +10,7 @@
glow # Markdown previews
skate # Key-value store
charm # Manage account and filesystem
pop # Send emails from a TUI
];
};

View File

@ -6,7 +6,7 @@
home-manager.users.${config.user} = {
# Packages used in abbreviations and aliases
home.packages = with pkgs; [ curl exa ];
home.packages = with pkgs; [ curl ];
programs.fish = {
enable = true;
@ -15,8 +15,8 @@
# Version of bash which works much better on the terminal
bash = "${pkgs.bashInteractive}/bin/bash";
# Use exa instead of ls for fancier output
ls = "exa --group";
# Use eza (exa) instead of ls for fancier output
ls = "${pkgs.eza}/bin/eza --group";
# Move files to XDG trash on the commandline
trash = lib.mkIf pkgs.stdenv.isLinux "${pkgs.trash-cli}/bin/trash-put";

View File

@ -13,7 +13,7 @@
"$cmd_duration"
"$character"
];
# right_format = "$nix_shell";
right_format = "$nix_shell";
character = {
success_symbol = "[](bold green)";
error_symbol = "[](bold red)";

View File

@ -55,6 +55,15 @@ local function worklayout()
local layout = concat(left, right, laptop)
hs.layout.apply(layout)
end)
-- Reload Hammerspoon whenever layout changes
hs.screen.watcher.new(function()
-- Pause for 5 seconds to give time for layout to change
hs.timer.doAfter(5, function()
-- Perform the actual reload
hs.reload()
end)
end)
end
return worklayout

View File

@ -42,6 +42,7 @@
"obsidian" # Obsidian packaging on Nix is not available for macOS
"scroll-reverser" # Different scroll style for mouse vs. trackpad
"steam" # Not packaged for Nix
"epic-games" # Not packaged for Nix
];
};

View File

@ -22,6 +22,11 @@
];
# Adapted in part from: https://github.com/Shawn8901/nix-configuration/blob/1c48be94238a9f463cf0bbd1e1842a4454286514/modules/nixos/steam-compat-tools/default.nix
# Based on: https://github.com/NixOS/nixpkgs/issues/73323
environment.sessionVariables.STEAM_EXTRA_COMPAT_TOOLS_PATHS =
lib.makeBinPath [ pkgs.proton-ge-custom ];
# Seems like NetworkManager can help speed up Steam launch
# https://www.reddit.com/r/archlinux/comments/qguhco/steam_startup_time_arch_1451_seconds_fedora_34/hi8opet/
networking.networkmanager.enable = true;

View File

@ -5,7 +5,6 @@
./fonts.nix
./gtk.nix
./i3.nix
./keybinds.nix
./picom.nix
./polybar.nix
./rofi.nix
@ -14,6 +13,14 @@
options = {
launcherCommand = lib.mkOption {
type = lib.types.str;
description = "Command to use for launching";
};
systemdSearch = lib.mkOption {
type = lib.types.str;
description = "Command to use for interacting with systemd";
};
altTabCommand = lib.mkOption {
type = lib.types.str;
description = "Command to use for choosing windows";
@ -30,30 +37,14 @@
type = lib.types.str;
description = "Command to use for quick calculations";
};
launcherCommand = lib.mkOption {
toggleBarCommand = lib.mkOption {
type = lib.types.str;
description = "Command to use for launching";
};
lockScreenCommand = lib.mkOption {
type = lib.types.str;
description = "Command to use to lock the screen";
description = "Command to hide and show the status bar.";
};
powerCommand = lib.mkOption {
type = lib.types.str;
description = "Command to use for power options menu";
};
systemdSearch = lib.mkOption {
type = lib.types.str;
description = "Command to use for interacting with systemd";
};
terminal = lib.mkOption {
type = lib.types.str;
description = "Package to use for graphical terminal";
};
toggleBarCommand = lib.mkOption {
type = lib.types.str;
description = "Command to hide and show the status bar.";
};
wallpaper = lib.mkOption {
type = lib.types.path;
description = "Wallpaper background image file";

View File

@ -2,22 +2,11 @@
let
lockCmd =
"${pkgs.betterlockscreen}/bin/betterlockscreen --lock --display 1 --blur 0.5 --span";
lockUpdate =
"${pkgs.betterlockscreen}/bin/betterlockscreen --update ${config.wallpaper} --display 1 --span";
workspaces = {
"1" = "1:I";
"2" = "2:II";
"3" = "3:III";
"4" = "4:IV";
"5" = "5:V";
"6" = "6:VI";
"7" = "7:VII";
"8" = "8:VIII";
"9" = "9:IX";
"10" = "10:X";
};
in {
config = lib.mkIf pkgs.stdenv.isLinux {
@ -34,18 +23,29 @@ in {
home-manager.users.${config.user} = {
xsession.windowManager.i3 = {
enable = config.services.xserver.enable;
config = let modifier = "Mod4"; # Super key
config = let
modifier = "Mod4"; # Super key
ws1 = "1:I";
ws2 = "2:II";
ws3 = "3:III";
ws4 = "4:IV";
ws5 = "5:V";
ws6 = "6:VI";
ws7 = "7:VII";
ws8 = "8:VIII";
ws9 = "9:IX";
ws10 = "10:X";
in {
modifier = modifier;
assigns = {
"${workspaces."1"}" = [{ class = "Firefox"; }];
"${workspaces."2"}" = [
"${ws1}" = [{ class = "Firefox"; }];
"${ws2}" = [
{ class = "kitty"; }
{ class = "aerc"; }
{ class = "obsidian"; }
];
"${workspaces."3"}" = [{ class = "discord"; }];
"${workspaces."4"}" = [{ class = "Steam"; }];
"${ws3}" = [{ class = "discord"; }];
"${ws4}" = [ { class = "steam"; } { class = "Steam"; } ];
};
bars = [{ command = "echo"; }]; # Disable i3bar
colors = let
@ -91,7 +91,129 @@ in {
newWindow = "urgent";
followMouse = false;
};
keybindings = { };
keybindings = {
# Adjust screen brightness
"Shift+F12" =
"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 --display 2 setvcp 10 - 30";
"XF86MonBrightnessUp" =
"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 --display 2 setvcp 10 - 30";
# Media player controls
"XF86AudioPlay" = "exec ${pkgs.playerctl}/bin/playerctl play-pause";
"XF86AudioStop" = "exec ${pkgs.playerctl}/bin/playerctl stop";
"XF86AudioNext" = "exec ${pkgs.playerctl}/bin/playerctl next";
"XF86AudioPrev" = "exec ${pkgs.playerctl}/bin/playerctl previous";
# Launchers
"${modifier}+Return" =
"exec --no-startup-id kitty; workspace ${ws2}; layout tabbed";
"${modifier}+space" =
"exec --no-startup-id ${config.launcherCommand}";
"${modifier}+Shift+s" =
"exec --no-startup-id ${config.systemdSearch}";
"${modifier}+Shift+a" =
"exec --no-startup-id ${config.audioSwitchCommand}";
"Mod1+Tab" = "exec --no-startup-id ${config.altTabCommand}";
"${modifier}+Shift+period" =
"exec --no-startup-id ${config.powerCommand}";
"${modifier}+Shift+m" =
"exec --no-startup-id ${config.brightnessCommand}";
"${modifier}+c" =
"exec --no-startup-id ${config.calculatorCommand}";
"${modifier}+Shift+c" = "reload";
"${modifier}+Shift+r" = "restart";
"${modifier}+Shift+q" = ''
exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"'';
"${modifier}+Shift+x" = "exec ${lockCmd}";
"${modifier}+Mod1+h" =
"exec --no-startup-id kitty sh -c '${pkgs.home-manager}/bin/home-manager switch --flake ${config.dotfilesPath}#${config.networking.hostName} || read'";
"${modifier}+Mod1+r" =
"exec --no-startup-id kitty sh -c 'doas nixos-rebuild switch --flake ${config.dotfilesPath}#${config.networking.hostName} || read'";
# Window options
"${modifier}+q" = "kill";
"${modifier}+b" = "exec ${config.toggleBarCommand}";
"${modifier}+f" = "fullscreen toggle";
"${modifier}+h" = "focus left";
"${modifier}+j" = "focus down";
"${modifier}+k" = "focus up";
"${modifier}+l" = "focus right";
"${modifier}+Left" = "focus left";
"${modifier}+Down" = "focus down";
"${modifier}+Up" = "focus up";
"${modifier}+Right" = "focus right";
"${modifier}+Shift+h" = "move left";
"${modifier}+Shift+j" = "move down";
"${modifier}+Shift+k" = "move up";
"${modifier}+Shift+l" = "move right";
"${modifier}+Shift+Left" = "move left";
"${modifier}+Shift+Down" = "move down";
"${modifier}+Shift+Up" = "move up";
"${modifier}+Shift+Right" = "move right";
# Tiling
"${modifier}+i" = "split h";
"${modifier}+v" = "split v";
"${modifier}+s" = "layout stacking";
"${modifier}+t" = "layout tabbed";
"${modifier}+e" = "layout toggle split";
"${modifier}+Shift+space" = "floating toggle";
"${modifier}+Control+space" = "focus mode_toggle";
"${modifier}+a" = "focus parent";
# Workspaces
"${modifier}+1" = "workspace ${ws1}";
"${modifier}+2" = "workspace ${ws2}";
"${modifier}+3" = "workspace ${ws3}";
"${modifier}+4" = "workspace ${ws4}";
"${modifier}+5" = "workspace ${ws5}";
"${modifier}+6" = "workspace ${ws6}";
"${modifier}+7" = "workspace ${ws7}";
"${modifier}+8" = "workspace ${ws8}";
"${modifier}+9" = "workspace ${ws9}";
"${modifier}+0" = "workspace ${ws10}";
# Move windows
"${modifier}+Shift+1" =
"move container to workspace ${ws1}; workspace ${ws1}";
"${modifier}+Shift+2" =
"move container to workspace ${ws2}; workspace ${ws2}";
"${modifier}+Shift+3" =
"move container to workspace ${ws3}; workspace ${ws3}";
"${modifier}+Shift+4" =
"move container to workspace ${ws4}; workspace ${ws4}";
"${modifier}+Shift+5" =
"move container to workspace ${ws5}; workspace ${ws5}";
"${modifier}+Shift+6" =
"move container to workspace ${ws6}; workspace ${ws6}";
"${modifier}+Shift+7" =
"move container to workspace ${ws7}; workspace ${ws7}";
"${modifier}+Shift+8" =
"move container to workspace ${ws8}; workspace ${ws8}";
"${modifier}+Shift+9" =
"move container to workspace ${ws9}; workspace ${ws9}";
"${modifier}+Shift+0" =
"move container to workspace ${ws10}; workspace ${ws10}";
# Move screens
"${modifier}+Control+l" = "move workspace to output right";
"${modifier}+Control+h" = "move workspace to output left";
# Resizing
"${modifier}+r" = ''mode "resize"'';
"${modifier}+Control+Shift+h" =
"resize shrink width 10 px or 10 ppt";
"${modifier}+Control+Shift+j" =
"resize grow height 10 px or 10 ppt";
"${modifier}+Control+Shift+k" =
"resize shrink height 10 px or 10 ppt";
"${modifier}+Control+Shift+l" = "resize grow width 10 px or 10 ppt";
};
modes = { };
startup = [
{
@ -100,15 +222,16 @@ in {
notification = false;
}
{
command = "i3-msg focus right, workspace ${workspaces."2"}";
command =
"i3-msg workspace ${ws2}, move workspace to output right";
notification = false;
}
{
command = "i3-msg focus left, workspace ${workspaces."1"}";
command =
"i3-msg workspace ${ws1}, move workspace to output left";
notification = false;
}
];
terminal = config.terminal;
window = {
border = 0;
hideEdgeBorders = "smart";
@ -116,74 +239,22 @@ in {
};
workspaceAutoBackAndForth = false;
workspaceOutputAssign = [ ];
# gaps = {
# bottom = 8;
# top = 8;
# left = 8;
# right = 8;
# horizontal = 15;
# vertical = 15;
# inner = 15;
# outer = 0;
# smartBorders = "off";
# smartGaps = false;
# };
};
extraConfig = "";
};
services.sxhkd.keybindings = let
# Shortcuts
i3-msg = "${pkgs.i3}/bin/i3-msg";
in {
# Window navigation
"super + {_,shift +}{h,j,k,l}" =
''${i3-msg} "{focus,move} {left,down,up,right}"'';
"super + {_,shift +}{Left,Down,Up,Right}" =
''${i3-msg} "{focus,move} {left,down,up,right}"'';
"super + q" = ''${i3-msg} "kill"'';
"super + f" = ''${i3-msg} "fullscreen toggle"'';
# Screen management
"super + control + l" = ''${i3-msg} "move workspace to output right"'';
"super + control + h" = ''${i3-msg} "move workspace to output left"'';
# Window layouts and tiling
"super + {i,v}" = ''${i3-msg} "split {h,v}"'';
"super + {s,t,e}" =
''${i3-msg} "layout {stacking,tabbed,toggle split}"'';
"super + shift + space" = ''${i3-msg} "floating toggle"'';
"super + control + space" = ''${i3-msg} "focus mode_toggle"'';
"super + a" = ''${i3-msg} "focus parent"'';
# Launch terminal
"super + Return" = ''
${i3-msg} "exec --no-startup-id ${config.terminal}; workspace ${
workspaces."2"
}; layout tabbed"'';
# Restart and reload
"super + shift + {c,r}" = ''${i3-msg} "{reload,restart}"'';
"super + shift + q" = ''
${pkgs.i3}/bin/i3-nagbar -t warning -m "Exit i3?" -B "Yes, exit i3" "${i3-msg} exit"'';
# Resize
"super + r : {h,j,k,l}" =
''${i3-msg} "resize {shrink,grow} width 10px or 10 ppt"'';
"super + r : {j,k}" =
''${i3-msg} "resize {shrink,grow} height 10px or 10 ppt"'';
} // (
# Bind navigation by number
let
bindWorkspace = num: workspace:
lib.attrsets.nameValuePair ("super + ${num}")
(''${i3-msg} "workspace ${workspace}"'');
in lib.mapAttrs' bindWorkspace workspaces
) // (
# Bind move container to workspace by number
let
bindWorkspace = num: workspace:
lib.attrsets.nameValuePair ("super + shift +${num}") (''
${i3-msg} "move container to workspace ${workspace}; workspace ${workspace}"'');
in lib.mapAttrs' bindWorkspace workspaces
);
programs.fish.functions = {
update-lock-screen = lib.mkIf config.services.xserver.enable {
description = "Update lockscreen with wallpaper";
@ -204,20 +275,17 @@ in {
};
lockScreenCommand =
"${pkgs.betterlockscreen}/bin/betterlockscreen --lock --display 1 --blur 0.5 --span";
# Ref: https://github.com/betterlockscreen/betterlockscreen/blob/next/system/betterlockscreen%40.service
systemd.services.lock = {
enable = config.services.xserver.enable;
description = "Lock the screen before suspend";
description = "Lock the screen on resume from suspend";
before = [ "sleep.target" "suspend.target" ];
serviceConfig = {
User = config.user;
Type = "simple";
Environment = "DISPLAY=:0";
TimeoutSec = "infinity";
ExecStart = config.lockScreenCommand;
ExecStart = lockCmd;
ExecStartPost = "${pkgs.coreutils-full}/bin/sleep 1";
};
wantedBy = [ "sleep.target" "suspend.target" ];

View File

@ -1,51 +0,0 @@
{ config, pkgs, ... }: {
home-manager.users.${config.user} = {
services.sxhkd = {
enable = true;
keybindings = {
# Adjust screen brightness (TODO: replace with pkgs.light?)
"shift + {F11,F12}" = ''
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 {- 30,+ 30} && sleep 1; \\
${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 {- 30,+ 30}
'';
"XF86MonBrightness{Down,Up}" = ''
${pkgs.ddcutil}/bin/ddcutil --display 1 setvcp 10 {- 30,+ 30} && sleep 1; \\
${pkgs.ddcutil}/bin/ddcutil --display 2 setvcp 10 {- 30,+ 30}
'';
# Media controls
"XF86Audio{Play,Stop,Next,Prev}" =
"${pkgs.playerctl}/bin/playerctl {play-pause,stop,next,previous}";
# Toggle bar
"super + b" = config.toggleBarCommand;
# Launchers
"super + space" = config.launcherCommand;
"super + shift + s" = config.systemdSearch;
"super + shift + a" = config.audioSwitchCommand;
"alt + Tab" = config.altTabCommand;
"super + shift + period" = config.powerCommand;
"super + shift + m" = config.brightnessCommand;
"super + c" = config.calculatorCommand;
"super + shift + x" = config.lockScreenCommand;
"super + alt + h" =
"${config.terminal} sh -c '${pkgs.home-manager}/bin/home-manager switch --flake ${config.dotfilesPath}#${config.networking.hostName} || read'";
"super + alt + r" =
"${config.terminal} sh -c 'doas nixos-rebuild switch --flake ${config.dotfilesPath}#${config.networking.hostName} || read'";
};
};
xsession.windowManager.i3.config.startup = [{
command = "pkill sxhkd; sxhkd";
always = true;
notification = false;
}];
};
}

View File

@ -1,6 +1,6 @@
{ config, pkgs, lib, ... }: {
config = lib.mkIf config.services.xserver.enable {
config = lib.mkIf (pkgs.stdenv.isLinux && config.services.xserver.enable) {
home-manager.users.${config.user} = {
services.picom = {

View File

@ -1,6 +1,6 @@
{ config, pkgs, lib, ... }: {
config = lib.mkIf config.services.xserver.enable {
config = lib.mkIf (pkgs.stdenv.isLinux && config.services.xserver.enable) {
toggleBarCommand = "polybar-msg cmd toggle";

View File

@ -8,10 +8,11 @@ in {
imports = [ ./rofi/power.nix ./rofi/brightness.nix ];
config = lib.mkIf config.services.xserver.enable {
config = lib.mkIf (pkgs.stdenv.isLinux && config.services.xserver.enable) {
# Set the Rofi-Systemd terminal for viewing logs
environment.sessionVariables.ROFI_SYSTEMD_TERM = config.terminal;
environment.sessionVariables.ROFI_SYSTEMD_TERM =
lib.mkIf config.kitty.enable "${pkgs.kitty}/bin/kitty";
home-manager.users.${config.user} = {
@ -23,13 +24,6 @@ in {
programs.rofi = {
enable = true;
cycle = true;
extraConfig = {
show-icons = true;
kb-cancel = "Escape,Super+space";
modi = "window,run,ssh,emoji,calc,systemd";
sort = true;
# levenshtein-sort = true;
};
location = "center";
pass = { };
plugins = [ pkgs.rofi-calc pkgs.rofi-emoji pkgs.rofi-systemd ];
@ -65,7 +59,7 @@ in {
border = mkLiteral "0px";
border-radius = mkLiteral "0px";
border-color = mkLiteral config.theme.colors.base04;
children = map mkLiteral [ "inputbar" "listview" ];
children = map mkLiteral [ "inputbar" "message" "listview" ];
spacing = mkLiteral "10px";
padding = mkLiteral "10px";
};
@ -149,9 +143,15 @@ in {
};
};
terminal = config.terminal;
xoffset = 0;
yoffset = -20;
extraConfig = {
show-icons = true;
kb-cancel = "Escape,Super+space";
modi = "window,run,ssh,emoji,calc,systemd";
sort = true;
# levenshtein-sort = true;
};
};
home.file.".local/share/rofi/themes" = {

0
modules/nixos/graphical/rofi/brightness.nix Normal file → Executable file
View File

0
modules/nixos/graphical/rofi/power.nix Normal file → Executable file
View File

View File

@ -1,25 +0,0 @@
{ config, lib, ... }: {
config = lib.mkIf config.gui.enable {
programs.sway = {
enable = true;
package = null; # Use home-manager Sway instead
};
};
home-manager.users.${config.user} = {
wayland.windowManager.sway = {
enable = true;
config =
config.home-manager.users.${config.user}.xsession.windowManager.i3.config;
};
};
# TODO: swaybg
# TODO: swaylock
}

5
overlays/age.nix Normal file
View File

@ -0,0 +1,5 @@
# Pin age because it is failing to build
inputs: _final: prev: {
age = prev.age.overrideAttrs (old: { src = inputs.age; });
}

View File

@ -22,7 +22,7 @@ let
'';
in {
caddy-cloudflare = prev.buildGo118Module {
caddy-cloudflare = prev.buildGo120Module {
pname = "caddy-cloudflare";
version = prev.caddy.version;
runVend = true;
@ -31,7 +31,7 @@ in {
src = prev.caddy.src;
vendorSha256 = "sha256:CrHqJcJ0knX+txQ5qvzW4JrU8vfi3FO3M/xtislIC1M=";
vendorSha256 = "sha256:mwIsWJYKuEZpOU38qZOG1LEh4QpK4EO0/8l4UGsroU8=";
overrideModAttrs = (_: {
preBuild = ''

View File

@ -4,14 +4,17 @@ inputs: _final: prev: {
news = prev.fetchNextcloudApp {
url = inputs.nextcloud-news.outPath;
sha256 = inputs.nextcloud-news.narHash;
license = "agpl3Plus";
};
external = prev.fetchNextcloudApp {
url = inputs.nextcloud-external.outPath;
sha256 = inputs.nextcloud-external.narHash;
license = "agpl3Plus";
};
cookbook = prev.fetchNextcloudApp {
url = inputs.nextcloud-cookbook.outPath;
sha256 = inputs.nextcloud-cookbook.narHash;
license = "agpl3Plus";
};
};

15
overlays/proton-ge.nix Normal file
View File

@ -0,0 +1,15 @@
# Adapted from:
# https://github.com/Shawn8901/nix-configuration/blob/182a45a6b193143ff7ff8e78bb66f7b869ea48d4/packages/proton-ge-custom/default.nix
# Based on: https://github.com/NixOS/nixpkgs/issues/73323
inputs: _final: prev: {
proton-ge-custom = prev.stdenv.mkDerivation (finalAttrs: rec {
name = "proton-ge-custom";
version = "0.1"; # Made up
src = inputs.proton-ge;
installPhase = ''
mkdir -p $out/bin
cp -r ${src}/* -t $out/bin/
'';
});
}