Compare commits
46 commits
d9eeeb5b52
...
0d37843140
| Author | SHA1 | Date | |
|---|---|---|---|
| 0d37843140 | |||
| be62fe7e4d | |||
| 7b9263f9ed | |||
| 8febd2fdbe | |||
| 1c746cd2bb | |||
| da72154eb8 | |||
| 94ead402cc | |||
| 8d63a2276e | |||
| eab7092f5d | |||
| 256feb9e2f | |||
| d245a1423b | |||
| 8056ca5ad5 | |||
| fbaf6ea860 | |||
| d450f77e21 | |||
| 6f05315dda | |||
| 605abffcc8 | |||
| c4289b480c | |||
| e1c037e393 | |||
| f8487b23dc | |||
| b8ac79e845 | |||
| 56da44d85b | |||
| 54dc2a97fc | |||
| 20bf05ccb8 | |||
| b8d1fc917b | |||
| 8bafea77f5 | |||
| c8d0e2ad97 | |||
| 570349e80f | |||
| 65a8f7c481 | |||
| c856933803 | |||
| b52e56ed08 | |||
| 27564cad42 | |||
| 32ec402ad0 | |||
| cc331b73c7 | |||
| 830e7bb865 | |||
| 7f857ab661 | |||
| 8ad02dd74d | |||
| 249ee14d39 | |||
| 9b71708e3a | |||
| ca4fac3c54 | |||
| 6a8f93df1f | |||
| 42ab12179e | |||
| 3a1ccea142 | |||
| c01f657e8d | |||
| bd69e28143 | |||
| 516df86b3f | |||
| 28187c3b8f |
217 changed files with 482 additions and 165 deletions
24
flake.lock
generated
24
flake.lock
generated
|
|
@ -70,11 +70,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1696343447,
|
||||
"narHash": "sha256-B2xAZKLkkeRFG5XcHHSXXcP7To9Xzr59KXeZiRf4vdQ=",
|
||||
"lastModified": 1698579227,
|
||||
"narHash": "sha256-KVWjFZky+gRuWennKsbo6cWyo7c/z/VgCte5pR9pEKg=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "c9afaba3dfa4085dbd2ccb38dfade5141e33d9d4",
|
||||
"rev": "f76e870d64779109e41370848074ac4eaa1606ec",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -131,11 +131,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1698250431,
|
||||
"narHash": "sha256-qs2gTeH4wpnWPO6Oi6sOhp2IhG0i0DzcnrJxIY3/CP8=",
|
||||
"lastModified": 1698670511,
|
||||
"narHash": "sha256-jQIu3UhBMPHXzVkHQO1O2gg8SVo5lqAVoC6mOaLQcLQ=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "09587fbbc6a669f7725613e044c2577dc5d43ab5",
|
||||
"rev": "8e5416b478e465985eec274bc3a018024435c106",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -147,11 +147,11 @@
|
|||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1698134075,
|
||||
"narHash": "sha256-foCD+nuKzfh49bIoiCBur4+Fx1nozo+4C/6k8BYk4sg=",
|
||||
"lastModified": 1698611440,
|
||||
"narHash": "sha256-jPjHjrerhYDy3q9+s5EAsuhyhuknNfowY6yt6pjn9pc=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "8efd5d1e283604f75a808a20e6cde0ef313d07d4",
|
||||
"rev": "0cbe9f69c234a7700596e943bfae7ef27a31b735",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -163,11 +163,11 @@
|
|||
},
|
||||
"nur": {
|
||||
"locked": {
|
||||
"lastModified": 1698317227,
|
||||
"narHash": "sha256-jzSJjjxJr/IPvoPSWB1ZobmlAKku6eeggh9ffGV7Sig=",
|
||||
"lastModified": 1698745553,
|
||||
"narHash": "sha256-Fdip7ewCtZTjOu7ATDFUAy3OqrgcyvzDElLXhr4YmmI=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"rev": "32a38be31067b0a2f4919fd9e7a49bbefc34d25f",
|
||||
"rev": "dfbf198236d40e9741db76936088f05107e19013",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
let
|
||||
defaultModules = [
|
||||
# Include generic settings
|
||||
"${self}/home"
|
||||
"${self}/modules/home"
|
||||
{
|
||||
# Basic user information defaults
|
||||
home.username = lib.mkDefault "ambroisie";
|
||||
|
|
|
|||
|
|
@ -13,9 +13,7 @@ let
|
|||
];
|
||||
}
|
||||
# Include generic settings
|
||||
"${self}/modules"
|
||||
# Include bundles of settings
|
||||
"${self}/profiles"
|
||||
"${self}/modules/nixos"
|
||||
];
|
||||
|
||||
buildHost = name: system: lib.nixosSystem {
|
||||
|
|
|
|||
|
|
@ -1,56 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./aliases
|
||||
./atuin
|
||||
./bat
|
||||
./bitwarden
|
||||
./bluetooth
|
||||
./calibre
|
||||
./comma
|
||||
./dircolors
|
||||
./direnv
|
||||
./discord
|
||||
./documentation
|
||||
./feh
|
||||
./firefox
|
||||
./flameshot
|
||||
./fzf
|
||||
./gammastep
|
||||
./gdb
|
||||
./git
|
||||
./gpg
|
||||
./gtk
|
||||
./htop
|
||||
./jq
|
||||
./mail
|
||||
./mpv
|
||||
./nix
|
||||
./nix-index
|
||||
./nixpkgs
|
||||
./nm-applet
|
||||
./packages
|
||||
./pager
|
||||
./power-alert
|
||||
./secrets
|
||||
./ssh
|
||||
./terminal
|
||||
./tmux
|
||||
./udiskie
|
||||
./vim
|
||||
./wm
|
||||
./x
|
||||
./xdg
|
||||
./zathura
|
||||
./zsh
|
||||
];
|
||||
|
||||
# First sane reproducible version
|
||||
home.stateVersion = "20.09";
|
||||
|
||||
# Who am I?
|
||||
home.username = "ambroisie";
|
||||
|
||||
# Start services automatically
|
||||
systemd.user.startServices = "sd-switch";
|
||||
}
|
||||
|
|
@ -17,11 +17,13 @@
|
|||
|
||||
services.gpg-agent.enable = lib.mkForce false;
|
||||
|
||||
# I use scripts that use the passthrough sequence often on this host
|
||||
my.home.tmux.enablePassthrough = true;
|
||||
my.home = {
|
||||
tmux = {
|
||||
# I use scripts that use the passthrough sequence often on this host
|
||||
enablePassthrough = true;
|
||||
|
||||
programs.tmux.extraConfig = ''
|
||||
# Setup 24-bit color explicitly, as the default terminfo entry does not
|
||||
set-option -sa terminal-overrides ",xterm-256color:Tc"
|
||||
'';
|
||||
# HTerm uses `xterm-256color` as its `$TERM`, so use that here
|
||||
trueColorTerminals = [ "xterm-256color" ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@
|
|||
./secrets
|
||||
./services.nix
|
||||
./sound.nix
|
||||
./system.nix
|
||||
];
|
||||
|
||||
# Set your time zone.
|
||||
|
|
|
|||
|
|
@ -9,8 +9,6 @@
|
|||
gtk.enable = true;
|
||||
# Laptop specific configuration
|
||||
laptop.enable = true;
|
||||
# Printers are hell, but so is the unability to print
|
||||
printing.enable = true;
|
||||
# i3 configuration
|
||||
wm.windowManager = "i3";
|
||||
# X configuration
|
||||
|
|
|
|||
10
hosts/nixos/aramis/system.nix
Normal file
10
hosts/nixos/aramis/system.nix
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
# Core system configuration
|
||||
{ ... }:
|
||||
{
|
||||
my.system = {
|
||||
# Printers are hell, but so is the unability to print
|
||||
printing = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -9,6 +9,7 @@
|
|||
./networking.nix
|
||||
./secrets
|
||||
./services.nix
|
||||
./system.nix
|
||||
./users.nix
|
||||
];
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,12 @@
|
|||
{ ... }:
|
||||
{
|
||||
my.home = {
|
||||
# Allow using 24bit color when SSH-ing from various clients
|
||||
tmux.trueColorTerminals = [
|
||||
# My usual terminal, e.g: on laptop
|
||||
"alacritty"
|
||||
];
|
||||
|
||||
# Always start a tmux session when opening a shell session
|
||||
zsh.launchTmux = true;
|
||||
};
|
||||
|
|
|
|||
12
hosts/nixos/porthos/system.nix
Normal file
12
hosts/nixos/porthos/system.nix
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
# Core system configuration
|
||||
{ ... }:
|
||||
{
|
||||
my.system = {
|
||||
nix = {
|
||||
cache = {
|
||||
# This server is the one serving the cache, don't try to query it
|
||||
selfHosted = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -24,4 +24,10 @@ in
|
|||
# (any -> value)
|
||||
# [ any ]
|
||||
mapFilter = pred: f: attrs: filter pred (map f attrs);
|
||||
|
||||
# Transform a nullable value into a list of zero/one element.
|
||||
#
|
||||
# nullableToList ::
|
||||
# (nullable a) -> [ a ]
|
||||
nullableToList = x: if x != null then [ x ] else [ ];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,29 +1,56 @@
|
|||
{ config, inputs, lib, ... }:
|
||||
let
|
||||
actualPath = [ "home-manager" "users" config.my.user.name "my" "home" ];
|
||||
aliasPath = [ "my" "home" ];
|
||||
|
||||
cfg = config.my.user.home;
|
||||
in
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
inputs.home-manager.nixosModules.home-manager # enable home-manager options
|
||||
(lib.mkAliasOptionModule aliasPath actualPath) # simplify setting home options
|
||||
./aliases
|
||||
./atuin
|
||||
./bat
|
||||
./bitwarden
|
||||
./bluetooth
|
||||
./calibre
|
||||
./comma
|
||||
./dircolors
|
||||
./direnv
|
||||
./discord
|
||||
./documentation
|
||||
./feh
|
||||
./firefox
|
||||
./flameshot
|
||||
./fzf
|
||||
./gammastep
|
||||
./gdb
|
||||
./git
|
||||
./gpg
|
||||
./gtk
|
||||
./htop
|
||||
./jq
|
||||
./mail
|
||||
./mpv
|
||||
./nix
|
||||
./nix-index
|
||||
./nixpkgs
|
||||
./nm-applet
|
||||
./packages
|
||||
./pager
|
||||
./power-alert
|
||||
./secrets
|
||||
./ssh
|
||||
./terminal
|
||||
./tmux
|
||||
./udiskie
|
||||
./vim
|
||||
./wm
|
||||
./x
|
||||
./xdg
|
||||
./zathura
|
||||
./zsh
|
||||
];
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
home-manager = {
|
||||
# Not a fan of out-of-directory imports, but this is a good exception
|
||||
users.${config.my.user.name} = import ../../home;
|
||||
# First sane reproducible version
|
||||
home.stateVersion = "20.09";
|
||||
|
||||
# Nix Flakes compatibility
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
# Who am I?
|
||||
home.username = "ambroisie";
|
||||
|
||||
# Forward inputs to home-manager configuration
|
||||
extraSpecialArgs = {
|
||||
inherit inputs;
|
||||
};
|
||||
};
|
||||
};
|
||||
# Start services automatically
|
||||
systemd.user.startServices = "sd-switch";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -33,13 +33,10 @@ in
|
|||
enable = true;
|
||||
|
||||
package = pkgs.firefox.override {
|
||||
cfg = {
|
||||
enableTridactylNative = cfg.tridactyl.enable;
|
||||
};
|
||||
|
||||
extraNativeMessagingHosts = with pkgs; ([ ]
|
||||
nativeMessagingHosts = ([ ]
|
||||
++ lib.optional cfg.tridactyl.enable pkgs.tridactyl-native
|
||||
# Watch videos using mpv
|
||||
++ lib.optional cfg.ff2mpv.enable ambroisie.ff2mpv-go
|
||||
++ lib.optional cfg.ff2mpv.enable pkgs.ambroisie.ff2mpv-go
|
||||
);
|
||||
};
|
||||
|
||||
|
|
@ -11,6 +11,19 @@ in
|
|||
enable = my.mkDisableOption "tmux terminal multiplexer";
|
||||
|
||||
enablePassthrough = mkEnableOption "tmux DCS passthrough sequence";
|
||||
|
||||
trueColorTerminals = mkOption {
|
||||
type = with types; listOf str;
|
||||
default = lib.my.nullableToList config.my.home.terminal.program;
|
||||
defaultText = ''
|
||||
`[ config.my.home.terminal.program ]` if it is non-null, otherwise an
|
||||
empty list.
|
||||
'';
|
||||
example = [ "xterm-256color" ];
|
||||
description = ''
|
||||
$TERM values which should be considered to always support 24-bit color.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config.programs.tmux = lib.mkIf cfg.enable {
|
||||
|
|
@ -75,6 +88,14 @@ in
|
|||
set -g allow-passthrough on
|
||||
''
|
||||
}
|
||||
|
||||
# Force 24-bit color for each relevant $TERM
|
||||
${
|
||||
let
|
||||
mkTcFlag = term: ''set -as terminal-features ",${term}:RGB"'';
|
||||
in
|
||||
lib.concatMapStringsSep "\n" mkTcFlag cfg.trueColorTerminals
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
@ -67,7 +67,7 @@ in
|
|||
nvim-lspconfig # Easy LSP configuration
|
||||
lsp-format-nvim # Simplified formatting configuration
|
||||
lsp_lines-nvim # Show diagnostics *over* regions
|
||||
null-ls-nvim # LSP integration for linters and formatters
|
||||
none-ls-nvim # LSP integration for linters and formatters
|
||||
nvim-treesitter.withAllGrammars # Better highlighting
|
||||
nvim-treesitter-textobjects # More textobjects
|
||||
nvim-ts-context-commentstring # Comment string in nested language blocks
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue