about summary refs log tree commit diff
path: root/nix/profiles
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--nix/profiles/home-manager/dev.nix38
-rw-r--r--nix/profiles/home-manager/git.nix76
-rw-r--r--nix/profiles/home-manager/mac.nix4
-rw-r--r--nix/profiles/home-manager/media.nix35
-rw-r--r--nix/profiles/home-manager/personal.nix8
-rw-r--r--nix/profiles/home-manager/shell.nix112
-rw-r--r--nix/profiles/home-manager/ssh.nix44
7 files changed, 0 insertions, 317 deletions
diff --git a/nix/profiles/home-manager/dev.nix b/nix/profiles/home-manager/dev.nix
deleted file mode 100644
index 02eb566..0000000
--- a/nix/profiles/home-manager/dev.nix
+++ /dev/null
@@ -1,38 +0,0 @@
-{ pkgs, config, ... }: {
-
-  programs.go = {
-    enable = true;
-    goPath = ".local/share/pkg.go";
-    goBin = ".local/bin.go";
-    goPrivate = [ "github.rbx.com/*" "github.com/fcuny/*" "git.fcuny.net/*" ];
-  };
-
-  home.packages = with pkgs; [
-    # go
-    go-tools
-    golangci-lint
-    gopls
-    delve
-
-    # docker
-    dive # explore layers in docker images
-
-    # shell
-    shellcheck
-
-    # ops
-    google-cloud-sdk
-    kubectl
-    tfswitch
-  ];
-
-  home.sessionPath = [ config.home.sessionVariables.GOBIN ];
-
-  home.sessionVariables = with config.xdg; {
-    IPYTHONDIR = "${cacheHome}/ipython";
-    PIP_LOG = "${cacheHome}/pip/pip.log";
-    PYLINTHOME = "${cacheHome}/pylint";
-    PYTHON_EGG_CACHE = "${cacheHome}/python-eggs";
-    MYPY_CACHE_DIR = "${cacheHome}/mypy";
-  };
-}
diff --git a/nix/profiles/home-manager/git.nix b/nix/profiles/home-manager/git.nix
deleted file mode 100644
index cba49f9..0000000
--- a/nix/profiles/home-manager/git.nix
+++ /dev/null
@@ -1,76 +0,0 @@
-{ pkgs, config, lib, ... }: {
-  programs.git = {
-    enable = true;
-    userName = "Franck Cuny";
-
-    aliases = {
-      amend = "commit --amend";
-      ll = ''log --pretty="format:%h %G? %aN  %s"'';
-    };
-
-    includes = [
-      {
-        condition = "hasconfig:remote.*.url:git@github.rbx.com:**";
-        path = pkgs.writeText "finsitGitConfig"
-          (lib.generators.toGitINI { user.email = "fcuny@roblox.com"; });
-      }
-      {
-        condition = "hasconfig:remote.*.url:git@github.com:Roblox/**";
-        path = pkgs.writeText "finsitGitConfig"
-          (lib.generators.toGitINI { user.email = "fcuny@roblox.com"; });
-      }
-    ];
-
-    extraConfig = {
-      core.whitespace = "trailing-space,space-before-tab";
-      color.ui = "true";
-
-      # abort if the remote branch does not match the local one
-      push.default = "simple";
-
-      # https://adamj.eu/tech/2024/01/18/git-improve-diff-histogram/
-      diff.algorithm = "histogram";
-
-      init.defaultBranch = "main";
-
-      pull.rebase = true;
-      rebase = {
-        # Automatically create a temporary stash entry before the
-        # operation begins, and apply it after the operation ends.
-        autoStash = true;
-        # Print a warning if some commits are removed
-        missingCommitsCheck = "warn";
-      };
-
-      branch.autosetuprebase = "remote";
-      branch.sort = "authordate";
-
-      commit.template = "${config.xdg.dataHome}/git/commit.template";
-
-      url = {
-        "ssh://git@github.rbx.com/" = {
-          insteadOf = "https://github.rbx.com/";
-        };
-      };
-    };
-
-    ignores = [ "*~" ".envrc" ".direnv" "__pycache__" ];
-  };
-
-  xdg.dataFile."git/commit.template".source =
-    pkgs.writeText "commit.template" ''
-
-      # (If applied, this commit will...) <subject>
-
-      # Explain why this change is being made
-
-      # --- COMMIT END ---
-      # Remember to
-      #    Use the imperative mood, present tense: `change' not `changed' nor `changes'
-      #    Do not end the subject line with a period
-      #    Use the body to explain what and why vs. how
-      #    Can use multiple lines with "-" for bullet points in body
-    '';
-
-  home.packages = with pkgs; [ gitAndTools.pre-commit git-credential-manager ];
-}
diff --git a/nix/profiles/home-manager/mac.nix b/nix/profiles/home-manager/mac.nix
deleted file mode 100644
index 045441a..0000000
--- a/nix/profiles/home-manager/mac.nix
+++ /dev/null
@@ -1,4 +0,0 @@
-{ ... }: {
-  imports = [ ./dev.nix ./git.nix ./shell.nix ./ssh.nix ];
-  xdg.enable = false;
-}
diff --git a/nix/profiles/home-manager/media.nix b/nix/profiles/home-manager/media.nix
deleted file mode 100644
index d3351fa..0000000
--- a/nix/profiles/home-manager/media.nix
+++ /dev/null
@@ -1,35 +0,0 @@
-{ ... }: {
-  programs.yt-dlp = {
-    enable = true;
-
-    extraConfig = ''
-      # Do not overwrite files
-      --no-overwrites
-
-      # Add metadata to the video files
-      --add-metadata
-
-      # Write video description to a .description file
-      --write-description
-
-      # Restrict filenames to only ASCII characters, and avoid "&" and spaces in filenames
-      --restrict-filenames
-
-      # Select the best audio quality (when extracting audio with -x/--extract-audio)
-      --audio-quality 0
-
-      # Save videos under "~/Movies/WebsiteName/" with the filename "VideoTitle---FormatNote-VideoId.VideoExtension"
-      --output "~/Movies/%(extractor_key)s/%(title)s---%(format_note)s-%(id)s.%(ext)s"
-
-      # Download subtitles for English and French
-      --sub-langs en,fr
-
-      # Embed subtitles in the video (only possible with mp4, webm and mkv files)
-      --embed-subs
-
-      # Download with the best resolution and if possible, in the video format mp4 and audio format m4a.
-      # If the video format isn't mp4 already, it will be converted to mp4
-      --format-sort res,ext:mp4:m4a --recode mp4
-    '';
-  };
-}
diff --git a/nix/profiles/home-manager/personal.nix b/nix/profiles/home-manager/personal.nix
deleted file mode 100644
index 34feca5..0000000
--- a/nix/profiles/home-manager/personal.nix
+++ /dev/null
@@ -1,8 +0,0 @@
-{ ... }: {
-
-  home.stateVersion = "23.05";
-
-  imports = [ ./mac.nix ./media.nix ];
-
-  programs.git = { userEmail = "franck@fcuny.net"; };
-}
diff --git a/nix/profiles/home-manager/shell.nix b/nix/profiles/home-manager/shell.nix
deleted file mode 100644
index bfeeb09..0000000
--- a/nix/profiles/home-manager/shell.nix
+++ /dev/null
@@ -1,112 +0,0 @@
-{ pkgs, config, ... }: {
-
-  home.packages = with pkgs; [
-    # shell utils
-    coreutils
-    direnv
-    dust
-    procs
-    ripgrep
-    tree
-    wget
-
-    # network
-    bandwhich
-
-    # data manipulation
-    jless
-    jq
-    yq
-
-    # encryption
-    age
-
-    # media
-    # mpv - TODO: this is currently broken
-    ffmpeg
-
-    # dicts
-    aspell
-    aspellDicts.en
-    aspellDicts.en-computers
-    aspellDicts.en-science
-
-    # nix related
-    nil
-    nix-direnv
-    nixd
-    nixfmt-classic
-    nixpkgs-fmt
-    nil # nix lsp
-  ];
-
-  xdg = {
-    configFile = {
-      "aspell/config".text = ''
-        local-data-dir ${pkgs.aspell}/lib/aspell
-        data-dir ${pkgs.aspellDicts.en}/lib/aspell
-        personal ${config.xdg.configHome}/aspell/en_US.personal
-        repl ${config.xdg.configHome}/aspell/en_US.repl
-      '';
-    };
-  };
-
-  home.sessionVariables = {
-    EDITOR = "emacsclient -a=";
-    VISUAL = "emacsclient -a=";
-    LESS = "-FRSXM";
-    LESSCHARSET = "utf-8";
-    PAGER = "less";
-    ASPELL_CONF = "conf ${config.xdg.configHome}/aspell/config;";
-    # for some reason, if I don't set this, zsh is picked up and mess up stuff.
-    SHELL = "${pkgs.fish}/bin/fish";
-    # stop bothering me with brew messages
-    HOMEBREW_NO_AUTO_UPDATE = 1;
-  };
-
-  # an alternative to ls
-  programs.eza = {
-    enable = true;
-    icons = "never";
-    enableFishIntegration = false;
-    extraOptions = [
-      "--group-directories-first"
-      "--no-quotes"
-      "--git-ignore"
-      "--icons=never"
-    ];
-  };
-
-  # an alternative to find
-  programs.fd = {
-    enable = true;
-    hidden = true;
-    ignores = [ ".git/" ];
-  };
-
-  programs.direnv = {
-    enable = true;
-    nix-direnv.enable = true;
-    enableZshIntegration = true;
-    config = {
-      global.disable_stdin = true;
-      global.strict_env = true;
-    };
-  };
-
-  programs.fish = {
-    enable = true;
-    interactiveShellInit = ''
-      set fish_greeting ""
-    '';
-
-    shellAbbrs = { ncg = "nix-collect-garbage -d"; };
-    shellAliases = {
-      c = "clear";
-      ls = "eza -l -L=1 --git --color=always --group-directories-first";
-      la = "eza -la --git --color=always --group-directories-first";
-      ll = "eza -la -L=1 --git --color=always --group-directories-first";
-      lt = "eza -aT -L=2 --git --color=always --group-directories-first";
-    };
-  };
-}
diff --git a/nix/profiles/home-manager/ssh.nix b/nix/profiles/home-manager/ssh.nix
deleted file mode 100644
index eebfd71..0000000
--- a/nix/profiles/home-manager/ssh.nix
+++ /dev/null
@@ -1,44 +0,0 @@
-{ ... }:
-{
-  programs.ssh = {
-    enable = true;
-    forwardAgent = true;
-    serverAliveInterval = 60;
-    controlMaster = "auto";
-    controlPersist = "30m";
-    extraConfig = ''
-      IdentityAgent "~/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"
-    '';
-    matchBlocks = {
-      "personal" = {
-        hostname = "github.com";
-        user = "git";
-        forwardAgent = false;
-        extraOptions = { preferredAuthentications = "publickey"; };
-      };
-      "github.com" = {
-        hostname = "github.com";
-        user = "git";
-        forwardAgent = false;
-        extraOptions = { preferredAuthentications = "publickey"; };
-      };
-      "github.rbx.com" = {
-        hostname = "github.rbx.com";
-        user = "git";
-        forwardAgent = false;
-        extraOptions = { preferredAuthentications = "publickey"; };
-      };
-    };
-  };
-
-  # Generate ssh agent config for 1Password - I want both my personal and work keys
-  home.file.".config/1Password/ssh/agent.toml".text = ''
-    [[ssh-keys]]
-    account = "my.1password.com"
-
-    [[ssh-keys]]
-    account = "roblox.1password.com"
-    item = "GitHub ssh key"
-    vault = "Private"
-  '';
-}