mergiraf: init module (#6633)

This adds git integration for mergiraf. It sets up git to use mergiraf
to automatically resolve merge conflicts.
This commit is contained in:
Bob van der Linden 2025-03-25 21:37:24 +01:00 committed by GitHub
parent 8bef8b7a0a
commit d8b4ba070f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 58 additions and 0 deletions

View file

@ -0,0 +1,13 @@
{ config, lib, ... }:
{
programs.git.enable = true;
programs.mergiraf.enable = true;
nmt.script = ''
assertFileContent "home-files/.config/git/config" ${./mergiraf-git.conf}
assertFileContent "home-files/.config/git/attributes" ${
./mergiraf-git-attributes.conf
}
'';
}

View file

@ -0,0 +1 @@
{ mergiraf-basic-configuration = ./basic-configuration.nix; }

View file

@ -0,0 +1 @@
* merge=mergiraf

View file

@ -0,0 +1,9 @@
[gpg]
format = "openpgp"
[gpg "openpgp"]
program = "@gnupg@/bin/gpg"
[merge "mergiraf"]
driver = "@mergiraf@/bin/mergiraf merge --git %O %A %B -s %S -x %X -y %Y -p %P -l %L"
name = "mergiraf"