From MAILER-DAEMON Wed May 02 20:35:51 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1HjPIV-0002M5-Ku
	for mharc-getht-commit@gnu.org; Wed, 02 May 2007 20:35:51 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1HjPIU-0002Lz-1u
	for getht-commit@nongnu.org; Wed, 02 May 2007 20:35:50 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1HjPIR-0002Lk-Op
	for getht-commit@nongnu.org; Wed, 02 May 2007 20:35:48 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1HjPIR-0002Lh-Is
	for getht-commit@nongnu.org; Wed, 02 May 2007 20:35:47 -0400
Received: from outmail136054.authsmtp.net ([62.13.136.54])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1HjPBx-0006dx-55
	for getht-commit@nongnu.org; Wed, 02 May 2007 20:29:06 -0400
Received: from outmail128179.authsmtp.co.uk (outmail128179.authsmtp.co.uk
	[62.13.128.179])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l430T2pJ086669
	for <getht-commit@nongnu.org>; Thu, 3 May 2007 01:29:03 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l430T1UC072868
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Thu, 3 May 2007 01:29:02 +0100 (BST)
Date: Thu, 3 May 2007 01:32:08 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070503003207.GA26740@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="pWyiEgJYm5f9v55/"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: 4ae4a0a5-f90d-11db-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcB AHl2Ch1LUl1xXnN1 agBTZA9dYARPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cucwZGHH8V FkZlXHhdVAp7fEd8
	RABQRDgCNGcxbX1J WUAMagJVJFFXLxtB aU1/VHIMaWBTZX1n
	FAYlNio6PX1ULyFQ Qx1fZV0fXUYXW3s5 ThEEGTQpEAhAH2Nq
	alk+I0IXHANLaS0w 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:646/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-23
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Thu, 03 May 2007 00:35:50 -0000


--pWyiEgJYm5f9v55/
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Revision: getht--mainline--0.1--patch-23
Archive: getht@sv.gnu.org
Creator: Nick White <arch@njw.me.uk>
Date: Thu May  3 01:31:22 BST 2007
Standard-date: 2007-05-03 00:31:22 GMT
New-files: .arch-ids/Makefile.am.id .arch-ids/NEWS.id
    .arch-ids/configure.in.id Makefile.am NEWS configure.in
    doc/.arch-ids/=3Did doc/.arch-ids/Makefile.am.id
    doc/.arch-ids/getht.man.id doc/Makefile.am doc/getht.man
    src/.arch-ids/=3Did src/.arch-ids/Makefile.am.id
    src/Makefile.am
New-directories: doc doc/.arch-ids src src/.arch-ids
Removed-files: .arch-ids/Makefile.id Makefile
Renamed-files: .arch-ids/AUTHOR.id .arch-ids/AUTHORS.id
    .arch-ids/config.c.id src/.arch-ids/config.c.id
    .arch-ids/download.c.id src/.arch-ids/download.c.id
    .arch-ids/getht.c.id src/.arch-ids/getht.c.id
    .arch-ids/getht.h.id src/.arch-ids/getht.h.id
    .arch-ids/issue.h.id src/.arch-ids/issue.h.id
    .arch-ids/issuemem.c.id src/.arch-ids/issuemem.c.id
    .arch-ids/mediarev.c.id src/.arch-ids/mediarev.c.id
    .arch-ids/mediaxml.c.id src/.arch-ids/mediaxml.c.id
    .arch-ids/tocxml.c.id src/.arch-ids/tocxml.c.id
    .arch-ids/version.h.id src/.arch-ids/version.h.id
    .arch-ids/xml.c.id src/.arch-ids/xml.c.id
    AUTHOR AUTHORS
    config.c src/config.c
    download.c src/download.c
    getht.c src/getht.c
    getht.h src/getht.h
    issue.h src/issue.h
    issuemem.c src/issuemem.c
    mediarev.c src/mediarev.c
    mediaxml.c src/mediaxml.c
    tocxml.c src/tocxml.c
    version.h src/version.h
    xml.c src/xml.c
Modified-files: INSTALL README src/getht.c src/version.h
    {arch}/=3Dtagging-method
New-patches: getht@sv.gnu.org/getht--mainline--0.1--patch-23
Summary: Added Autotools, changed dir structure, added docs
Keywords:=20

Added (perhaps somewhat shaky) autotools support
Added tagging rules to junkify files generated by autotools
Added a directory structure
Updated README & INSTALL files to reflect changes
Wrote a man page
Changed version numbers in preparation for a release
A/ doc
A/ doc/.arch-ids
A/ src
A/ src/.arch-ids
D  .arch-ids/Makefile.id
D  Makefile
A  .arch-ids/Makefile.am.id
A  .arch-ids/NEWS.id
A  .arch-ids/configure.in.id
A  Makefile.am
A  NEWS
A  configure.in
A  doc/.arch-ids/=3Did
A  doc/.arch-ids/Makefile.am.id
A  doc/.arch-ids/getht.man.id
A  doc/Makefile.am
A  doc/getht.man
A  src/.arch-ids/=3Did
A  src/.arch-ids/Makefile.am.id
A  src/Makefile.am
M  {arch}/=3Dtagging-method
M  INSTALL
M  README
M  src/getht.c
M  src/version.h
=3D> .arch-ids/AUTHOR.id	.arch-ids/AUTHORS.id
=3D> AUTHOR	AUTHORS
=3D> .arch-ids/config.c.id	src/.arch-ids/config.c.id
=3D> .arch-ids/download.c.id	src/.arch-ids/download.c.id
=3D> .arch-ids/getht.c.id	src/.arch-ids/getht.c.id
=3D> .arch-ids/getht.h.id	src/.arch-ids/getht.h.id
=3D> .arch-ids/issue.h.id	src/.arch-ids/issue.h.id
=3D> .arch-ids/issuemem.c.id	src/.arch-ids/issuemem.c.id
=3D> .arch-ids/mediarev.c.id	src/.arch-ids/mediarev.c.id
=3D> .arch-ids/mediaxml.c.id	src/.arch-ids/mediaxml.c.id
=3D> .arch-ids/tocxml.c.id	src/.arch-ids/tocxml.c.id
=3D> .arch-ids/version.h.id	src/.arch-ids/version.h.id
=3D> .arch-ids/xml.c.id	src/.arch-ids/xml.c.id
=3D> config.c	src/config.c
=3D> download.c	src/download.c
=3D> getht.c	src/getht.c
=3D> getht.h	src/getht.h
=3D> issue.h	src/issue.h
=3D> issuemem.c	src/issuemem.c
=3D> mediarev.c	src/mediarev.c
=3D> mediaxml.c	src/mediaxml.c
=3D> tocxml.c	src/tocxml.c
=3D> version.h	src/version.h
=3D> xml.c	src/xml.c

* modified files

--- orig/INSTALL
+++ mod/INSTALL
@@ -1,21 +1,32 @@
-At the moment this project uses a custom (but very basic) makefile
-to make and install. This will soon be changed to autotools, but at
-present this way works well enough.
+To install this package, simply follow the following steps:
=20
-For a default install all that is needed is the following:
+1. Decompress & untar the archive
+   $ tar -xjf getht-<version>.tar.bz2
=20
-1. Decompress/archive the project file:
-	tar -xzf getht-<version>.tar.gz
-or
-	tar -xyf getht-<version>.tar.bz2
+2. Change to the source directory
+   $ cd getht-<version>
=20
-2. Change to hdte directory:
-	cd getht-<version>
+4. Prepare the software for your system
+   $ ./configure
=20
-3. Run make to compile the source:
-	make
+   Note that there are several options which can be applied
+   here, such as prefix and locations of libraries.
+   For more information run:
+   $ ./configure --help
=20
-4. Use make again to install it (you'll need to have root privilages):
-	make install
+4. Build the software
+   $ make
=20
-For further build options, see the output of "make help"
+5. Install the software (ensure that you have superuser
+   privilages if installing outside of your home directory)
+   $ make install
+
+
+You can then run the package by typing the following
+command into a terminal:
+$ getht
+
+Note that the AutoTools scripts to build and install GetHT are
+quite simple, and have not been thoroughly tested.
+If you encounter any problems building please let me know, using
+one of the methods suggested in the README file.


--- orig/README
+++ mod/README
@@ -1,6 +1,6 @@
-GetHT - The Free Hinduism Today Digital Edition Fetcher
+GetHT - The Free Hinduism Today Digital Edition Downloader
=20
-Summary:
+-Summary
 The nice people at Hinduism Today have recently begun freely distributing
 their magazine in pdf format, so that anybody may read a copy for free.
=20
@@ -13,36 +13,37 @@
=20
 This program is written to change all that.
=20
-License:
-htde is released under the GPL, see the file COPYING for details.
+-License
+GetHT is released under the GPL, see the file COPYING for details.
 Basically this means that you are free to study the program, modify it,
 and redistribute it however you see fit, provided you extend the same
 freedom to others by releasing derivatives with the same license.
=20
-Proxy Support:
+-Dependancies
+libxml2 2.0.0+  Compiled with zlib support
+libcurl 7.7.2+
+
+-Install
+For details on how to install GetHT see the INSTALL file.
+
+-Proxy Support
 GetHT supports HTTP, SOCKS4 & SOCKS5 proxys (though they haven't been
 thoroughly tested - let me know if there are any problems).
 Environmental variables (e.g. http_proxy) are used, but may be overridden
 with the following lines in the config.ini file. Any lines which are not
 needed (for example the authentication lines) should just be omitted.
 The format of the options is:
-proxy_type <type_of_proxy> (http, socks4 or socks5)
-proxy_address <address>
-proxy_port <port>
-proxy_auth <proxy_auth_method> (none, basic, digest or ntlm)
-proxy_user <proxy_username>
-proxy_pass <proxy_password>
-
-Dependancies:
-libxml2         To parse the contents and media files; ensure to compile
-                with zlib support
-libcurl 7.7.2+  To download the necessary issues and periphery
-Unless compiled with "make nogui":
-fltk    2.0+    To draw and control the windows
-
-Install:
-The project is too small to warrent autoconf or anything else complex,
-so simply use the makefile provided to compile and install the software
-from source.
-
-For more details see the included INSTALL file.
+  proxy_type <type_of_proxy> (http, socks4 or socks5)
+  proxy_address <address>
+  proxy_port <port>
+  proxy_auth <proxy_auth_method> (none, basic, digest or ntlm)
+  proxy_user <proxy_username>
+  proxy_pass <proxy_password>
+
+-Bugs / Problems
+This software is very new, so there will undoubtedly be some bugs lingerin=
g,
+or parts of the program which don't work as expected.
+If you encounter problems, there are several ways to get help:
+ Mailing List    : http://lists.nongnu.org/mailman/listinfo/getht-general
+ Support Tracker : http://savannah.nongnu.org/support/?group=3Dgetht
+ Bug Tracker     : http://savannah.nongnu.org/bugs/?group=3Dgetht


--- orig/getht.c
+++ mod/src/getht.c
@@ -56,7 +56,7 @@
 	if(!opendir(getht_path))
 		if(mkdir(getht_path, S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH))
 		{
-			fprintf(stderr,"Cannot open/create directory %s",getht_path);
+			fprintf(stderr,"Cannot open/create directory %s\n",getht_path);
 			printf("Please enter the path of a directory to save settings in: ");
 			scanf("%s", getht_path);
 		}


--- orig/version.h
+++ mod/src/version.h
@@ -19,4 +19,4 @@
  *
  */
=20
-#define VERSION "pre-release"
+#define VERSION "0.0.1"


--- orig/{arch}/=3Dtagging-method
+++ mod/{arch}/=3Dtagging-method
@@ -166,3 +166,6 @@
=20
 # exclude the getht executable
 junk ^getht$
+
+# deal with various autotools extras
+junk ^(Makefile.in|Makefile|config\.(h|h\.in|log|status)|configure|stamp-h=
1|aclocal\.m4|\.deps|config|autom4te.cache)$



* added files

--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./.arch-ids/Makefi=
le.am.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:29:07 2007 8115.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./.arch-ids/NEWS.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:39:57 2007 9811.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./.arch-ids/config=
ure.in.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:29:11 2007 8116.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./Makefile.am
@@ -0,0 +1,13 @@
+## A simple file to process with Automake, to produce Makefile.in
+
+SUBDIRS =3D src doc
+
+doc_DATA =3D \
+	     AUTHORS	\
+	     BUGS	\
+	     ChangeLog	\
+	     COPYING	\
+	     CREDITS	\
+	     INSTALL	\
+	     NEWS	\
+	     README
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./configure.in
@@ -0,0 +1,47 @@
+#                                               -*- Autoconf -*-
+# Process this file with autoconf to produce a configure script.
+
+AC_PREREQ(2.61)
+AC_INIT(getht, 0.0.1)
+AC_CONFIG_SRCDIR([src/])
+AC_CONFIG_AUX_DIR([config])
+AC_CONFIG_HEADER([config.h])
+AM_INIT_AUTOMAKE(AC_PACKAGE_NAME,AC_PACKAGE_VERSION)
+AC_LANG([C])
+
+# Checks for programs.
+AC_PROG_CC
+AC_PROG_INSTALL
+
+# Checks for libraries.
+
+dnl check for zlib
+CHECK_ZLIB()
+
+dnl check for libxml2
+AM_PATH_XML2([2.0.0])
+CFLAGS=3D"$CFLAGS $XML_CPPFLAGS"
+LIBS=3D"$LIBS $XML_LIBS"
+
+dnl check for libcurl
+LIBCURL_CHECK_CONFIG([yes], [7.7.2])
+CFLAGS=3D"$CFLAGS $LIBCURL_CPPFLAGS"
+LIBS=3D"$LIBS $LIBCURL"
+
+# Checks for header files.
+AC_HEADER_STDC
+AC_CHECK_HEADERS([stdlib.h string.h unistd.h])
+
+# Checks for typedefs, structures, and compiler characteristics.
+AC_C_CONST
+AC_TYPE_SIZE_T
+
+# Checks for library functions.
+AC_FUNC_MALLOC
+AC_FUNC_REALLOC
+AC_CHECK_FUNCS([mkdir strdup])
+
+AC_CONFIG_FILES([Makefile
+                 doc/Makefile
+                 src/Makefile])
+AC_OUTPUT
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./doc/.arch-ids/=
=3Did
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:29:26 2007 8118.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./doc/.arch-ids/Ma=
kefile.am.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:29:33 2007 8119.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./doc/.arch-ids/ge=
tht.man.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Thu May  3 01:05:09 2007 23756.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./doc/Makefile.am
@@ -0,0 +1,2 @@
+man1_MANS =3D getht.man
+##doc_DATA =3D *.txt
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./doc/getht.man
@@ -0,0 +1,167 @@
+.\" Copyright 2007 Nick White
+.\"
+.\" This file is part of GetHT
+.\"
+.\" This is free documentation; you can redistribute it and/or
+.\" modify it under the terms of the GNU General Public License as
+.\" published by the Free Software Foundation; either version 2 of
+.\" the License, or (at your option) any later version.
+.\"
+.\" The GNU General Public License's references to "object code"
+.\" and "executables" are to be interpreted as the output of any
+.\" document formatting or typesetting system, including
+.\" intermediate and printed output.
+.\"
+.\" This manual is distributed in the hope that it will be useful,
+.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
+.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+.\" GNU General Public License for more details.
+.\"
+.\" You should have received a copy of the GNU General Public License=20
+.\" along with this program; if not, write to the Free Software
+.\" Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,=
 USA.
+.TH GETHT 1
+.SH NAME=20
+.B GetHT
+\- The Free Hinduism Today Digital Edition Downloader
+.SH SYNOPSIS
+.TP 5
+\fBgetht
+\fI[-uadmnfvh] [-t tocfile] [-m medtocfile]\fR
+
+.SH DESCRIPTION
+.PP
+.I GetHT
+is a program which downloads multimedia and pdf files=20
+from Hinduism Today. It has good proxy support, and
+is small, fast, and simple.
+
+.I GetHT
+is not endorsed by or affiliated with Hinduism Today.=20
+
+.SH OPTIONS
+.TP
+.B \-u, \-\-update
+Update the Hinduism Today contents files.
+.TP
+.B \-a, \-\-download-all
+Download all issues of Hinduism Today.=20
+.TP
+.B \-d, \-\-download-latest
+Download only the latest issue of Hinduism Today.
+.TP
+.B \-m, \-\-download-all-media
+Download all multimedia files distributed by Hinduism=20
+Today.
+.TP
+.B \-n, \-\-download-latest-media
+Download only the multimedia files from the latest=20
+issue of Hinduism Today.
+.TP
+.B \-f, \-\-force
+Force getht to download files, even if they have
+already been downloaded. This is useful if a download
+has been corrupted or interrupted.
+.TP
+.B \-t, \-\-tocfile tocfile
+Use a different contents file, as specified by tocfile.
+.TP
+.B \-x, \-\-mediatocfile mediatocfile
+Use a different media contents file, as specified by
+mediatocfile.
+.TP
+.B \-h, \-\-help
+Print a brief usage message.
+.TP
+.B \-v, \-\-version
+Display the version number.
+
+.SH CONFIGURATION FILE
+All of the settings for GetHT are stored in the=20
+configuration file, which normally resides in
+\fB~/.getht/config.ini\fR.
+
+The format of this file is very simple:
+\fB<option> =3D <setting>\fR
+with commented lines starting with a #=20
+
+The following options may be set.
+.TP
+.B issuepath
+Stores the path in which all issues and multimedia=20
+files will be saved. The default setting is
+\fB~/hinduism_today/\fR
+.TP
+.B startup_check
+Whether to automatically check for new issues each=20
+time the GetHT is executed. \fB1\fR =3D yes, \fB0\fR =3D no
+The default setting is \fB0\fR
+.TP
+.B proxy_type
+The type of proxy (if any) through which GetHT is to
+pass. GetHT currently supports the following options:
+\fBhttp\fR, \fBsocks4\fR, and \fBsocks5\fR.
+To not use any proxy, simply leave out this line.
+.TP
+.B proxy_address
+The url of the proxy to connect through.
+.TP
+.B proxy_port
+The port of the proxy to connect to.
+.TP
+.B proxy_auth
+The method of authentication (if any) with the proxy.
+GetHT currently supports the following options:
+\fBbadic\fR, \fBdigest\fR, and \fBntlm\fR.
+If you don't need proxy authentication, leave out this
+line.
+.TP
+.B proxy_user
+The username with which to connect to the proxy server.
+.TP
+.B proxy_pass
+The password with which to connect to to proxy server.
+
+.SH FILES
+.TP
+.B ~/getht/config.ini
+configuration file.
+
+.SH BUGS
+.I GetHT
+is very new, so there will undoubtedly be some bugs
+around, or parts of the program which don't work as
+expected.
+
+If you encounter problems, there are several ways to
+get help:
+.TP
+.B Mailing List
+.I http://lists.nongnu.org/mailman/listinfo/getht-general
+.TP
+.B Support Tracker=20
+.I http://savannah.nongnu.org/support/?group=3Dgetht
+.TP
+.B Bug Tracker
+.I http://savannah.nongnu.org/bugs/?group=3Dgetht
+
+.SH LICENSE
+Copyright 2007 Nick White
+
+This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License=20
+as published by the Free Software Foundation; either version 2
+of the License, or (at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License=20
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+
+.SH AUTHOR
+GetHT is at present primarily the work of Nick White, see the AUTHORS
+file for full credits and contact details.
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./src/.arch-ids/=
=3Did
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:29:22 2007 8117.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./src/.arch-ids/Ma=
kefile.am.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Wed May  2 20:32:55 2007 8163.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-22--getht@sv.gnu.org/new-files-archive/./src/Makefile.am
@@ -0,0 +1,7 @@
+## A simple file to process with Automake, to produce Makefile.in
+
+bin_PROGRAMS =3D getht
+
+getht_SOURCES =3D config.c download.c getht.c issuemem.c	\
+		mediarev.c mediaxml.c tocxml.c xml.c	\
+		getht.h issue.h version.h


--pWyiEgJYm5f9v55/
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGOS2HH0hWdATkZT8RArKzAKCL9g1ZkjF1aacFFe5iQFKOYnqUaQCgz4mF
eZsU8gcT1ubmnhzHTGz0PYY=
=Ixlt
-----END PGP SIGNATURE-----

--pWyiEgJYm5f9v55/--



From MAILER-DAEMON Thu May 03 13:56:34 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1HjfXe-00058H-74
	for mharc-getht-commit@gnu.org; Thu, 03 May 2007 13:56:34 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1HjfXb-00057T-P8
	for getht-commit@nongnu.org; Thu, 03 May 2007 13:56:31 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1HjfXX-00054x-M7
	for getht-commit@nongnu.org; Thu, 03 May 2007 13:56:31 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1HjfXX-00054Z-Eq
	for getht-commit@nongnu.org; Thu, 03 May 2007 13:56:27 -0400
Received: from outmail136089.authsmtp.com ([62.13.136.89])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1HjfQy-0004RG-2J
	for getht-commit@nongnu.org; Thu, 03 May 2007 13:49:41 -0400
Received: from outmail128182.authsmtp.co.uk (outmail128182.authsmtp.co.uk
	[62.13.128.182])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l43HncGO010475
	for <getht-commit@nongnu.org>; Thu, 3 May 2007 18:49:38 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l43Hnb1Z070996
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Thu, 3 May 2007 18:49:37 +0100 (BST)
Date: Thu, 3 May 2007 18:52:46 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070503175246.GA4657@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="Nq2Wo0NMKNjxTN9z"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: a9b304ca-f99e-11db-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcB AHl2Ch1LUl1xXnN0 YwBVZA9eagRPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cucwY+Jixx D0ZlXnlSWgp4dUd/
	RgAFHD8FZWMzOX1J WUkNagJVJFFXLxtB aU1/VHIMaWBTZX1n
	FAYlNio6PX1ULyFQ Qx1fZV0fXUYXW3s5 ThEEGTQpEAhAH2Nq
	alk+I0IXHANLbi0w 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:646/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-24
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Thu, 03 May 2007 17:56:32 -0000


--Nq2Wo0NMKNjxTN9z
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Revision: getht--mainline--0.1--patch-24
Archive: getht@sv.gnu.org
Creator: Nick White <arch@njw.me.uk>
Date: Thu May  3 18:51:44 BST 2007
Standard-date: 2007-05-03 17:51:44 GMT
New-files: .arch-ids/prepare-package.sh.id
    prepare-package.sh src/.arch-ids/cli.c.id src/cli.c
Modified-files: doc/getht.man src/Makefile.am src/getht.c
    src/issue.h src/tocxml.c src/version.h
New-patches: getht@sv.gnu.org/getht--mainline--0.1--patch-24
Summary: Added a script to ease releases, improved cli interface
Keywords:=20

Added the script prepare-release.sh
Modified and added options to allow easy downloading of single
issues and media files
Moved functions outputting to the command line to cli.c
Added a verbose flag
A  .arch-ids/prepare-package.sh.id
A  prepare-package.sh
A  src/.arch-ids/cli.c.id
A  src/cli.c
M  doc/getht.man
M  src/getht.c
M  src/issue.h
M  src/tocxml.c
M  src/version.h
M  src/Makefile.am

* modified files

--- orig/doc/getht.man
+++ mod/doc/getht.man
@@ -27,7 +27,7 @@
 .SH SYNOPSIS
 .TP 5
 \fBgetht
-\fI[-uadmnfvh] [-t tocfile] [-m medtocfile]\fR
+\fI[-ualmofVvh] [-d issno] [-n medno] [-t tocfile] [-m medtocfile]\fR
=20
 .SH DESCRIPTION
 .PP
@@ -47,22 +47,31 @@
 .B \-a, \-\-download-all
 Download all issues of Hinduism Today.=20
 .TP
-.B \-d, \-\-download-latest
-Download only the latest issue of Hinduism Today.
+.B \-d, \-\-download-issue issno
+Download the issue numbered issno (use \fI-l\fR to find
+issue numbers).
+.TP
+.B \-n, \-\-download-media medno
+Download the multimedia file numbered medno (use \fI-m\fR
+to find media numbers).
 .TP
 .B \-m, \-\-download-all-media
 Download all multimedia files distributed by Hinduism=20
 Today.
 .TP
-.B \-n, \-\-download-latest-media
-Download only the multimedia files from the latest=20
-issue of Hinduism Today.
-.TP
 .B \-f, \-\-force
 Force getht to download files, even if they have
 already been downloaded. This is useful if a download
 has been corrupted or interrupted.
 .TP
+.B \-l, \-\-list-issues
+List the issues of Hinduism Today, with issue numbers,
+sorted by date.
+.TP
+.B \m, \-\-list-media
+List the multimedia files associated with Hinduism=20
+today, with media numbers, sorted by issue date.
+.TP
 .B \-t, \-\-tocfile tocfile
 Use a different contents file, as specified by tocfile.
 .TP
@@ -73,7 +82,11 @@
 .B \-h, \-\-help
 Print a brief usage message.
 .TP
-.B \-v, \-\-version
+.B \-v, \-\-verbose
+Make the output from \fI-l\fR and \fI-m\fR more verbose.
+May be used twice to make output yet more verbose.
+.TP
+.B \-V, \-\-version
 Display the version number.
=20
 .SH CONFIGURATION FILE


--- orig/src/Makefile.am
+++ mod/src/Makefile.am
@@ -2,6 +2,6 @@
=20
 bin_PROGRAMS =3D getht
=20
-getht_SOURCES =3D config.c download.c getht.c issuemem.c	\
+getht_SOURCES =3D config.c cli.c download.c getht.c issuemem.c	\
 		mediarev.c mediaxml.c tocxml.c xml.c	\
 		getht.h issue.h version.h


--- orig/src/getht.c
+++ mod/src/getht.c
@@ -35,10 +35,6 @@
=20
 med * findnewestmed(iss ** issue, int no_of_issues);
=20
-void show_iss_struct(iss ** issue, int no_of_issues);
-
-void showusage();
-
 proxytype proxy_type; char proxy_addr[STR_MAX]; long proxy_port;
 proxyauth proxy_auth;=20
 char proxy_user[STR_MAX]; char proxy_pass[STR_MAX];
@@ -67,11 +63,12 @@
=20
 	snprintf(save_path,STR_MAX,"%s/hinduism_today",getenv("HOME"));
=20
-	int downall =3D 0, downlatest =3D 0;
-	int downallmedia =3D 0, downlatestmedia =3D 0;
-	int downissue =3D 0, downmedia =3D 0;
-	int force =3D 0, update =3D 0, showstr =3D 0;
-	int option =3D 0;
+	int downall =3D 0, downallmedia =3D 0;
+	int downissue =3D 0, downissueno =3D -1;
+	int downmedia =3D 0, downmediano =3D -1;
+	int listissues =3D 0, listmedia =3D 0;
+	int force =3D 0, update =3D 0;
+	int verbose =3D 0, option =3D 0;
=20
 	proxy_type =3D NONE;
 	proxy_port =3D 0;
@@ -98,18 +95,21 @@
 	static struct option long_opts[] =3D
 	{
 		{"download-all", no_argument, 0, 'a'},
-		{"download-latest", no_argument, 0, 'd'},
-		{"download-all-media", no_argument, 0, 'm'},
-		{"download-latest-media", no_argument, 0, 'n'},
+		{"download-issue", required_argument, 0, 'd'},
+		{"download-media", required_argument, 0, 'n'},
+		{"download-all-media", no_argument, 0, 'o'},
 		{"force", no_argument, 0, 'f'},
+		{"list-issues", no_argument, 0, 'l'},
+		{"list-media", no_argument, 0, 'm'},
 		{"update", no_argument, 0, 'u'},
 		{"tocfile", required_argument, 0, 't'},
 		{"mediatocfile", required_argument, 0, 'x'},
 		{"help", no_argument, 0, 'h'},
-		{"version", no_argument, 0, 'v'},
+		{"verbose", no_argument, 0, 'v'},
+		{"version", no_argument, 0, 'V'},
 		{0, 0, 0, 0}
 	};
-	while((c =3D getopt_long(argc, argv, "adfhmnsuvx:t:", long_opts, NULL)) !=
=3D -1) {
+	while((c =3D getopt_long(argc, argv, "ad:fhlmn:osuvVx:t:", long_opts, NUL=
L)) !=3D -1) {
 		switch(c) {
 			case 'a':
 				downall =3D 1;
@@ -117,18 +117,26 @@
 				option =3D 1;
 				break;
 			case 'd':
-				downlatest =3D 1;
 				downissue =3D 1;
+				downissueno =3D atoi(optarg);
+				option =3D 1;
+				break;
+			case 'l':
+				listissues =3D 1;
 				option =3D 1;
 				break;
 			case 'm':
+				listmedia =3D 1;
+				option =3D 1;
+				break;
+			case 'o':
 				downallmedia =3D 1;
 				downmedia =3D 1;
 				option =3D 1;
 				break;
 			case 'n':
-				downlatestmedia =3D 1;
 				downmedia =3D 1;
+				downmediano =3D atoi(optarg);
 				option =3D 1;
 				break;
 			case 'f':
@@ -139,10 +147,6 @@
 				update =3D 1;
 				option =3D 1;
 				break;
-			case 's':
-				showstr =3D 1;
-				option =3D 1;
-				break;
 			case 't':
 				strcpy(issue_xml, strdup(optarg));
 				option =3D 1;
@@ -156,6 +160,10 @@
 				return 0;
 				break;
 			case 'v':
+				verbose++;
+				option =3D 1;
+				break;
+			case 'V':
 				printf("GetHT version: %s\n",VERSION);
 				option =3D 1;
 				return 0;
@@ -181,12 +189,11 @@
=20
 	iss **issue;
 	int no_of_issues =3D -1;
-	int latest_index =3D -1;
 	int i;
=20
-	if(downissue || showstr)
+	if(downissue || listissues)
 	{
-		issue =3D parsetoc(issue_xml, &no_of_issues, &latest_index);
+		issue =3D parsetoc(issue_xml, &no_of_issues);
=20
 		if(!issue)
 		{
@@ -195,7 +202,7 @@
 				printf("Cannot open contents file, trying to update contents\n");
 				if(update_contents_files())
 					return 1;
-				issue =3D parsetoc(issue_xml, &no_of_issues, &latest_index);
+				issue =3D parsetoc(issue_xml, &no_of_issues);
 			}
 			else
 			{
@@ -204,24 +211,16 @@
 			}
 		}
=20
-		if(latest_index =3D=3D -1)
-		{
-			fprintf(stderr, "Error: Cannot ascertain latest issue. ");
-			fprintf(stderr, "Defaulting to first issue in contents file\n");
-			latest_index =3D 0;
-		}
-
 		if(downall)
 		{
 			for(i =3D 0; i < no_of_issues; i++)
 				downloadissue(NULL, save_path, issue[i], force);
 		}
-=09
-		if(downlatest)
-			downloadissue(NULL, save_path, issue[latest_index], force);
+		else if(downissueno >=3D 0 && downissueno <=3D no_of_issues)
+			downloadissue(NULL, save_path, issue[downissueno], force);
 	}
 =09
-	if(downmedia || showstr)
+	if(downmedia || listmedia)
 	{
 		int newest;
=20
@@ -243,13 +242,6 @@
 			}
 		}
=20
-		if(downlatestmedia)
-		{
-			newest =3D findnewestiss(issue, no_of_issues);
-			for(i =3D 0; i <=3D issue[newest]->no_of_media; i++)
-				downloadmedia(NULL, save_path, issue[newest]->media[i], force);
-		}
-
 		if(downallmedia)
 		{
 			for(i =3D 0; i <=3D no_of_issues; i++)
@@ -258,10 +250,23 @@
 					downloadmedia(NULL, save_path, issue[i]->media[newest], force);
 			}
 		}
+		else if(downmediano >=3D 0)
+		{
+			int med_global, med_no;
+
+			for(i=3D0,med_global=3D0; i<=3Dno_of_issues; i++)
+				if(issue[i]->no_of_media >=3D 0)
+					for(med_no=3D0; med_no <=3D (issue[i]->no_of_media); med_no++,med_glo=
bal++)
+						if(med_global =3D=3D downmediano)
+							downloadmedia(NULL, save_path, issue[i]->media[med_no], force);
+		}
 	}
=20
-	if(showstr)
-		show_iss_struct(issue, no_of_issues);
+	if(listissues)
+		list_issues(issue, no_of_issues, verbose);
+
+	if(listmedia)
+		list_media(issue, no_of_issues, verbose);
=20
 	/* Ensure curl cleans itself up */
 	curl_easy_cleanup(main_curl_handle);
@@ -306,52 +311,6 @@
 	return 0;
 }
=20
-void show_iss_struct(iss ** issue, int no_of_issues)
-/*	Prints issue information */
-{
-	int iss_no, sec_no, med_no, it_no;
-	printf("%i Issues\n",no_of_issues);
-	for(iss_no=3D0;iss_no<=3Dno_of_issues;iss_no++)
-	{
-		printf("-Issue %i-\n", (iss_no+1));
-		printf("Title:\t'%s'\n", issue[iss_no]->title);
-		printf("Preview URI:\t'%s'\n", issue[iss_no]->preview_uri);
-		printf("Months:\t'%i' - '%i'\n",issue[iss_no]->date.firstmonth,issue[iss=
_no]->date.lastmonth);
-		printf("Year:\t'%i'\n",issue[iss_no]->date.year);
-		printf("Number of Sections:\t'%i'\n",issue[iss_no]->no_of_sections);
-
-		for(sec_no=3D0; sec_no <=3D (issue[iss_no]->no_of_sections); sec_no++)
-		{
-			printf("\t-Section %i-\n", (sec_no));
-			printf("\tTitle:\t'%s'\n", issue[iss_no]->section[sec_no]->title);
-			printf("\tURI:\t'%s'\n", issue[iss_no]->section[sec_no]->uri);
-			printf("\tNo. of Items:\t'%i'\n", issue[iss_no]->section[sec_no]->no_of=
_items);
-
-			for(it_no=3D0; it_no <=3D issue[iss_no]->section[sec_no]->no_of_items; =
it_no++)
-			{
-				printf("\t\t-Item-\n");
-				printf("\t\tTitle:\t'%s'\n",issue[iss_no]->section[sec_no]->item[it_no=
]->title);
-				printf("\t\tFirst page:\t'%i'",issue[iss_no]->section[sec_no]->item[it=
_no]->firstpage);
-				printf("\tLast page:\t'%i'\n",issue[iss_no]->section[sec_no]->item[it_=
no]->lastpage);
-			}
-			it_no =3D 0;
-		}
-		sec_no =3D 0;
-
-		printf("Number of Media:\t'%i'\n",issue[iss_no]->no_of_media);
-
-		for(med_no=3D0; med_no <=3D (issue[iss_no]->no_of_media); med_no++)
-		{
-			printf("\t-Media %i-\n", (med_no));
-			printf("\tTitle:\t'%s'\n", issue[iss_no]->media[med_no]->title);
-			printf("\tURI:\t'%s'\n", issue[iss_no]->media[med_no]->uri);
-			printf("\tComment:\t'%s'\n", issue[iss_no]->media[med_no]->comment);
-			printf("\tPreview URI:\t'%s'\n", issue[iss_no]->media[med_no]->preview_=
uri);
-		}
-		med_no =3D 0;
-	}
-}
-
 int findnewestiss(iss ** issue, int no_of_issues)
 /*	returns newest issue indice */
 {
@@ -377,18 +336,3 @@
=20
 	return new_iss;
 }
-
-void showusage()
-{
-	printf("Usage: getht -u -a -d -m -n -f [-t tocfile] -h -v\n");
-	printf("-u | --update                 Update contents files\n");
-	printf("-a | --download-all           Download all issues\n");
-	printf("-d | --download-latest        Download latest issue\n");
-	printf("-m | --download-all-media     Download all media\n");
-	printf("-n | --download-latest-media  Download latest issue's media\n");
-	printf("-f | --force                  Force re-download of existing files=
\n");
-	printf("-t | --tocfile file           Use alternative contents xml file\n=
");
-	printf("-x | --mediatocfile file      Use alternative media contents xml =
file\n");
-	printf("-h | --help                   Print this help message\n");
-	printf("-v | --version                Print version information\n");
-}


--- orig/src/issue.h
+++ mod/src/issue.h
@@ -66,7 +66,7 @@
 	int no_of_media;
 } iss;
=20
-iss ** parsetoc(char *filepath, int * iss_no, int * latest);
+iss ** parsetoc(char *filepath, int * iss_no);
 iss ** parsemedia(char * filepath, iss ** issue, int * no_of_issues);
=20
 med ** parsemediagz(char * media_path, int * no_of_media);


--- orig/src/tocxml.c
+++ mod/src/tocxml.c
@@ -28,15 +28,15 @@
 #include "issue.h"
 #include "getht.h"
=20
-iss ** parsetoc(char *filepath, int * iss_no, int * latest);
-int parseissue(xmlDocPtr file, xmlNodePtr node, iss * cur_issue, int * lat=
est);
+iss ** parsetoc(char *filepath, int * iss_no);
+int parseissue(xmlDocPtr file, xmlNodePtr node, iss * cur_issue);
 void parsesection(xmlDocPtr file, xmlNodePtr node, sec * cur_section);
=20
 void tokenise_hyphons(char to_token[10], int * first, int * last);
=20
 int no_of_issues;
=20
-iss ** parsetoc(char *filepath, int * iss_no, int * latest)
+iss ** parsetoc(char *filepath, int * iss_no)
 /*	starts parsing of xml to issue structure	*/
 {
 	xmlDocPtr file;
@@ -78,7 +78,7 @@
 							&(issue[no_of_issues]->date.lastmonth));
=20
 					/* parse the issue */
-					parseissue(file, cnode, issue[no_of_issues], latest);
+					parseissue(file, cnode, issue[no_of_issues]);
 				}
 				cnode =3D cnode->next;
 			}
@@ -95,15 +95,12 @@
 	return issue;
 }
=20
-int parseissue(xmlDocPtr file, xmlNodePtr node, iss * cur_issue, int * lat=
est)
+int parseissue(xmlDocPtr file, xmlNodePtr node, iss * cur_issue)
 /*	parses issue from xml, saving in cur_issue structure	*/
 {
 	strncpy(cur_issue->title, (char *) xmlGetProp(node, "title"), STR_MAX);
 	strncpy(cur_issue->preview_uri, (char *) xmlGetProp(node, "coverlink"), S=
TR_MAX);
=20
-	if(xmlGetProp(node, "current") && *latest=3D=3D-1)
-		*latest =3D no_of_issues;
-
 	node =3D node->xmlChildrenNode;
=20
 	while(node !=3D NULL){


--- orig/src/version.h
+++ mod/src/version.h
@@ -19,4 +19,4 @@
  *
  */
=20
-#define VERSION "0.0.1"
+#define VERSION "pre_release"



* added files

--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-23--getht@sv.gnu.org/new-files-archive/./.arch-ids/prepar=
e-package.sh.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Thu May  3 15:21:05 2007 12700.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-23--getht@sv.gnu.org/new-files-archive/./prepare-package.=
sh
@@ -0,0 +1,64 @@
+#!/bin/bash
+#
+# Copyright 2006 Nick White
+#
+# This file is part of GetHT
+#=20
+# GetHT is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# GetHT is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GetHT; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  U=
SA
+
+TMPDIR=3D"/tmp"
+ORIGDIR=3D$(pwd)
+
+VERSION=3D$(gawk -F \" '{print $2}' src/version.h | \
+	sed -e ':a;N;$!ba;s/\n//g')
+
+echo Packaging GetHT version $VERSION
+
+echo Copying sources to a temporary directory
+rm -rf $TMPDIR/getht-$VERSION && \
+mkdir $TMPDIR/getht-$VERSION && \
+cp -R * $TMPDIR/getht-$VERSION && \
+cd $TMPDIR/getht-$VERSION
+
+echo Removing Arch metadata
+rm -rf \{arch\}
+rm -rf .arch_ids
+rm -f ++log.getht*
+
+# ensure version number in configure.in is set correctly
+sed -i "s|^AC_INIT(getht, .*)$|AC_INIT(getht, $VERSION)|" configure.in
+
+echo Building necessary autotools parts
+autoreconf -i
+
+echo Cleaning make environment
+make clean
+
+echo Cleaning up working directory
+rm -rf autom4te.cache
+rm prepare-package.sh
+
+echo Packaging into a tarball
+cd ..
+tar -cjf getht-$VERSION.tar.bz2 getht-$VERSION
+
+echo Removing temporary directory
+rm -rf getht-$VERSION
+
+cd $ORIGDIR
+mv $TMPDIR/getht-$VERSION.tar.bz2 .
+
+echo "Packaging of GetHT $VERSION complete."
+echo "The tarball resides at ./getht-$VERSION.tar.bz2"
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-23--getht@sv.gnu.org/new-files-archive/./src/.arch-ids/cl=
i.c.id
@@ -0,0 +1 @@
+Nick White <arch@njw.me.uk> Thu May  3 17:57:09 2007 26612.0
--- /dev/null
+++ /home/nick/programming/c/getht/getht-mainline/,,what-changed.getht--mai=
nline--0.1--patch-23--getht@sv.gnu.org/new-files-archive/./src/cli.c
@@ -0,0 +1,99 @@
+/*
+ * Copyright 2006 Nick White
+ *
+ * This file is part of GetHT
+ *=20
+ * GetHT is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * GetHT is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with GetHT; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  =
USA
+ *
+ */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include "issue.h"
+#include "getht.h"
+
+void list_issues(iss ** issue, int no_of_issues, int verbose)
+{
+	int iss_no, sec_no, it_no;
+	for(iss_no=3D0;iss_no<=3Dno_of_issues;iss_no++)
+	{
+		printf("[%i]\t", iss_no);
+		printf("%s\n", issue[iss_no]->title);
+		if(verbose >=3D 1)
+		{
+			for(sec_no=3D0; sec_no<=3Dissue[iss_no]->no_of_sections; sec_no++)
+			{
+				printf("\t%i: %s\n", issue[iss_no]->section[sec_no]->number,
+					issue[iss_no]->section[sec_no]->title);
+				printf("\t%s\n", issue[iss_no]->section[sec_no]->uri);
+				if(verbose >=3D 2)
+				{
+					for(it_no=3D0;
+						it_no<=3Dissue[iss_no]->section[sec_no]->no_of_items;
+						it_no++)
+					{
+						printf("\t\tpp %i - %i: %s\n",
+							issue[iss_no]->section[sec_no]->item[it_no]->firstpage,
+							issue[iss_no]->section[sec_no]->item[it_no]->lastpage,
+							issue[iss_no]->section[sec_no]->item[it_no]->title);
+					}
+				}
+			}
+		}
+	}
+}
+
+void list_media(iss ** issue, int no_of_issues, int verbose)
+{
+	int iss_no, med_no, med_global;
+	for(iss_no=3D0, med_global=3D0;iss_no<=3Dno_of_issues;iss_no++)
+	{
+		if(issue[iss_no]->no_of_media >=3D 0)
+		{
+			printf("%s\n", issue[iss_no]->title);
+			for(med_no=3D0; med_no <=3D (issue[iss_no]->no_of_media); med_no++, med=
_global++)
+			{
+				printf("[%i]\t", med_global);
+				printf("%s\n", issue[iss_no]->media[med_no]->title);
+				if(verbose >=3D 1)
+				{
+					printf("\t%s\n", issue[iss_no]->media[med_no]->uri);
+					if(verbose >=3D2 && issue[iss_no]->media[med_no]->comment[0]!=3D'\0')
+							printf("\t%s\n", issue[iss_no]->media[med_no]->comment);
+				}
+			}
+		}
+	}
+}
+
+void showusage()
+{
+	printf("Usage: getht [-ualmofhv] [-d issno] [-n medno] [-t tocfile]\n");
+	printf("-u | --update                 Update contents files\n");
+	printf("-a | --download-all           Download all issues\n");
+	printf("-d | --download-issue issno   Download issue number issno\n");
+	printf("-n | --download-media medno   Download media number n\n");
+	printf("-o | --download-all-media     Download all media\n");
+	printf("-f | --force                  Force re-download of existing files=
\n");
+	printf("-l | --list-issues            List available issues\n");
+	printf("-m | --list-media             List available media\n");
+	printf("-t | --tocfile file           Use alternative contents xml file\n=
");
+	printf("-x | --mediatocfile file      Use alternative media contents xml =
file\n");
+	printf("-h | --help                   Print this help message\n");
+	printf("-v | --verbose                Make output more verbose\n");
+	printf("-V | --version                Print version information\n");
+}


--Nq2Wo0NMKNjxTN9z
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGOiFuH0hWdATkZT8RApnjAKC3hsh3owskZesrWdV9xZlFhV8AgQCgzwmK
XxjNxZOsWffdVwaSrt1cNN4=
=pYQ6
-----END PGP SIGNATURE-----

--Nq2Wo0NMKNjxTN9z--



From MAILER-DAEMON Thu May 03 14:33:45 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1Hjg7d-0000at-F7
	for mharc-getht-commit@gnu.org; Thu, 03 May 2007 14:33:45 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1Hjg7c-0000YR-2p
	for getht-commit@nongnu.org; Thu, 03 May 2007 14:33:44 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1Hjg7b-0000XX-At
	for getht-commit@nongnu.org; Thu, 03 May 2007 14:33:43 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1Hjg7b-0000XU-4d
	for getht-commit@nongnu.org; Thu, 03 May 2007 14:33:43 -0400
Received: from outmail136083.authsmtp.com ([62.13.136.83])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1Hjg12-0001Dn-Cw
	for getht-commit@nongnu.org; Thu, 03 May 2007 14:26:56 -0400
Received: from outmail128175.authsmtp.net (outmail128175.authsmtp.net
	[62.13.128.175])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l43IQrtP028038
	for <getht-commit@nongnu.org>; Thu, 3 May 2007 19:26:55 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l43IQqRY093735
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Thu, 3 May 2007 19:26:53 +0100 (BST)
Date: Thu, 3 May 2007 19:30:01 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070503183001.GA10413@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="3V7upXqbjpZ4EhLz"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: dddeb3e7-f9a3-11db-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcB AHl2Ch1LUl1xXnN0 YgBTaw9YYQRPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cucwY/GT8S DEZrXXdYWQp4c0Z6
	DBoAQThUZjJndTYW AUNFdgIAIh4behtG d1B/VXIFZDEEYX0z
	Fhk6JTsxdT5YLSFU XlNFIl8OQVpOWzs1 RhYGHDMiWAhdAXx2
	agQvNlUcWRxMWicA 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:646/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-25
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Thu, 03 May 2007 18:33:44 -0000


--3V7upXqbjpZ4EhLz
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Revision: getht--mainline--0.1--patch-25
Archive: getht@sv.gnu.org
Creator: Nick White <arch@njw.me.uk>
Date: Thu May  3 19:28:10 BST 2007
Standard-date: 2007-05-03 18:28:10 GMT
Modified-files: README configure.in doc/getht.man
New-patches: getht@sv.gnu.org/getht--mainline--0.1--patch-25
Summary: Altered bug/support urls in docs, corrected config version
Keywords:=20



M  doc/getht.man
M  README
M  configure.in

* modified files

--- orig/README
+++ mod/README
@@ -45,5 +45,5 @@
 or parts of the program which don't work as expected.
 If you encounter problems, there are several ways to get help:
  Mailing List    : http://lists.nongnu.org/mailman/listinfo/getht-general
- Support Tracker : http://savannah.nongnu.org/support/?group=3Dgetht
- Bug Tracker     : http://savannah.nongnu.org/bugs/?group=3Dgetht
+ Support Tracker : http://savannah.nongnu.org/support/?func=3Dadditem&grou=
p=3Dgetht
+ Bug Tracker     : http://savannah.nongnu.org/bugs/?func=3Dadditem&group=
=3Dgetht


--- orig/configure.in
+++ mod/configure.in
@@ -2,7 +2,7 @@
 # Process this file with autoconf to produce a configure script.
=20
 AC_PREREQ(2.61)
-AC_INIT(getht, 0.0.1)
+AC_INIT(getht, pre_release)
 AC_CONFIG_SRCDIR([src/])
 AC_CONFIG_AUX_DIR([config])
 AC_CONFIG_HEADER([config.h])


--- orig/doc/getht.man
+++ mod/doc/getht.man
@@ -153,10 +153,10 @@
 .I http://lists.nongnu.org/mailman/listinfo/getht-general
 .TP
 .B Support Tracker=20
-.I http://savannah.nongnu.org/support/?group=3Dgetht
+.I http://savannah.nongnu.org/support/?func=3Dadditem&group=3Dgetht
 .TP
 .B Bug Tracker
-.I http://savannah.nongnu.org/bugs/?group=3Dgetht
+.I http://savannah.nongnu.org/bugs/?func=3Dadditem&group=3Dgetht
=20
 .SH LICENSE
 Copyright 2007 Nick White




--3V7upXqbjpZ4EhLz
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGOiopH0hWdATkZT8RAsoaAJ0fd5A7oFO/25zIJiv9KvBVoYoRTQCgjzT1
KK5IJjwGjwMpKdvusUJbhs0=
=EfMU
-----END PGP SIGNATURE-----

--3V7upXqbjpZ4EhLz--



From MAILER-DAEMON Sat May 05 14:46:19 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1HkPGt-0006ty-Qk
	for mharc-getht-commit@gnu.org; Sat, 05 May 2007 14:46:19 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1HkPGs-0006tT-GB
	for getht-commit@nongnu.org; Sat, 05 May 2007 14:46:18 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1HkPGq-0006sZ-AW
	for getht-commit@nongnu.org; Sat, 05 May 2007 14:46:18 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1HkPGq-0006sT-5E
	for getht-commit@nongnu.org; Sat, 05 May 2007 14:46:16 -0400
Received: from outmail136079.authsmtp.co.uk ([62.13.136.79])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1HkPA3-0004t3-Gj
	for getht-commit@nongnu.org; Sat, 05 May 2007 14:39:15 -0400
Received: from outmail128183.authsmtp.com (outmail128183.authsmtp.com
	[62.13.128.183])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l45IdDB7018874
	for <getht-commit@nongnu.org>; Sat, 5 May 2007 19:39:13 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l45Id8ri037519
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Sat, 5 May 2007 19:39:09 +0100 (BST)
Date: Sat, 5 May 2007 19:42:00 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070505184200.GA32639@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="IJpNTDwzlM2Ie8A6"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: e971b2ea-fb37-11db-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcB Bnl2Ch1LUl1xXnN0 YgBSZA9dawRPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cucwA/LHYy PEZhWXVaVQp4ckJ0
	DBtdEmxUZzIxdTZN U0dFdgIAIh4behtG d1B/VXIFZDEEYX0z
	Fhk6JTsxdT5YLSFU XlNFIl8OQVpOWzs1 RhYGHDMiWAhdAXx2
	agQvNlUcWRxPWicA 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:646/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-26
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Sat, 05 May 2007 18:46:18 -0000


--IJpNTDwzlM2Ie8A6
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Revision: getht--mainline--0.1--patch-26
Archive: getht@sv.gnu.org
Creator: Nick White <arch@njw.me.uk>
Date: Sat May  5 19:41:23 BST 2007
Standard-date: 2007-05-05 18:41:23 GMT
Modified-files: src/cli.c src/mediaxml.c
New-patches: getht@sv.gnu.org/getht--mainline--0.1--patch-26
Summary: Fixed media sorting bug, added date view to listings
Keywords:=20

Fixed bug causing issues containing only media to not be sorted
correctly
Added display of issue date when -vv is passed with -l or -m
M  src/cli.c
M  src/mediaxml.c

* modified files

--- orig/src/cli.c
+++ mod/src/cli.c
@@ -33,6 +33,8 @@
 	{
 		printf("[%i]\t", iss_no);
 		printf("%s\n", issue[iss_no]->title);
+		if(verbose >=3D 2)
+			printf("Year: %i; Months: %i - %i\n",issue[iss_no]->date.year,issue[iss=
_no]->date.firstmonth,issue[iss_no]->date.lastmonth);
 		if(verbose >=3D 1)
 		{
 			for(sec_no=3D0; sec_no<=3Dissue[iss_no]->no_of_sections; sec_no++)
@@ -65,6 +67,8 @@
 		if(issue[iss_no]->no_of_media >=3D 0)
 		{
 			printf("%s\n", issue[iss_no]->title);
+			if(verbose >=3D 2)
+				printf("Year: %i; Months: %i - %i\n",issue[iss_no]->date.year,issue[is=
s_no]->date.firstmonth,issue[iss_no]->date.lastmonth);
 			for(med_no=3D0; med_no <=3D (issue[iss_no]->no_of_media); med_no++, med=
_global++)
 			{
 				printf("[%i]\t", med_global);
@@ -72,8 +76,11 @@
 				if(verbose >=3D 1)
 				{
 					printf("\t%s\n", issue[iss_no]->media[med_no]->uri);
-					if(verbose >=3D2 && issue[iss_no]->media[med_no]->comment[0]!=3D'\0')
+					if(verbose >=3D2)
+					{
+						if(issue[iss_no]->media[med_no]->comment[0]!=3D'\0')
 							printf("\t%s\n", issue[iss_no]->media[med_no]->comment);
+					}
 				}
 			}
 		}


--- orig/src/mediaxml.c
+++ mod/src/mediaxml.c
@@ -240,7 +240,7 @@
=20
 	xmlFreeDoc(media_file);
=20
-	issuesort(issue, no_of_issues);
+	issuesort(issue, *no_of_issues);
=20
 	return issue;
 }




--IJpNTDwzlM2Ie8A6
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGPM/3H0hWdATkZT8RAlZkAJ9GFS7yaNai8rHwg6wpeHONuE+Y+ACgyOTg
m+DVnS9eUhaaS+PfvG6LrIc=
=crf6
-----END PGP SIGNATURE-----

--IJpNTDwzlM2Ie8A6--



From MAILER-DAEMON Mon May 07 20:28:05 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1HlDYj-0002lc-HA
	for mharc-getht-commit@gnu.org; Mon, 07 May 2007 20:28:05 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1HlDYh-0002kT-87
	for getht-commit@nongnu.org; Mon, 07 May 2007 20:28:03 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1HlDYf-0002kH-QW
	for getht-commit@nongnu.org; Mon, 07 May 2007 20:28:02 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1HlDYf-0002kE-Lt
	for getht-commit@nongnu.org; Mon, 07 May 2007 20:28:01 -0400
Received: from outmail129144.authsmtp.net ([62.13.129.144])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1HlDRd-0008IZ-CN
	for getht-commit@nongnu.org; Mon, 07 May 2007 20:20:45 -0400
Received: from outmail128185.authsmtp.co.uk (outmail128185.authsmtp.co.uk
	[62.13.128.185])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l480Kgrk025732
	for <getht-commit@nongnu.org>; Tue, 8 May 2007 01:20:42 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l480KfFB086320
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Tue, 8 May 2007 01:20:41 +0100 (BST)
Date: Tue, 8 May 2007 01:23:57 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070508002357.GA15085@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="yrj/dFKFPuw6o+aM"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: f4a922e0-fcf9-11db-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcB C3l2Ch1LUl1xXnN1 agBTbQ9ZYwRPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cucw1GAygG F0ZqWHNZXAp7c098
	DBhQRGQEZzJgdTZM BklFdgIAIh4behtG d1B/VXIFZDEEYX0z
	Fhk6JTsxdT5YLSFU XlNFIl8OQVpOWzs1 RhYGHDMiWAhdAXx2
	agQvNlUcWRxOWicA 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:646/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-27
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Tue, 08 May 2007 00:28:03 -0000


--yrj/dFKFPuw6o+aM
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Revision: getht--mainline--0.1--patch-27
Archive: getht@sv.gnu.org
Creator: Nick White <arch@njw.me.uk>
Date: Tue May  8 01:23:05 BST 2007
Standard-date: 2007-05-08 00:23:05 GMT
Modified-files: configure.in src/version.h
New-patches: getht@sv.gnu.org/getht--mainline--0.1--patch-27
Summary: Bumped version number for 0.0.1 release
Keywords:=20



M  src/version.h
M  configure.in

* modified files

--- orig/configure.in
+++ mod/configure.in
@@ -2,7 +2,7 @@
 # Process this file with autoconf to produce a configure script.
=20
 AC_PREREQ(2.61)
-AC_INIT(getht, pre_release)
+AC_INIT(getht, 0.0.1)
 AC_CONFIG_SRCDIR([src/])
 AC_CONFIG_AUX_DIR([config])
 AC_CONFIG_HEADER([config.h])


--- orig/src/version.h
+++ mod/src/version.h
@@ -19,4 +19,4 @@
  *
  */
=20
-#define VERSION "pre_release"
+#define VERSION "0.0.1"




--yrj/dFKFPuw6o+aM
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGP8MdH0hWdATkZT8RAuf7AJ9xRLPPPbTjX1mZXo0mDWZisreoxACgpG4t
Dkj4xY9eaqi6L37JI5qSLhQ=
=nFrz
-----END PGP SIGNATURE-----

--yrj/dFKFPuw6o+aM--



From MAILER-DAEMON Tue May 08 20:47:31 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1HlaL5-0004gP-6C
	for mharc-getht-commit@gnu.org; Tue, 08 May 2007 20:47:31 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1HlaL3-0004gK-UH
	for getht-commit@nongnu.org; Tue, 08 May 2007 20:47:29 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1HlaL3-0004ft-02
	for getht-commit@nongnu.org; Tue, 08 May 2007 20:47:29 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1HlaL2-0004fq-Qd
	for getht-commit@nongnu.org; Tue, 08 May 2007 20:47:28 -0400
Received: from outmail136069.authsmtp.net ([62.13.136.69])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1HlaDt-0005p7-JP
	for getht-commit@nongnu.org; Tue, 08 May 2007 20:40:05 -0400
Received: from outmail128181.authsmtp.net (outmail128181.authsmtp.net
	[62.13.128.181])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l490e3NO085249
	for <getht-commit@nongnu.org>; Wed, 9 May 2007 01:40:03 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l490e09Y018119
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Wed, 9 May 2007 01:40:00 +0100 (BST)
Date: Wed, 9 May 2007 01:43:01 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070509004301.GA25260@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="ikeVEW9yuYc//A+q"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: d1edd5a7-fdc5-11db-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcB Cnl2Ch1LUl1xXnN1 agBVbQ9dYwRPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cucwxGLX55 DEZjVnFaVQp7cER6
	DBpVQDlSYDZndTZL A0VFdgIAIh4behtG d1B/VXIFZDEEYX0z
	Fhk6JTsxdT5YLSFU XlNFIl8OQVpOWzs1 RhYGHDMiWAhdAXx2
	agQvNlUcWRxBWicA 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:646/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-28
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Wed, 09 May 2007 00:47:30 -0000


--ikeVEW9yuYc//A+q
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

M  prepare-package.sh
M  ChangeLog
=3D> .arch-ids/configure.in.id	.arch-ids/configure.ac.id
=3D> configure.in	configure.ac

* modified files

--- orig/ChangeLog
+++ mod/ChangeLog
@@ -1 +0,0 @@
-2006-08: pre-release


--- orig/prepare-package.sh
+++ mod/prepare-package.sh
@@ -37,8 +37,8 @@
 rm -rf .arch_ids
 rm -f ++log.getht*
=20
-# ensure version number in configure.in is set correctly
-sed -i "s|^AC_INIT(getht, .*)$|AC_INIT(getht, $VERSION)|" configure.in
+# ensure version number in configure.ac is set correctly
+sed -i "s|^AC_INIT(getht, .*)$|AC_INIT(getht, $VERSION)|" configure.ac
=20
 echo Building necessary autotools parts
 autoreconf -i




--ikeVEW9yuYc//A+q
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGQRkUH0hWdATkZT8RAuX2AKDEZf3IN80J33s+ItgUHUy2UNGiTACgviAo
izTpb/FGHpy0Zvat7nFyKiQ=
=GoXQ
-----END PGP SIGNATURE-----

--ikeVEW9yuYc//A+q--



From MAILER-DAEMON Sat May 26 18:16:03 2007
Received: from mailman by lists.gnu.org with archive (Exim 4.43)
	id 1Hs4YN-0005g2-6l
	for mharc-getht-commit@gnu.org; Sat, 26 May 2007 18:16:03 -0400
Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43)
	id 1Hs4YL-0005e9-9a
	for getht-commit@nongnu.org; Sat, 26 May 2007 18:16:01 -0400
Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43)
	id 1Hs4YK-0005be-4j
	for getht-commit@nongnu.org; Sat, 26 May 2007 18:16:00 -0400
Received: from [199.232.76.173] (helo=monty-python.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.43) id 1Hs4YJ-0005bO-WA
	for getht-commit@nongnu.org; Sat, 26 May 2007 18:16:00 -0400
Received: from outmail136050.authsmtp.com ([62.13.136.50])
	by monty-python.gnu.org with esmtp (Exim 4.60)
	(envelope-from <nick@njw.me.uk>) id 1Hs4YJ-000308-Al
	for getht-commit@nongnu.org; Sat, 26 May 2007 18:15:59 -0400
Received: from outmail128182.authsmtp.co.uk (outmail128182.authsmtp.co.uk
	[62.13.128.182])
	by punt2.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l4QMFu8W006938
	for <getht-commit@nongnu.org>; Sat, 26 May 2007 23:15:56 +0100 (BST)
Received: from localhost ([194.80.176.253]) (authenticated bits=0)
	by mail.authsmtp.com (8.13.8/8.13.8/Kp) with ESMTP id l4QMFqBn083260
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <getht-commit@nongnu.org>; Sat, 26 May 2007 23:15:52 +0100 (BST)
Date: Sat, 26 May 2007 23:19:37 +0100
From: Nick <nick@njw.me.uk>
To: getht-commit@nongnu.org
Message-ID: <20070526221937.GA10561@cutie1.lan>
Mail-Followup-To: getht-commit@nongnu.org
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="ibTvN161/egqYuK8"
Content-Disposition: inline
User-Agent: Mutt/1.5.13 (2006-08-11)
X-Server-Quench: aad13d72-0bd6-11dc-a443-001185d377ca
X-AuthRoute: OCdxYQ8WA1ZTTQ8Z IiUGE2lFREM4JQtD DAMDMU5RJ18MVBh5
	NEFcIVxOdloGSkcD BXl2Ch1LUl1xXnN3 aABQaA9YYQRPVgF0
	WEhXQ1VUCgdtAgMF ABsBU1cuc2Q7Dj8C O0ZqXXJdXAp8dUB7
	DB8FQWwFMWBidWBN BEZFdgIAIx4behtG d1B/VXIFZDEEYX0z
	Fhk6JTsxdT5YLSFU XlNFIl8OQVpOWzs1 RhYGHDMiWAhdAXx2
	agQvNlUcWRxAWjMw 
X-Authentic-SMTP: 61633231373330.squirrel.dmpriest.net.uk:671/Kp
X-Report-SPAM: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse
X-Virus-Status: No virus detected - but ensure you scan with your own
	anti-virus system!
X-detected-kernel: FreeBSD 6.x (1)
Subject: [Getht-commit] arch commit: getht--mainline--0.1--patch-29
X-BeenThere: getht-commit@nongnu.org
X-Mailman-Version: 2.1.5
Precedence: list
Reply-To: getht-general@nongnu.org
List-Id: Repository Commit List <getht-commit.nongnu.org>
List-Unsubscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=unsubscribe>
List-Archive: <http://lists.gnu.org/pipermail/getht-commit>
List-Post: <mailto:getht-commit@nongnu.org>
List-Help: <mailto:getht-commit-request@nongnu.org?subject=help>
List-Subscribe: <http://lists.nongnu.org/mailman/listinfo/getht-commit>,
	<mailto:getht-commit-request@nongnu.org?subject=subscribe>
X-List-Received-Date: Sat, 26 May 2007 22:16:01 -0000


--ibTvN161/egqYuK8
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Revision: getht--mainline--0.1--patch-29
Archive: getht@sv.gnu.org
Creator: Nick White <arch@njw.me.uk>
Date: Sat May 26 23:18:56 BST 2007
Standard-date: 2007-05-26 22:18:56 GMT
Modified-files: configure.ac doc/getht.man src/config.c
    src/getht.c
New-patches: getht@sv.gnu.org/getht--mainline--0.1--patch-29
Summary: General cleanup, Add alt url config options
Keywords:=20

Removed unused & unnecessary findnewestiss
Replaces strcpy with strncpy to eliminate possible buffer overruns
Added a couple of config options to allow use of alternative
toc urls
M  doc/getht.man
M  src/config.c
M  src/getht.c
M  configure.ac

* modified files

--- orig/configure.ac
+++ mod/configure.ac
@@ -22,6 +22,9 @@
 AM_PATH_XML2([2.0.0])
 CFLAGS=3D"$CFLAGS $XML_CPPFLAGS"
 LIBS=3D"$LIBS $XML_LIBS"
+#PKG_CHECK_MODULES(libxml-2.0)
+#AC_SUBST(XML_CPPFLAGS)
+#AC_SUBST(XML_LIBS)
=20
 dnl check for libcurl
 LIBCURL_CHECK_CONFIG([yes], [7.7.2])


--- orig/doc/getht.man
+++ mod/doc/getht.man
@@ -110,6 +110,16 @@
 time the GetHT is executed. \fB1\fR =3D yes, \fB0\fR =3D no
 The default setting is \fB0\fR
 .TP
+.B toc_url
+A url to the xml file containing the table of contents=20
+for the publication.
+Default: \fBhttp://www.hinduismtoday.com/digital/htde_toc.xml\fR
+.TP
+.B mediatoc_url
+A url to the rev.gz file listing the media included with=20
+the publication.
+Default: \fBhttp://www.hinduismtoday.com/digital/htde_media-player.rev.gz\=
fR
+.TP
 .B proxy_type
 The type of proxy (if any) through which GetHT is to
 pass. GetHT currently supports the following options:


--- orig/src/config.c
+++ mod/src/config.c
@@ -30,6 +30,8 @@
 extern proxyauth proxy_auth;
 extern char proxy_user[STR_MAX];
 extern char proxy_pass[STR_MAX];
+extern char issue_url[STR_MAX];
+extern char media_url[STR_MAX];
=20
 int loadconfig(char * htde_path, char * issue_path, int * update)
 /*	Loads variables from config file to extern and passed
@@ -56,6 +58,10 @@
 			strncpy(issue_path, parameter, STR_MAX);
 		else if(!strcmp(option, "startup_check"))
 			*update =3D atoi(parameter);
+		else if(!strcmp(option, "toc_url"))
+			strncpy(issue_url, parameter, STR_MAX);
+		else if(!strcmp(option, "mediatoc_url"))
+			strncpy(media_url, parameter, STR_MAX);
 		else if(!strcmp(option, "proxy_type"))
 		{
 			if(!strcmp(parameter, "http"))
@@ -117,6 +123,10 @@
 		fprintf(config_file, "%s =3D %s\n", "issuepath", issue_path);
 	if(update)
 		fprintf(config_file, "%s =3D %i\n", "startup_check", *update);
+	if(issue_url[0])
+		fprintf(config_file, "%s =3D %s\n", "toc_url", issue_url);
+	if(media_url[0])
+		fprintf(config_file, "%s =3D %s\n", "mediatoc_url", media_url);
 	if(proxy_type !=3D NONE)
 	{
 		if(proxy_type =3D HTTP)


--- orig/src/getht.c
+++ mod/src/getht.c
@@ -39,6 +39,7 @@
 proxyauth proxy_auth;=20
 char proxy_user[STR_MAX]; char proxy_pass[STR_MAX];
 char issue_xml[STR_MAX]; char media_xml[STR_MAX]; char media_rev[STR_MAX];
+char issue_url[STR_MAX]; char media_url[STR_MAX];
 CURL *main_curl_handle;=20
=20
 int main(int argc, char *argv[])
@@ -61,6 +62,9 @@
 	snprintf(media_xml,STR_MAX, "%s/%s", getht_path, MED_XML_FILE);
 	snprintf(media_rev,STR_MAX,"%s/%s",getht_path,MED_REVGZ_FILE);
=20
+	strncpy(issue_url,XML_TOC_URL,STR_MAX);
+	strncpy(media_url,MEDIA_TOC_URL,STR_MAX);
+
 	snprintf(save_path,STR_MAX,"%s/hinduism_today",getenv("HOME"));
=20
 	int downall =3D 0, downallmedia =3D 0;
@@ -78,7 +82,7 @@
 	proxy_pass[0] =3D '\0';
=20
 	if(loadconfig(getht_path, &save_path, &update) !=3D 0)
-		writefreshconfig(getht_path, &save_path, &update);
+		writefreshconfig(getht_path, &save_path, &update, &issue_url, &media_url=
);
=20
 	if(!opendir(save_path))
 		if(mkdir(save_path, S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH))
@@ -148,12 +152,10 @@
 				option =3D 1;
 				break;
 			case 't':
-				strcpy(issue_xml, strdup(optarg));
-				option =3D 1;
+				strncpy(issue_xml, strdup(optarg), STR_MAX);
 				break;
 			case 'x':
-				strcpy(media_xml, strdup(optarg));
-				option =3D 1;
+				strncpy(media_xml, strdup(optarg), STR_MAX);
 				break;
 			case 'h':
 				showusage();
@@ -277,7 +279,7 @@
 int update_contents_files()
 /* Returns 0 on success, 1 on failure */
 {
-	if(save_file(NULL, XML_TOC_URL, issue_xml))
+	if(save_file(NULL, issue_url, issue_xml))
 		return 1;
 =09
 	char isstitle[STR_MAX];
@@ -295,7 +297,7 @@
=20
 	if(media_accounted_for(media_xml, &date))
 	{
-		if(save_file(NULL, MEDIA_TOC_URL, media_rev))
+		if(save_file(NULL, media_url, media_rev))
 			return 1;
 =09
 		med ** temp_med;
@@ -310,29 +312,3 @@
=20
 	return 0;
 }
-
-int findnewestiss(iss ** issue, int no_of_issues)
-/*	returns newest issue indice */
-{
-	iss * tmp_issue; issdates newest;
-	int new_iss;
-
-	new_iss =3D -1;
-	newest.year =3D 0; newest.firstmonth =3D 0; newest.lastmonth =3D 0;
-
-	int i;
-
-	for(i =3D 0; i <=3D no_of_issues; i++)
-	{
-		if(issue[i]->date.year > newest.year ||
-			(issue[i]->date.year =3D=3D newest.year && issue[i]->date.firstmonth > =
newest.firstmonth))
-		{
-			newest.year =3D issue[i]->date.year;
-			newest.firstmonth =3D issue[i]->date.firstmonth;
-			newest.lastmonth =3D issue[i]->date.lastmonth;
-			new_iss =3D i;
-		}
-	}
-
-	return new_iss;
-}




--ibTvN161/egqYuK8
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFGWLJ5H0hWdATkZT8RAvAAAJ9rmhA71FFaCPdSvWGOO/QvnQllQACfZl3V
BVQuqX/K8IWjum5a5JldDSU=
=C8BS
-----END PGP SIGNATURE-----

--ibTvN161/egqYuK8--



