home.nix
changeset 0 0bfc10663494
child 1 4a1d6dba7fe5
child 2 a71813720fef
equal deleted inserted replaced
-1:000000000000 0:0bfc10663494
       
     1 { config, pkgs, ... }:
       
     2 
       
     3 let
       
     4 
       
     5   my-nur = import /repos/NixOS/nur-packages {
       
     6     inherit pkgs;
       
     7   };
       
     8 
       
     9 in
       
    10 
       
    11 {
       
    12   home.file."bin/idea" = {
       
    13     text = ''
       
    14       #!${pkgs.bash}/bin/bash
       
    15       export JAVA_HOME=${pkgs.jetbrains.jdk}
       
    16       exec /opt/idea-IC-201.7223.91/bin/idea.sh
       
    17     '';
       
    18     executable = true;
       
    19   };
       
    20 
       
    21   home.packages = [
       
    22     my-nur.guilt
       
    23     pkgs.nix-direnv
       
    24   ];
       
    25 
       
    26   programs.bash = {
       
    27     enable = true;
       
    28     initExtra = ''
       
    29       export LC_CTYPE=cs_CZ.UTF-8
       
    30       unset LC_ALL
       
    31       eval `dircolors $HOME/.dir_colors`
       
    32       eval `keychain --eval --agents ssh,gpg`
       
    33       PS1='[\u@\h \W \D{%F %T}]\n\$ '
       
    34     '';
       
    35     sessionVariables = {
       
    36       HGEDITOR="~/bin/hgeditor";
       
    37     };
       
    38   };
       
    39 
       
    40   # Let Home Manager install and manage itself.
       
    41   programs.home-manager.enable = true;
       
    42 
       
    43   programs.direnv = {
       
    44     enable = true;
       
    45     enableBashIntegration = true;
       
    46     stdlib = ''
       
    47       if [ -f ~/.nix-profile/share/nix-direnv/direnvrc ]; then
       
    48         source ~/.nix-profile/share/nix-direnv/direnvrc
       
    49       fi
       
    50     '';
       
    51   };
       
    52 
       
    53   services.gpg-agent = {
       
    54     enable = true;
       
    55     pinentryFlavor = "gtk2";
       
    56     verbose = true;
       
    57   };
       
    58 
       
    59   # This value determines the Home Manager release that your
       
    60   # configuration is compatible with. This helps avoid breakage
       
    61   # when a new Home Manager release introduces backwards
       
    62   # incompatible changes.
       
    63   #
       
    64   # You can update Home Manager without changing this value. See
       
    65   # the Home Manager release notes for a list of state version
       
    66   # changes in each release.
       
    67   home.stateVersion = "20.03";
       
    68 }
       
    69 
       
    70 # vim: ts=2 sw=2 et