System/home-manager/common/programs/core.nix

79 lines
2.1 KiB
Nix

{ config, lib, pkgs, inputs, ... }:
with lib; {
config = mkMerge [
(mkIf config.nathan.programs.util.core {
home.packages = with pkgs; [
# Rust rewrites of common shell utilites
exa
bat
fd
sd
du-dust
ripgrep
ripgrep-all
hyperfine
dogdns
duf
xcp
# User friendly cut
choose
# Man but terse
tealdeer
# rsync for _The Cloud_ :tm:
rclone
];
# Configure tmux
programs.tmux = {
enable = true;
aggressiveResize = true;
extraConfig = if pkgs.stdenv.isLinux then ''
set -g default-terminal "tmux-256color"
set -ag terminal-overrides ",xterm-256color:RGB"
set-option -g status-interval 1
set-option -g automatic-rename on
set-option -g automatic-rename-format '#{pane_current_path}: #{pane_current_command}'
'' else ''
set -g default-terminal "screen-256color"
set -ag terminal-overrides ",xterm-256color:RGB"
set-option -g status-interval 1
set-option -g automatic-rename on
set-option -g automatic-rename-format '#{pane_current_path}: #{pane_current_command}'
'';
};
# Configure btop
programs.btop = { enable = true; };
})
(mkIf config.nathan.programs.util.productivity {
home.packages = with pkgs; [
tokei
# Spell check
hunspell
hunspellDicts.en-us
# CLI Markdown renderer
glow
# Command line file manager
broot
# Much better curl
httpie
# CLI spreadsheets
visidata
# Cheatsheet manager
cheat
# Ping with a graph
gping
# Pandoc for documentation
pandoc
# Tmate for pair programming
tmate
];
})
(mkIf config.nathan.programs.util.json {
#########################
## JSON Utilities
#########################
programs.jq = { enable = true; };
home.packages = with pkgs; [ jc fx ];
})
];
}