File hgview.spec of Package hgview

# spec file for package hgview
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2012 Guido Berhoerster.
# 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

Name:           hgview
Version:        1.8.2
Release:        0
Summary:        Visual Log Navigator for Mercurial
License:        GPL-2.0+
Group:          Development/Tools/Version Control
# hg clone
# tag="$(hg -R hgview tags | sort -r | sed -n '0,/^hgview-version-/s/^\(hgview-version-[^ ]\{1,\}\).*/\1/p')"
# hg -R hgview archive -f tbz2 -r "${tag}" hgview-"${tag#hgview-version-}".tar.bz2
Source:         %{name}-%{version}.tar.bz2
BuildRequires:  asciidoc
BuildRequires:  mercurial
BuildRequires:  python-devel
BuildRequires:  python-qt4
BuildRequires:  python-qt4-utils
BuildRequires:  python-setuptools
BuildRequires:  xmlto
Requires:       mercurial
Requires:       python-pygments
Requires:       python-pyinotify
# Qt4 default interface
Recommends:     hgview-qt4
# for the optional curses interface in the main package
Recommends:     python-urwid
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch

hgview is a simple tool aiming at visually navigate in a Mercurial repository
history.  It is written in Python with quick and efficient key-based navigation
in mind, trying to be fast enough to be usable for big repositories.

%package qt4
Summary:        Qt4 User Interface for hgview
Group:          Development/Tools/Version Control
Requires:       hgview = %{version}
Requires:       python-docutils
Requires:       python-qscintilla
Requires:       python-qt4

%description qt4
This package provides the Qt4 user interface for hgview.

%setup -q

%{__python} build

%{__python} install \
    --prefix=%{_prefix} \
mkdir -p %{buildroot}%{_datadir}
mv %{buildroot}%{_prefix}/man %{buildroot}%{_datadir}/
rm -rf %{buildroot}%{_datadir}/doc/hgview
chmod 644 %{buildroot}%{_mandir}/man1/hgview.1*

rm -rf %{buildroot}

%exclude %{python_sitelib}/hgviewlib/qt4/

%files qt4

openSUSE Build Service is sponsored by