Skip to content

Commit

Permalink
restore git integration
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianHicks committed Aug 22, 2021
1 parent f772ff2 commit 8e2adff
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 14 deletions.
1 change: 1 addition & 0 deletions dotfiles/default.nix
Expand Up @@ -4,6 +4,7 @@
imports = [
./alacritty
./chromium
./git
./tmux
./rofi
./xsession
Expand Down
19 changes: 10 additions & 9 deletions backup/dotfiles/git.nix → dotfiles/git/default.nix
@@ -1,5 +1,8 @@
{ pkgs, ... }:
let git-gclone = import ../pkgs/git-gclone { };
let lazygit-config =
if pkgs.stdenv.isDarwin
then "Library/Application Support/jesseduffield/lazygit/config.yml"
else ".config/jesseduffield/lazygit/config.yml";
in {
programs.git = {
enable = true;
Expand Down Expand Up @@ -33,7 +36,7 @@ in {
};
};

ignores = [ ".direnv" ".DS_Store" ];
ignores = [ ".DS_Store" ];

delta = {
enable = true;
Expand All @@ -49,7 +52,7 @@ in {

programs.gh.enable = true;

home.file."Library/Application Support/jesseduffield/lazygit/config.yml".text =
home.file."${lazygit-config}".text =
builtins.toJSON {
reporting = "off";
startupPopupVersion = 1;
Expand All @@ -60,8 +63,6 @@ in {
universal.return = "q";
universal.createRebaseOptionsMenu = "M";
branches.mergeIntoCurrentBranch = "m";
commits.moveUpCommit = "<a-j>";
commits.moveDownCommit = "<a-k>";
};

gui.theme = {
Expand All @@ -78,10 +79,10 @@ in {
};
};

home.packages = with pkgs; [
git-lfs
lazygit
home.packages = [
pkgs.git-lfs
pkgs.lazygit
pkgs.gitAndTools.delta
git-gclone
pkgs.git-gclone
];
}
2 changes: 2 additions & 0 deletions flake.nix
Expand Up @@ -27,6 +27,8 @@
configureFlags = attrs.configureFlags ++ [ "--enable-utf8proc" ];
}
);

git-gclone = final.callPackage ./pkgs/git-gclone {};
};

nixosConfigurations.torch = inputs.nixpkgs.lib.nixosSystem {
Expand Down
@@ -1,7 +1,5 @@
{ sources ? import ../../nix/sources.nix, nixpkgs ? import sources.nixpkgs { }
}:
with nixpkgs;
stdenv.mkDerivation {
{ pkgs ? import <nixpkgs> { } }:
pkgs.stdenv.mkDerivation {
name = "git-gclone";
src = ./.;
buildInputs = [ pkgs.makeWrapper ];
Expand All @@ -10,7 +8,7 @@ stdenv.mkDerivation {
mkdir -p $out/bin
cp ./git-gclone.sh $out/bin/git-gclone
wrapProgram $out/bin/git-gclone --prefix PATH : ${
pkgs.lib.makeBinPath [ git ]
pkgs.lib.makeBinPath [ pkgs.git ]
}
'';
}
Expand Down
File renamed without changes.

0 comments on commit 8e2adff

Please sign in to comment.