2021-11-02 13:23:43 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, ruby, makeWrapper, git }:
|
2011-05-04 10:07:56 +00:00
|
|
|
|
2021-11-02 13:23:43 +00:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-13 21:52:01 +00:00
|
|
|
pname = "svn2git";
|
2021-11-02 13:23:43 +00:00
|
|
|
version = "2.4.0";
|
2011-05-04 10:07:56 +00:00
|
|
|
|
2021-11-02 13:23:43 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nirvdrum";
|
|
|
|
repo = "svn2git";
|
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "sha256-w649l/WO68vYYxZOBKzI8XhGFkaSwWx/O3oVOtnGg6w=";
|
2011-05-04 10:07:56 +00:00
|
|
|
};
|
|
|
|
|
2021-02-07 09:17:39 +00:00
|
|
|
nativeBuildInputs = [ ruby makeWrapper ];
|
2011-05-04 10:07:56 +00:00
|
|
|
|
2016-05-04 10:08:35 +00:00
|
|
|
dontBuild = true;
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out
|
|
|
|
cp -r lib $out/
|
|
|
|
|
|
|
|
mkdir -p $out/bin
|
|
|
|
substituteInPlace bin/svn2git --replace '/usr/bin/env ruby' ${ruby}/bin/ruby
|
|
|
|
cp bin/svn2git $out/bin/
|
|
|
|
chmod +x $out/bin/svn2git
|
|
|
|
|
|
|
|
wrapProgram $out/bin/svn2git \
|
|
|
|
--set RUBYLIB $out/lib \
|
|
|
|
--prefix PATH : ${git}/bin
|
|
|
|
'';
|
2013-12-09 00:15:16 +00:00
|
|
|
|
|
|
|
meta = {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/nirvdrum/svn2git";
|
2015-08-05 10:03:01 +00:00
|
|
|
description = "Tool for importing Subversion repositories into git";
|
2021-01-15 13:21:58 +00:00
|
|
|
license = lib.licenses.mit;
|
|
|
|
platforms = lib.platforms.unix;
|
2013-12-09 00:15:16 +00:00
|
|
|
};
|
2011-05-04 10:07:56 +00:00
|
|
|
}
|