[ubuntu] Onboard an ubuntu config.

This commit is contained in:
jmug
2026-11-18 22:28:25 -08:00
parent 2df0a3a2f9
commit 61e1108ff7
10 changed files with 612 additions and 4 deletions
+6 -1
View File
@@ -1,4 +1,4 @@
{ lib, config, ... }: {
{ lib, config, pkgs, ... }: {
options.ghostty.font-size = lib.mkOption {
# Using a string to support floats.
type = lib.types.str;
@@ -21,6 +21,11 @@
# This is the default to open the configuration
# I type this by accident way to frequently...
keybind = ctrl+comma=unbind
'' + lib.optionalString pkgs.stdenv.hostPlatform.isLinux ''
# Support configs where Meta+C/V is turned into Ctrl+Insert/Shift+Insert.
keybind = ctrl+insert=copy_to_clipboard
keybind = shift+insert=paste_from_clipboard
'';
};
config.home.file.".config/ghostty/themes/PaleNight" = {
+28
View File
@@ -0,0 +1,28 @@
# Glue for running Home Manager on Ubuntu.
{ config, ... }: {
# Nix-installed apps/fonts/terminfo visible to the host system.
targets.genericLinux.enable = true;
# GUI apps come from apt/flatpak, so nix packages don't need host GPU drivers.
targets.genericLinux.gpu.enable = false;
# Things the stock ~/.profile and ~/.bashrc provided that are still needed.
# ~/.local/bin: native installers put binaries here.
home.sessionPath = [ "$HOME/.local/bin" "$HOME/bin" ];
programs.zsh = {
# Keep ~/.zshrc etc. in $HOME
dotDir = config.home.homeDirectory;
# Ubuntu's /etc/zsh/zshrc runs compinit; Home Manager runs it again.
envExtra = ''
skip_global_compinit=1
'';
# zsh doesn't read /etc/profile, so /etc/profile.d/* (nix-daemon, /snap/bin,
# flatpak XDG_DATA_DIRS, vte) would be skipped for login shells.
profileExtra = ''
emulate sh -c '. /etc/profile'
'';
};
# GNOME's gcr-ssh-agent already owns SSH_AUTH_SOCK; don't start another agent.
services.ssh-agent.enable = false;
}