Compare commits

...
This repository has been archived on 2026-09-10. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.

7 commits

Author SHA1 Message Date
Fedora Release Engineering
20c77bccb1 dist-git conversion 2010-07-28 17:41:46 +00:00
Bill Nottingham
3cf3e831ba Fix typo that causes a failure to update the common directory. (releng
#2781)
2009-11-26 01:17:32 +00:00
e9c2cfb06f Patch to do multiple groups ok 2008-10-16 15:48:54 +00:00
0eefaf05c0 Try three... 2008-08-10 15:46:07 +00:00
7c423c0bb1 Initial import (try two). 2008-08-10 15:38:56 +00:00
9fb557114b Initial import into Fedora. 2008-08-10 15:36:55 +00:00
44bb7da0c0 Initialize branch F-9 for hellanzb 2008-08-10 01:06:05 +00:00
9 changed files with 195 additions and 21 deletions

View file

2
.gitignore vendored Normal file
View file

@ -0,0 +1,2 @@
hellanzb-0.13.tar.gz
hellanzb-README.Fedora

View file

@ -1,21 +0,0 @@
# Makefile for source rpm: hellanzb
# $Id$
NAME := hellanzb
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))
ifeq ($(MAKEFILE_COMMON),)
# attept a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif
include $(MAKEFILE_COMMON)

View file

@ -0,0 +1,16 @@
--- Hellanzb/NZBLeecher/NZBParser.py.orig 2008-10-15 20:05:11.000000000 -0700
+++ Hellanzb/NZBLeecher/NZBParser.py 2008-10-15 20:10:32.000000000 -0700
@@ -148,11 +148,12 @@
self.file = None
self.fileNeedsDownload = None
elif name == 'group':
newsgroup = self.parseUnicode(''.join(self.chars))
- self.file.groups.append(newsgroup)
+ #self.file.groups.append(newsgroup)
+ self.file.group = newsgroup
self.chars = None
elif name == 'segment':
if self.number in self.segmentNumbers:

View file

@ -0,0 +1,42 @@
--- Hellanzb/Core.py.orig 2008-08-05 23:50:37.000000000 -0700
+++ Hellanzb/Core.py 2008-08-06 00:02:39.000000000 -0700
@@ -32,14 +32,13 @@
return
else:
error('Unable to load specified config file: ' + optionalConfigFile)
sys.exit(1)
- # look for conf in this order: sys.prefix, ./, or ./etc/
- confDirs = [os.path.join(sys.prefix, 'etc')]
+ # look for conf in this order: $HOME/, /etc, or ./
+ confDirs = [os.environ['HOME'], '/etc']
try:
- confDirs.append(os.path.join(os.getcwd(), 'etc'))
confDirs.append(os.getcwd())
except OSError, ose:
if ose.errno != 2:
raise
# OSError: [Errno 2] No such file or directory. cwd doesn't exist
@@ -49,16 +48,22 @@
if Hellanzb.SYSNAME == "Darwin":
confDirs[0] = '/opt/local/etc'
for dir in confDirs:
file = os.path.join(dir, 'hellanzb.conf')
+ file2 = os.path.join(dir, '.hellanzb.conf')
if loadConfig(file):
Hellanzb.CONFIG_FILENAME = file
return
+ elif loadConfig(file2):
+ Hellanzb.CONFIG_FILENAME = file2
+ return
error('Could not find configuration file in the following dirs: ' + str(confDirs))
+ readmeFedora = "*DOCDIR*/*PKGNAME*/README.Fedora"
+ print open(readmeFedora).read().strip()
sys.exit(1)
def loadConfig(fileName):
""" Attempt to load the specified config file. If successful, clean the variables/data the
config file has setup """

View file

@ -0,0 +1,10 @@
--- Hellanzb/Growl.py.orig 2008-07-19 18:08:13.000000000 -0700
+++ Hellanzb/Growl.py 2008-07-19 18:08:45.000000000 -0700
@@ -1,7 +1,5 @@
-#!/usr/bin/env python
-
"""Growl 0.6 Network Protocol Client for Python"""
__version__ = "0.6" # will always match Growl version
__author__ = "Rui Carmo (http://the.taoofmac.com)"
__copyright__ = "(C) 2004 Rui Carmo. Code under BSD License."
__contributors__ = "Ingmar J Stein (Growl Team)"

View file

@ -0,0 +1,22 @@
--- Hellanzb/Core.py.orig 2008-07-21 06:05:16.000000000 -0700
+++ Hellanzb/Core.py 2008-07-21 06:06:23.000000000 -0700
@@ -94,11 +94,18 @@
Hellanzb.MAX_RATE = 0
else:
Hellanzb.MAX_RATE = int(Hellanzb.MAX_RATE)
if not hasattr(Hellanzb, 'UNRAR_CMD') or Hellanzb.UNRAR_CMD is None:
- Hellanzb.UNRAR_CMD = assertIsExe(['rar', 'unrar'])
+ # unrar is optional when it is not installed or not specified in conf
+ Hellanzb.UNRAR_CMD = None
+ try:
+ Hellanzb.UNRAR_CMD = assertIsExe(['rar', 'unrar'])
+ except FatalError:
+ # if unrar isn't available, skip it and warn the user
+ print "Warning -- unrar was not found. Disabling unraring."
+ Hellanzb.SKIP_UNRAR = True
else:
Hellanzb.UNRAR_CMD = assertIsExe([Hellanzb.UNRAR_CMD])
if not hasattr(Hellanzb, 'PAR2_CMD') or Hellanzb.PAR2_CMD is None:
Hellanzb.PAR2_CMD = assertIsExe(['par2'])

101
hellanzb.spec Normal file
View file

@ -0,0 +1,101 @@
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
Name: hellanzb
Version: 0.13
Release: 6%{?dist}
Summary: Hands-free nzb downloader and post processor
Group: Applications/Internet
License: BSD
URL: http://www.hellanzb.com/trac/
Source0: http://www.hellanzb.com/distfiles/hellanzb-%{version}.tar.gz
Source1: hellanzb-README.Fedora
# Make hellanzb check in $HOME, then /etc, then cwd. Print Fedora-specific
# README if no config is found.
Patch0: hellanzb-configuration-location3.patch
# Disable unrar functionality if the command is not found in PATH.
Patch1: hellanzb-unrar-is-optional.patch
# Remove a bogus shebang from a library that rpmlint doesn't like.
Patch2: hellanzb-remove-bogus-shebang.patch
# Multiple group support is broken, so only take the last one
# See: https://bugzilla.redhat.com/show_bug.cgi?id=467032
Patch3: hellanzb-0.13-dont-attempt-multiple-groups.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: python-devel
BuildRequires: python-setuptools
BuildArch: noarch
Requires: par2cmdline
Requires: python-twisted
Requires: python-twisted-web
Requires: python-yenc
%description
hellanzb is an easy to use application designed to retrieve nzb files
and fully process them. The goal being to make getting files from Usenet
as hands-free as possible. Once fully installed, all that's required
is moving an nzb file to the queue directory. The rest: downloading,
par-checking, un-raring, etc. is done automatically by hellanzb.
%prep
%setup -q
%patch0
sed --in-place 's|\*DOCDIR\*|%{_docdir}|' Hellanzb/Core.py
sed --in-place 's|\*PKGNAME\*|%{name}|' Hellanzb/Core.py
%patch1
%patch2
%patch3
%build
%{__python} -c 'import setuptools; execfile("setup.py")' build
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}
%{__python} -c 'import setuptools; execfile("setup.py")' install --skip-build --root $RPM_BUILD_ROOT
mv $RPM_BUILD_ROOT/%{_bindir}/%{name}.py $RPM_BUILD_ROOT/%{_bindir}/%{name}
rm $RPM_BUILD_ROOT/usr/etc/%{name}.conf.sample
mv etc/hellanzb.conf.sample $RPM_BUILD_ROOT/%{_docdir}/%{name}/
cp %{SOURCE1} $RPM_BUILD_ROOT/%{_docdir}/%{name}/README.Fedora
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%{_docdir}/%{name}/
%{python_sitelib}/*
%{_bindir}/%{name}
%changelog
* Wed Oct 15 2008 Conrad Meyer <konrad@tylerc.org> - 0.13-6
- Don't allow multiple groups as support for that is broken.
* Wed Aug 6 2008 Conrad Meyer <konrad@tylerc.org> - 0.13-5
- Re-seperated unrar and configuration patches.
* Tue Aug 5 2008 Conrad Meyer <konrad@tylerc.org> - 0.13-4
- Add missing BR to build in mock/koji.
- Patched to look in /etc instead of /usr/etc for configuration.
- Patched to inform user that configuration is needed if no configuration
can be found.
* Mon Jul 21 2008 Conrad Meyer <konrad@tylerc.org> - 0.13-3
- Patch to make unrar optional.
* Sat Jul 19 2008 Conrad Meyer <konrad@tylerc.org> - 0.13-2
- Look for configuration on a per-user basis (~/.hellanzb.conf).
- Move sample config to %%doc.
- Add a README.RPMFusion.
* Mon Jun 2 2008 Conrad Meyer <konrad@tylerc.org> - 0.13-1
- Initial revision.

View file

@ -0,0 +1,2 @@
d3510c6b1b2c7b935332a469fdc8e7e2 hellanzb-0.13.tar.gz
c6cebd7a279ee4aabbf3773c6aab7b6b hellanzb-README.Fedora