Adam Miller 1e3df3c
%global        with_python3 0
25056f9
25056f9
Name:          bpython
25056f9
Summary:       Fancy curses interface to the Python interactive interpreter
c9a3437
Version:       0.14.2
1a583fd
Release:       1%{?dist}
bff1d72
URL:           http://www.bpython-interpreter.org/
25056f9
Group:         Development/Libraries
25056f9
License:       MIT
bff1d72
Source0:       http://www.bpython-interpreter.org/releases/bpython-%{version}.tar.gz
176d1db
# some gimp resize of http://bpython-interpreter.org/static/img/bpython-logo.png
25056f9
BuildArch:     noarch
ac1ea40
BuildRequires: python-devel
ac1ea40
BuildRequires: python-setuptools
0bffbb0
BuildRequires: python-sphinx
ac1ea40
BuildRequires: desktop-file-utils
870b452
%if 0%{?with_python3}
870b452
BuildRequires: python3-devel
870b452
BuildRequires: python3-setuptools
870b452
%endif # if with_python3
1a583fd
Requires:      python-curtsies < 0.2
1a583fd
Requires:      python-greenlet
4dda57b
Requires:      python-pygments
1a583fd
Requires:      python-requests > 1.2.3
09bdefd
Requires:      python-urwid
1a583fd
Obsoletes:     bpython-gtk < 0.14
870b452
25056f9
%description
25056f9
bpython is a fancy interface to the Python interpreter for Unix-like
25056f9
operating systems. It has the following features:
25056f9
 o in-line syntax highlighting
25056f9
 o readline-like autocomplete with suggestions displayed as you type
25056f9
 o expected parameter list for any Python function.
25056f9
 o eewind function to pop the last line of code from memory and
25056f9
   re-evaluate.
25056f9
 o send the code you've entered off to a pastebin and display the
f27473a
   pastebin URL for copying, etc.
f27473a
 o save the code you've entered to a file
f27473a
 o auto indentation
f27473a
870b452
%if 0%{?with_python3}
4dda57b
%package -n    python3-bpython
870b452
Summary:       Fancy curses interface to the Python 3 interactive interpreter 
870b452
Group:         Development/Languages
09bdefd
Provides:      bpython3 = %{version}-%{release}
1a583fd
Requires:      python3-curtsies < 0.2
1a583fd
Requires:      python3-greenlet
870b452
Requires:      python3-pygments
1a583fd
Requires:      python3-requests > 1.2.3
b520165
#Requires:      python3-urwid
870b452
870b452
%description -n python3-bpython
870b452
bpython is a fancy interface to the Python interpreter for Unix-like
870b452
operating systems. It has the following features:
870b452
 o in-line syntax highlighting
870b452
 o readline-like autocomplete with suggestions displayed as you type
870b452
 o expected parameter list for any Python function.
870b452
 o eewind function to pop the last line of code from memory and
870b452
   re-evaluate.
870b452
 o send the code you've entered off to a pastebin and display the
f27473a
   pastebin URL for copying, etc.
870b452
 o save the code you've entered to a file
870b452
 o auto indentation
870b452
870b452
This is the Python 3 build of bpython
870b452
%endif # if with_python3
870b452
25056f9
%prep
bff1d72
%setup -q
870b452
%if 0%{?with_python3}
870b452
rm -rf %{py3dir}
870b452
cp -a . %{py3dir}
870b452
# 2to3 is done for us by the setup.py
870b452
%endif # with_python3
870b452
25056f9
%build
4dda57b
%{__python2} setup.py build
25056f9
870b452
%if 0%{?with_python3}
870b452
pushd %{py3dir}
870b452
%{__python3} setup.py build
870b452
popd
870b452
%endif # with_python3
870b452
25056f9
%install
870b452
# Install python 3 first, so that python 2 gets precedence:
870b452
%if 0%{?with_python3}
870b452
pushd %{py3dir}
870b452
%{__python3} setup.py install -O1 --skip-build --root %{buildroot}
1a583fd
b520165
# python3-urwid ok, however python3 twisted also needed
4dda57b
rm -f %{buildroot}%{_bindir}/bpython-urwid
1a583fd
1a583fd
# Move python3
1a583fd
mv %{buildroot}/%{_bindir}/bpython %{buildroot}/%{_bindir}/bpython3
1a583fd
mv %{buildroot}/%{_bindir}/bpython-curses %{buildroot}/%{_bindir}/bpython3-curses
c9a3437
mv %{buildroot}/%{_bindir}/bpdb %{buildroot}%{_bindir}/bpdb3
1a583fd
1a583fd
# Create symlink for compat reasons
1a583fd
ln -s bpython3 %{buildroot}%{_bindir}/python3-bpython
1a583fd
870b452
popd
870b452
%endif # with_python3
4dda57b
%{__python2} setup.py install -O1 --skip-build --root %{buildroot}
25056f9
25056f9
%files
1a583fd
%doc AUTHORS CHANGELOG LICENSE README.rst
1a583fd
%doc light.theme sample.theme
c9a3437
%{_bindir}/bpdb
1a583fd
%{_bindir}/bpython
1a583fd
%{_bindir}/bpython-curses
1a583fd
%{_bindir}/bpython-urwid
1a583fd
%{python_sitelib}/bpython*
176d1db
%{python_sitelib}/bpdb
1a583fd
%{_mandir}/man1/bpython.1*
1a583fd
%{_mandir}/man5/bpython-config.5*
1a583fd
%{_datadir}/pixmaps/bpython.png
1a583fd
%{_datadir}/appdata/bpython.appdata.xml
1a583fd
%{_datadir}/applications/bpython.desktop
f27473a
870b452
%if 0%{?with_python3}
870b452
%files -n python3-bpython
1a583fd
%doc AUTHORS CHANGELOG LICENSE README.rst
1a583fd
%doc light.theme sample.theme
c9a3437
%{_bindir}/bpdb3
ec7fd91
%{_bindir}/bpython3
1a583fd
%{_bindir}/bpython3-curses
1a583fd
%{_bindir}/python3-bpython
1a583fd
%{python3_sitelib}/bpython*
176d1db
%{python3_sitelib}/bpdb
870b452
%endif # with_python3
870b452
25056f9
%changelog
c9a3437
* Tue Jun 02 2015 Terje Rosten <terje.rosten@ntnu.no> - 0.14.2-1
c9a3437
- 0.14.2
c9a3437
1a583fd
* Thu Mar 26 2015 Terje Rosten <terje.rosten@ntnu.no> - 0.14.1-1
1a583fd
- 0.14.1
1a583fd
- gtk gone upstream, remove sub package and add obsolete
1a583fd
- appdata, desktop file and png upstream
1a583fd
- new deps
1a583fd
- curtsies now default
1a583fd
Richard Hughes 439969c
* Thu Mar 26 2015 Richard Hughes <rhughes@redhat.com> - 0.13.2-2
Richard Hughes 439969c
- Add an AppData file for the software center
Richard Hughes 439969c
09bdefd
* Mon Jan 12 2015 Terje Rosten <terje.rosten@ntnu.no> - 0.13.2-1
09bdefd
- 0.13.2
09bdefd
- Swap bpython3 symlinks
09bdefd
- Add bpython3 provide
09bdefd
- Python requests package required
09bdefd
ec7fd91
* Sun Jan 11 2015 Terje Rosten <terje.rosten@ntnu.no> - 0.13.1-3
ec7fd91
- Add bpython3 symlink
ec7fd91
f27473a
* Sat Jan 10 2015 Terje Rosten <terje.rosten@ntnu.no> - 0.13.1-2
f27473a
- Move bpython-gtk to subpackage (bz #1178996)
f27473a
74a1e4e
* Mon Aug 11 2014 Terje Rosten <terje.rosten@ntnu.no> - 0.13.1-1
74a1e4e
- 0.13.1
74a1e4e
Adam Miller 1e3df3c
* Mon Jul 15 2014 Adam Miller <maxamillion@fedoraproject.org> - 0.12-6.1
Adam Miller 1e3df3c
- set with_python3 to 0 for epel7
Adam Miller 1e3df3c
9806df0
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12-6
9806df0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
9806df0
195a865
* Tue May 27 2014 Kalev Lember <kalevlember@gmail.com> - 0.12-5
195a865
- Rebuilt for https://fedoraproject.org/wiki/Changes/Python_3.4
195a865
4dda57b
* Mon Nov 18 2013 Terje Rosten <terje.rosten@ntnu.no> - 0.12-4
4dda57b
- Add patch to fix resize crash (bz #667934)
4dda57b
206c347
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.12-3
206c347
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
206c347
10fb45a
* Wed Mar 06 2013 Terje Rosten <terje.rosten@ntnu.no> - 0.12-2
10fb45a
- Add patch to fix import crash (bz #823662)
10fb45a
0bffbb0
* Wed Jan 30 2013 Terje Rosten <terje.rosten@ntnu.no> - 0.12-1
0bffbb0
- 0.12
0bffbb0
fa04080
* Sat Aug 04 2012 David Malcolm <dmalcolm@redhat.com> - 0.11-4
fa04080
- rebuild for https://fedoraproject.org/wiki/Features/Python_3.3
fa04080
71fff1e
* Fri Aug  3 2012 David Malcolm <dmalcolm@redhat.com> - 0.11-3
71fff1e
- remove rhel logic from with_python3 conditional
71fff1e
00c3287
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.11-2
00c3287
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
00c3287
b520165
* Mon May 07 2012 Terje Rosten <terje.rosten@ntnu.no> - 0.11-1
b520165
- 0.11
b520165
c4acc2b
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.10.1-3
c4acc2b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
c4acc2b
ac1ea40
* Mon Oct 17 2011 Terje Rosten <terje.rosten@ntnu.no> - 0.10.1-2
ac1ea40
- Add python-urwid to buildreq
ac1ea40
695f06d
* Mon Oct 17 2011 Terje Rosten <terje.rosten@ntnu.no> - 0.10.1-1
695f06d
- 0.10.1
695f06d
b56f2b9
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.7.1-2
b56f2b9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
b56f2b9
695f06d
* Thu Sep 02 2010 Terje Rosten <terje.rosten@ntnu.no> - 0.9.7.1-1
176d1db
- 0.9.7.1
176d1db
64431f3
* Wed Aug 25 2010 Thomas Spura <tomspur@fedoraproject.org> - 0.9.6.2-7
64431f3
- rebuild with python3.2
64431f3
  http://lists.fedoraproject.org/pipermail/devel/2010-August/141368.html
64431f3
dee2034
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 0.9.6.2-6
dee2034
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
dee2034
43ebbdd
* Sun May 30 2010 Terje Rosten <terje.rosten@ntnu.no> - 0.9.6.2-5
43ebbdd
- Add patch to fix suspend
43ebbdd
870b452
* Sun May 09 2010 Terje Rosten <terje.rosten@ntnu.no> - 0.9.6.2-4
870b452
- bpython don't use pyparsing
870b452
870b452
* Fri May 07 2010 David Malcolm <dmalcolm@redhat.com> - 0.9.6.2-3
870b452
- Add python3 subpackage (bz #590107)
870b452
74a1e4e
* Fri Apr 09 2010 Terje Rosten <terje.rosten@ntnu.no> - 0.9.6.2-2
6b855b1
- Fix man page (bz #561800)
6b855b1
74a1e4e
* Fri Apr 09 2010 Terje Rosten <terje.rosten@ntnu.no> - 0.9.6.2-1
8af6d74
- 0.9.6.2
8af6d74
0465e2e
* Thu Nov 05 2009 Terje Rosten <terje.rosten@ntnu.no> - 0.9.5.2-1
0465e2e
- 0.9.5.2
0465e2e
bff1d72
* Fri Jul 31 2009 Terje Rosten <terje.rosten@ntnu.no> - 0.9.4-1
bff1d72
- 0.9.4
bff1d72
- Update urls
bff1d72
098b2d7
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.8.0-2
098b2d7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
098b2d7
ded77d5
* Mon May 18 2009 Terje Rosten <terje.rosten@ntnu.no> - 0.8.0-1
ded77d5
- 0.8.0
ded77d5
335c5fe
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.7.1-3
335c5fe
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
335c5fe
5025a1e
* Mon Jan  5 2009 Terje Rosten <terje.rosten@ntnu.no> - 0.7.1-2
5025a1e
- Add setuptools to buildreq
5025a1e
2240e37
* Mon Jan  5 2009 Terje Rosten <terje.rosten@ntnu.no> - 0.7.1-1
2240e37
- 0.7.1
2240e37
3c6a366
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.7.0-2
3c6a366
- Rebuild for Python 2.6
3c6a366
a972a90
* Mon  Sep 1 2008 Terje Rosten <terje.rosten@ntnu.no> - 0.7.0-1
a972a90
- 0.7.0
a972a90
8750690
* Tue Aug 12 2008 Terje Rosten <terje.rosten@ntnu.no> - 0.6.3-1
8750690
- 0.6.3
8750690
25056f9
* Mon May  5 2008 Terje Rosten <terje.rosten@ntnu.no> - 0.3.1-2
25056f9
- fix summary
25056f9
- remove desktop file and optflags
25056f9
25056f9
* Wed Apr 30 2008 Terje Rosten <terje.rosten@ntnu.no> - 0.3.1-1
25056f9
- 0.3.1
25056f9
- drop patch
25056f9
25056f9
* Sun Apr 27 2008 Terje Rosten <terje.rosten@ntnu.no> - 0.2.3-1
25056f9
- random fixes
25056f9
25056f9
* Sun Apr 27 2008 Pascal Bleser <guru@unixtech.be> 0.2.3
25056f9
- new package