File hg-git.spec of Package hg-git

#
# spec file for package hg-git
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


%define rev 586b7aa96466

Name:           hg-git
Version:        0.3.4
Release:        0
Summary:        Mercurial Plugin for Communicating with Git Servers
License:        GPL-2.0+
Group:          Development/Tools/Version Control
Url:            http://hg-git.github.com/
Source0:        https://bitbucket.org/durin42/hg-git/get/%{rev}.tar.bz2
BuildRequires:  mercurial
BuildRequires:  python-devel
BuildRequires:  python-dulwich >= 0.8.0
BuildRequires:  python-setuptools
# tests
BuildRequires:  git-daemon
BuildRequires:  netcat-openbsd
BuildRequires:  unzip
Requires:       mercurial
Requires:       python-dulwich >= 0.8.0
BuildArch:      noarch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
This is the Hg-Git plugin for Mercurial, adding the ability to push and pull
to/from a Git server repository from Hg. This means you can collaborate on Git
based projects from Hg, or use a Git server as a collaboration point for a team
with developers using both Git and Hg.

The Hg-Git plugin can convert commits/changesets losslessly from one system to
another, so you can push via an Hg repository and another Hg client can pull it
and their changeset node ids will be identical - Mercurial data does not get
lost in translation.

%prep
%setup -q -n durin42-hg-git-%{rev}

%build
env CFLAGS="$RPM_OPT_FLAGS" python setup.py build

%check
#export PYTHONPATH="$RPM_BUILD_ROOT%{python_sitelib}"
#cd tests && \
#    python run-tests.py --verbose --with-hg=%{_bindir}/hg

%install
python setup.py install --prefix=%{_prefix} --root="$RPM_BUILD_ROOT" --record-rpm=INSTALLED_FILES

%files -f INSTALLED_FILES
%defattr(-,root,root,-)
%doc COPYING DESIGN.txt README.md

%changelog
openSUSE Build Service is sponsored by