nix-managed-macbook/home.nix

156 lines
3.4 KiB
Nix
Raw Normal View History

2022-09-25 00:54:06 +05:30
{ config, pkgs, ... }:
{
# Home Manager needs a bit of information about you and the
# paths it should manage.
home.username = "abhinav";
home.homeDirectory = "/Users/abhinav";
# This value determines the Home Manager release that your
# configuration is compatible with. This helps avoid breakage
# when a new Home Manager release introduces backwards
# incompatible changes.
#
# You can update Home Manager without changing this value. See
# the Home Manager release notes for a list of state version
# changes in each release.
home.stateVersion = "22.05";
# Let Home Manager install and manage itself.
programs.home-manager.enable = true;
programs.htop = {
enable = true;
settings = {
hide_kernel_threads = true;
hide_threads = true;
hide_userland_threads = true;
highlight_base_name = true;
show_program_path = false;
tree_view = true;
};
};
programs.exa = {
enable = true;
enableAliases = true;
};
programs.direnv = {
enable = true;
nix-direnv = { enable = true; };
};
programs.nix-index = {
enable = true;
enableFishIntegration = true;
};
programs.just = {
enable = true;
enableFishIntegration = true;
};
programs.fish = {
enable = true;
shellAliases = {
j = "just";
g = "git";
2022-09-26 10:26:44 +05:30
l = "bat";
2022-09-25 00:54:06 +05:30
};
plugins = [
{
name = "foreign-env";
src = pkgs.fetchFromGitHub {
owner = "oh-my-fish";
repo = "plugin-foreign-env";
rev = "b3dd471bcc885b597c3922e4de836e06415e52dd";
sha256 = "00xqlyl3lffc5l0viin1nyp819wf81fncqyz87jx8ljjdhilmgbs";
};
}
{
name = "agnoster";
src = pkgs.fetchFromGitHub {
owner = "oh-my-fish";
repo = "theme-agnoster";
rev = "43860ce1536930bca689470e26083b0a5b7bd6ae";
sha256 = "16k94hz3s6wayass6g1lhlcjmbpf2w8mzx90qrrqp120h80xwp25";
};
}
];
interactiveShellInit = ''
set EDITOR micro
'';
shellInit = ''
# nix
if test -e /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh
fenv source /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh
end
# home-manager
if test -e $HOME/.nix-profile/etc/profile.d/hm-session-vars.sh
fenv source $HOME/.nix-profile/etc/profile.d/hm-session-vars.sh
end
'';
2022-09-26 10:26:44 +05:30
};
2022-09-25 00:54:06 +05:30
2022-09-26 10:26:44 +05:30
programs.bat = {
enable = true;
config = {
italic-text = "always";
paging = "always";
tabs = "2";
theme = "DarkNeon";
};
};
programs.fzf = {
enable = true;
enableFishIntegration = true;
fileWidgetCommand = "fd --type f --no-ignore";
historyWidgetOptions = [ "--reverse" "--sort" "--exact" ];
2022-09-25 00:54:06 +05:30
};
programs.micro = {
enable = true;
settings = {
2022-09-25 18:33:56 +05:30
colorscheme = "gotham";
tabsize = 2;
tabstospaces = true;
autoindent = true;
colorcolumn = 100;
diffgutter = true;
hlsearch = true;
mkparents = true;
savecursor = true;
2022-09-26 10:26:44 +05:30
softwrap = true;
2022-09-25 18:33:56 +05:30
manipulator = true;
2022-09-25 00:54:06 +05:30
};
};
# Packages to install
home.packages = with pkgs; [
# pkgs is the set of all packages in the default home.nix implementation
cloc
cloudflare-dyndns
coreutils
delta
entr
gitui
graphviz-nox
haskellPackages.cabal-plan
haskellPackages.graphmod
httpie
mosh
micro
niv
nixfmt
statix
tree
];
}