1 { lib, stdenv, fetchFromGitHub, coreutils, git, gnugrep, gnused, makeWrapper, inotify-tools }:
3 stdenv.mkDerivation rec {
5 version = "unstable-2022-03-20";
7 src = fetchFromGitHub {
10 rev = "8466b77a38b3d5e8b4ed9e3cb1b635e475eeb415";
11 sha256 = "sha256-8rCwpmHV6wgFCLzPJOKzwN5mG8uD5KIlGFwcgQD+SK4=";
14 nativeBuildInputs = [ makeWrapper ];
21 cp -a contrib/git-* $out/bin/
24 wrapperPath = with lib; makeBinPath ([
29 ] ++ lib.optionals stdenv.isLinux [ inotify-tools ]);
32 wrap_path="${wrapperPath}":$out/bin
34 wrapProgram $out/bin/git-sync \
35 --prefix PATH : $wrap_path
37 wrapProgram $out/bin/git-sync-on-inotify \
38 --prefix PATH : $wrap_path
42 description = "A script to automatically synchronize a git repository";
43 homepage = "https://github.com/simonthum/git-sync";
44 maintainers = with lib.maintainers; [ imalison ];
45 license = lib.licenses.cc0;
46 platforms = with lib.platforms; unix;