diff options
author | Marc Weber <marco-oweber@gmx.de> | 2009-10-27 17:46:37 +0000 |
---|---|---|
committer | Marc Weber <marco-oweber@gmx.de> | 2009-10-27 17:46:37 +0000 |
commit | 748dd33b2546fb840da4c9f3258d72a8856f62b7 (patch) | |
tree | c1952f008c317df680c2f5d983a04f5f5a23b7bb /pkgs | |
parent | d129a6ce87bb86d81a02a2f225e5afe10b17b687 (diff) |
hg2git has been put into repo fast-export. make it work again
svn path=/nixpkgs/trunk/; revision=17977
Diffstat (limited to 'pkgs')
4 files changed, 39 insertions, 30 deletions
diff --git a/pkgs/applications/version-management/git-and-tools/default.nix b/pkgs/applications/version-management/git-and-tools/default.nix index 86dfc77c4ae93..9e6c1043f0a78 100644 --- a/pkgs/applications/version-management/git-and-tools/default.nix +++ b/pkgs/applications/version-management/git-and-tools/default.nix @@ -3,7 +3,7 @@ */ args: with args; with pkgs; let - inherit (pkgs) stdenv fetchurl getConfig; + inherit (pkgs) stdenv fetchurl getConfig subversion; inherit (pkgs.bleedingEdgeRepos) sourceByName; in rec { @@ -83,8 +83,8 @@ rec { }; }; - hg2git = import ./hg2git { - inherit fetchurl stdenv mercurial coreutils git makeWrapper; + gitFastExport = import ./fast-export { + inherit fetchurl stdenv mercurial coreutils git makeWrapper subversion; inherit (bleedingEdgeRepos) sourceByName; }; diff --git a/pkgs/applications/version-management/git-and-tools/fast-export/default.nix b/pkgs/applications/version-management/git-and-tools/fast-export/default.nix new file mode 100644 index 0000000000000..2c1b055f31162 --- /dev/null +++ b/pkgs/applications/version-management/git-and-tools/fast-export/default.nix @@ -0,0 +1,35 @@ +args: with args; +stdenv.mkDerivation { + name = "fast-export"; + + src = sourceByName "git_fast_export"; + + buildInputs =([mercurial.python mercurial makeWrapper subversion]); + + buildPhase="true"; # skip svn for now + + # TODO also support svn stuff + # moving .py files into lib directory so that you can't pick the wrong file from PATH. + # This requires redefining ROOT + installPhase = '' + sed -i "s@/usr/bin/env.*@$(type -p python)@" *.py + l=$out/libexec/git-fast-export + ensureDir $out/{bin,doc/git-fast-export} $l + mv *.txt $out/doc/git-fast-export + sed -i "s@ROOT=.*@ROOT=$l@" *.sh + mv *.sh $out/bin + mv *.py $l + for p in $out/bin/*.sh; do + wrapProgram $p \ + --set PYTHONPATH "$(echo ${mercurial}/lib/python*/site-packages)" \ + --prefix PATH : "$(dirname $(type -p python))":$l + done + ''; + + # usage: + meta = { + description = "import svn, mercurial into git"; + homepage = "http://repo.or.cz/w/fast-export.git"; + license = "?"; # the .py file is GPLv2 + }; +} diff --git a/pkgs/applications/version-management/git-and-tools/hg2git/default.nix b/pkgs/applications/version-management/git-and-tools/hg2git/default.nix deleted file mode 100644 index 291391b671919..0000000000000 --- a/pkgs/applications/version-management/git-and-tools/hg2git/default.nix +++ /dev/null @@ -1,26 +0,0 @@ -args: with args; -stdenv.mkDerivation { - name = "hg2git"; - - src = sourceByName "hg2git"; - - buildInputs =([mercurial.python mercurial makeWrapper]); - - installPhase = '' - ensureDir $out/bin; - cp hg2git.sh hg2git.py $out/bin - cat >> $out/bin/hg2git-doc << EOF - #!${coreutils}/bin/cat - $(cat hg2git.txt) - EOF - chmod +x $out/bin/hg2git-doc - wrapProgram $out/bin/hg2git.sh \ - --set PYTHONPATH "$(echo ${mercurial}/lib/python*/site-packages)" - ''; - - meta = { - description = "mercurial to git one way conversion"; - homepage = "http://git.grml.org/?p=hg-to-git.git;a=summary"; - license = "?"; # the .py file is GPLv2 - }; -} diff --git a/pkgs/development/misc/bleeding-edge-repos/default.nix b/pkgs/development/misc/bleeding-edge-repos/default.nix index e73d8b5a07790..386ed2d08d659 100644 --- a/pkgs/development/misc/bleeding-edge-repos/default.nix +++ b/pkgs/development/misc/bleeding-edge-repos/default.nix @@ -41,7 +41,7 @@ args: plugins = { type = "darcs"; url="http://code.haskell.org/~dons/code/hs-plugins/"; groups="haskell"; }; - hg2git = { type = "git"; url="git://repo.or.cz/hg2git.git"; }; + git_fast_export = { type = "git"; url="git://repo.or.cz/hg2git.git"; }; MPlayer = { type = "svn"; url="svn://svn.mplayerhq.hu/mplayer/trunk"; }; |