[pacman-dev] (no subject)

2011-02-25 Thread Dave Reisner
The ensuing patches revert Allan's breakage^Wchanges to the public API with regard to the introduction of pmpkghash_t. Since we haven't exposed any public facing API calls which can manipulate a pmpkghash_t, there's not much point in exposing the type along with it. alpm_db_get_pkgcache_list is re

[pacman-dev] [PATCH 1/2] alpm: remove public visibility of pmpkghash_t

2011-02-25 Thread Dave Reisner
There's no API functions exposed which allow manipulation of this type, so remove it from public view. Also, rename the public and private alpm_db_get_pkgcache symbol to alpm_db_get_pkgcache_has. Signed-off-by: Dave Reisner --- lib/libalpm/alpm.h|2 -- lib/libalpm/db.c |

[pacman-dev] [PATCH 2/2] alpm: alpm_db_get_pkgcache_list => alpm_db_get_pkgcache

2011-02-25 Thread Dave Reisner
This avoids needless breakage of the public API. Signed-off-by: Dave Reisner --- lib/libalpm/alpm.h |2 +- lib/libalpm/conflict.c |2 +- lib/libalpm/db.c| 12 ++-- lib/libalpm/db.h|2 +- lib/libalpm/deps.c |6 +++--- lib/libalpm/package.c

Re: [pacman-dev] Style questions and concerns

2011-02-25 Thread Dave Reisner
On Fri, Feb 25, 2011 at 10:27:13AM -0600, Dan McGee wrote: > I've noticed these things a lot in recent patches, so let the > discussion commence. > > 1) typedef-ed structs. This is just a "copy the rest of them" habit, > but I really feel we should stop doing this, only typedef-ing when we > are m

Re: [pacman-dev] [arch-dev-public] [signoff] pacman 3.5.0-1

2011-03-16 Thread Dave Reisner
On Wed, Mar 16, 2011 at 03:29:24PM -0500, Dan McGee wrote: > On Wed, Mar 16, 2011 at 3:26 PM, Aaron Griffin > wrote: > > On Wed, Mar 16, 2011 at 3:24 PM, Dan McGee wrote: > >> On Wed, Mar 16, 2011 at 3:18 PM, Gaetan Bisson > >> wrote: > >>> [2011-03-16 15:10:08 -0500] Dan McGee: > 2. This

[pacman-dev] [PATCH] Only read from stdin if sole target is '-'

2011-03-16 Thread Dave Reisner
This prevents a regression for people who enjoy piping yes to pacman to avoid prompts. Signed-off-by: Dave Reisner --- src/pacman/pacman.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/pacman/pacman.c b/src/pacman/pacman.c index 984bd1b..c66d34b 100644 --- a

Re: [pacman-dev] [GIT] The official pacman repository branch, master, updated. v3.5.0-18-ge6c9076

2011-03-16 Thread Dave Reisner
ee > Date: Wed Mar 16 19:25:35 2011 -0500 > > Merge branch 'download' > > commit f2eac18a6ec62db3ec53744064e05416024c1b30 > Author: Dave Reisner > Date: Tue Feb 8 21:05:53 2011 -0500 > > Remove all traces of libfetch > > Sign

Re: [pacman-dev] [PATCH] Use sane umask for repo db downloads

2011-03-18 Thread Dave Reisner
On Sat, Mar 19, 2011 at 11:24:22AM +1000, Allan McRae wrote: > Fixes FS#23343. > > Signed-off-by: Allan McRae > --- > lib/libalpm/be_sync.c |5 + > 1 files changed, 5 insertions(+), 0 deletions(-) > > diff --git a/lib/libalpm/be_sync.c b/lib/libalpm/be_sync.c > index 6c0d2d6..216213b 10

Re: [pacman-dev] change to option handling for --debug and -v

2011-03-19 Thread Dave Reisner
On Sat, Mar 19, 2011 at 12:10:58PM -0400, Ray Kohler wrote: > I noticed a change in the way 3.5 processes some of its command-line > flags: It used to be that --debug and -v were handled immediately, > such that their initial output appeared before pacman complained of a > usage error. Now, it erro

Re: [pacman-dev] [PATCH] Don't initialize progress to zero before calling curl_easy_perform().

2011-03-21 Thread Dave Reisner
On Mon, Mar 21, 2011 at 07:50:37AM -0500, Dan McGee wrote: > On Mon, Mar 21, 2011 at 5:53 AM, Lukas Fleischer > wrote: > > Drawing progress bars before calling curl_easy_perform() is needless as > > the curl progress callback is called with zero progress before actually > > downloading the file an

Re: [pacman-dev] [GIT] The official pacman repository branch, master, updated. v3.5.0-78-gf7b577d

2011-03-23 Thread Dave Reisner
On Wed, Mar 23, 2011 at 03:36:07AM -0400, Dan McGee wrote: > This is an automated email from the git hooks/post-receive script. It was > generated because a ref change was pushed to the repository containing > the project "The official pacman repository". > > The branch, master has been updated >

[pacman-dev] [RFC] Replacing wget with curl in makepkg

2011-03-23 Thread Dave Reisner
The attached patch proposes to replace wget with curl as the default DLAGENT in makepkg for http, https, and ftp. This seems like the sane choice given our switch from fetch to curl. dave >From 4e0ad1833fa5c8ef725ce3144e6318c397f60782 Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Wed, 16

[pacman-dev] [RFC] Proposed fix for FS#20538

2011-03-23 Thread Dave Reisner
001 From: Dave Reisner Date: Fri, 18 Mar 2011 11:03:28 -0400 Subject: [PATCH] pacman/util: flush terminal input before reading response Addresses FS#20538 Signed-off-by: Dave Reisner --- src/pacman/util.c | 17 + src/pacman/util.h |1 + 2 files changed, 18 insertions(+), 0 d

Re: [pacman-dev] [RFC] Proposed fix for FS#20538

2011-03-24 Thread Dave Reisner
On Thu, Mar 24, 2011 at 12:18:20AM -0500, Dan McGee wrote: > On Wed, Mar 23, 2011 at 10:41 AM, Dave Reisner wrote: > > https://bugs.archlinux.org/task/20538 > > > > The attached patch flushes the terminal input buffer shortly before > > prompting users for input to an

Re: [pacman-dev] pacman-key imports and key trust levels

2011-03-25 Thread Dave Reisner
On Fri, Mar 25, 2011 at 11:52:28PM -0400, Ray Kohler wrote: > On Fri, Mar 25, 2011 at 11:40 PM, Ray Kohler wrote: > > While I'm talking about signing stuff - I noticed an open question on > > what to do with the downloaded DB if sig verification fails. I suggest > > it be deleted, and the sig be d

[pacman-dev] [PATCH 1/4] lib/handle: add get/set methods for useragent

2011-03-28 Thread Dave Reisner
Signed-off-by: Dave Reisner --- lib/libalpm/alpm.h |3 +++ lib/libalpm/dload.c |4 ++-- lib/libalpm/handle.c | 15 +++ lib/libalpm/handle.h |1 + 4 files changed, 21 insertions(+), 2 deletions(-) diff --git a/lib/libalpm/alpm.h b/lib/libalpm/alpm.h index b08191d

[pacman-dev] [PATCH 0/4] addition of API methods and backend work

2011-03-28 Thread Dave Reisner
I've had the ensuing patches on my tree for a few days. A quick outline of what they accomplish: 1) Replace the old libfetch method of setting useragent (via an environment var) with proper get/set methods. 2) Refactor signature downloading to ensure that the sig file is downloaded from the same m

[pacman-dev] [PATCH 2/4] pacman: use alpm method to set useragent

2011-03-28 Thread Dave Reisner
The call for this needs to be done a little later now since it requires that the handle be initialized. Signed-off-by: Dave Reisner --- src/pacman/pacman.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/pacman/pacman.c b/src/pacman/pacman.c index eac9c9c

[pacman-dev] [PATCH 3/4] lib/dload: major refactor of signature downloading

2011-03-28 Thread Dave Reisner
which is passed through to curl_download_internal * move the actual signature download to curl_download_internal. this allows us to ensure that the signature and the file came from the same mirror, and only to accept the file if signature verification passes. Signed-off-by: Dave Reisner

[pacman-dev] [PATCH 4/4] Allow VerifySig to act as a default verification in [options]

2011-03-28 Thread Dave Reisner
* add _alpm_get_sigverify_level * add alpm_option_{get,set}_default_sigverify This requires moving around protos in alpm.h so that pgp_verify_t is known to the get/set methods for default_sigverify. Signed-off-by: Dave Reisner --- lib/libalpm/alpm.h| 36

Re: [pacman-dev] [PATCH 4/4] Allow VerifySig to act as a default verification in [options]

2011-03-28 Thread Dave Reisner
On Mon, Mar 28, 2011 at 09:34:57PM +0200, Rémy Oudompheng wrote: > On Mon 28 March 2011 at 15:15 -0400, Dave Reisner wrote: > > +/* GPG signature verification option */ > > +typedef enum _pgp_verify_t { > > + PM_PGP_VERIFY_UNKNOWN, > > + PM_PGP_VERIFY_ALWAYS, >

Re: [pacman-dev] Issues with strip on package sources

2011-04-08 Thread Dave Reisner
On Fri, Apr 08, 2011 at 10:10:19PM +1000, Allan McRae wrote: > On 08/04/11 21:57, Mathew de Detrich wrote: > >A problem that seems to be occurring on packages (typically on AUR) where > >makepkg using gnu's strip causes the package building process to fail (since > >/usr/bin/strip terminates with a

Re: [pacman-dev] Issues with strip on package sources

2011-04-08 Thread Dave Reisner
On Fri, Apr 08, 2011 at 10:20:53PM +1000, Allan McRae wrote: > On 08/04/11 22:12, Dave Reisner wrote: > >On Fri, Apr 08, 2011 at 10:10:19PM +1000, Allan McRae wrote: > >>On 08/04/11 21:57, Mathew de Detrich wrote: > >>>A problem that seems to be occurring on pac

Re: [pacman-dev] [PATCH 3/4] lib/dload: major refactor of signature downloading

2011-04-20 Thread Dave Reisner
On Wed, Apr 20, 2011 at 07:03:49PM -0500, Dan McGee wrote: > On Mon, Mar 28, 2011 at 2:15 PM, Dave Reisner wrote: > > There's a lot of related moving parts here: > > * iteration through mirrors is moved back to the calling functions. this > >  allows removal of _alp

[pacman-dev] [PATCH] trans.c: create transaction prior to checking DB version

2011-05-14 Thread Dave Reisner
leave behind a db.lck file. Signed-off-by: Dave Reisner --- lib/libalpm/trans.c | 19 ++- 1 files changed, 10 insertions(+), 9 deletions(-) diff --git a/lib/libalpm/trans.c b/lib/libalpm/trans.c index 4e88668..af1bcce 100644 --- a/lib/libalpm/trans.c +++ b/lib/libalpm/tr

Re: [pacman-dev] Finishing off the package signing issue -- Update

2011-05-30 Thread Dave Reisner
On Mon, May 30, 2011 at 04:43:02AM -0500, Kerrick Staley wrote: > All, > > I examined the code in pacman's git master branch, and I found that it > appears nearly finished. There are some issues, both blocking and > non-blocking. Note that the following statements are to be interpreted as > sugges

[pacman-dev] [PATCH 0/2] Minor tweaks to download code

2011-06-01 Thread Dave Reisner
Just a couple fixes for the download code. I'm not entirely convinced that the values hard coded in patch 2/2 are appropriate, so I'll say that its up for discussion. I know that we have folks who insist on using dial-up, so we need to be aware of this as well. Based on the source of curl, it seems

[pacman-dev] [PATCH 1/2] dload: abort transfer on CURLOPT_LOW_SPEED_LIMIT

2011-06-01 Thread Dave Reisner
If a connection drops below 10kb/s for 10s, curl will kill the transfer and we'll report failure. Signed-off-by: Dave Reisner --- lib/libalpm/dload.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/lib/libalpm/dload.c b/lib/libalpm/dload.c index d024c73..3d90130 1

[pacman-dev] [PATCH 2/2] lib/dload.c: remove assumption in continuation logic

2011-06-01 Thread Dave Reisner
Callers to curl_download_internal now tell us if its okay to continue a transfer, so obey this instead of using a heuristic. Signed-off-by: Dave Reisner --- lib/libalpm/dload.c |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/libalpm/dload.c b/lib/libalpm

Re: [pacman-dev] Does anyone use ALPM_LOG_FUNC?

2011-06-03 Thread Dave Reisner
On Fri, Jun 03, 2011 at 10:12:32AM -0500, Dan McGee wrote: > It isn't even enabled in non-debug builds, so this seems like a > not-so-useful feature as a debugger and/or a few printf() calls will > help you do anything this can, and will be a lot less crazy. If there > are no objections I'd like to

Re: [pacman-dev] [PATCH] makepkg: move option parsing code to separte file

2011-06-08 Thread Dave Reisner
On Wed, Jun 08, 2011 at 11:40:41PM +1000, Allan McRae wrote: > This move the getopt replacement function parse_options out of > makepkg.sh.in and into a separate file. The code is inserted > into the relevant place in makepkg using m4. > > This will allow the reuse of the option parsing code in o

[pacman-dev] [PATCH] dload: handle irregular URLs

2011-06-11 Thread Dave Reisner
pm on a -U operation, so callers of _alpm_download can optionally pass a pointer to a *char to be filled in by curl_download_internal with the actual filename we wrote to. Any sync operation will pass a NULL pointer here, as we rely on specific names for packages from a mirror. Fixes FS#22645. Signed-of

Re: [pacman-dev] [PATCH] dload: handle irregular URLs

2011-06-11 Thread Dave Reisner
On Sat, Jun 11, 2011 at 03:16:42PM -0400, Dave Reisner wrote: > URLs might end with a slash and follow redirects, or could be a > generated by a script such as /getpkg.php?id=12345. In both cases, we > may have a better filename that we can write to, taken from either > content-dispos

Re: [pacman-dev] [PATCH] Fix list_display on non-ttys and other output fixes

2011-06-13 Thread Dave Reisner
On Mon, Jun 13, 2011 at 05:11:11PM -0500, Dan McGee wrote: > commit c1f742d7750a14 broke what was one of the tenants of out output- > if piping pacman output somewhere else, we shouldn't ever try to > line-wrap and indent print our output. This makes it easier for tools to > use output from pacman

[pacman-dev] [PATCH] pacman/util.c: support terminals with unknown width

2011-06-14 Thread Dave Reisner
Fall back on the default passed to getcols when we encounter a device attached to stdout that reports itself as being a tty but which has no width. This is only (currently) known to affect serial consoles, which have a legitimate size of 80x24. Signed-off-by: Dave Reisner --- So this seems to

[pacman-dev] [PATCH] lib/util: call _alpm_log before setting handle->pm_errno

2011-06-18 Thread Dave Reisner
d-off-by: Dave Reisner --- Awesome bug. Here's what happens when the DB is locked: $ sudo pacman -Sy :: Synchronizing package databases... error: failed to init transaction (unexpected error) I'm still not sure why CHECK_HANDLE will always reset handle->pm_errno. Seems like it&#

[pacman-dev] [PATCH] repo-add: reuse write_list_entry for desc file

2011-06-20 Thread Dave Reisner
Repurpose the write_list_entry function for everything we write to the depends and desc files by appending our own extra newline after each single line data point. This also refactors write_list_entry into a single printf statement. Signed-off-by: Dave Reisner --- More repo-add madness

[pacman-dev] [PATCH] repo-add.8.txt: document valid DB file extensions

2011-06-20 Thread Dave Reisner
Signed-off-by: Dave Reisner --- This isn't documented anywhere except in the code, and every few months when I end up having to test something that requires my own repo, it takes me 10 minutes to figure out wtf a valid file extension is. d doc/repo-add.8.txt |4 1 files chang

Re: [pacman-dev] [PATCH] repo-add: reuse write_list_entry for desc file

2011-06-20 Thread Dave Reisner
On Mon, Jun 20, 2011 at 01:27:07PM -0500, Dan McGee wrote: > On Mon, Jun 20, 2011 at 1:12 PM, Dave Reisner wrote: > > Repurpose the write_list_entry function for everything we write to the > > depends and desc files by appending our own extra newline after each > > s

[pacman-dev] [PATCH 0/3] repo-add desc/depends creation cleanup

2011-06-20 Thread Dave Reisner
m happy to refactor if it would make you more comfortable. I know it's an insanely important code path so I encourage you (and anyone else reading) to put on your nerd glasses and nitpick this. Dave Reisner (3): repo-add: bashify reading of .PKGINFO file repo-add: store multi-value fields a

[pacman-dev] [PATCH 3/3] repo-add: use format_entry for all desc/depends fields

2011-06-20 Thread Dave Reisner
This ranks high on the code readability scale. The same function formats all of our data and writes to the metadata file at once. --- scripts/repo-add.sh.in | 52 --- 1 files changed, 27 insertions(+), 25 deletions(-) diff --git a/scripts/repo-add.sh.

[pacman-dev] [PATCH 1/3] repo-add: bashify reading of .PKGINFO file

2011-06-20 Thread Dave Reisner
grep and sed aren't needed here, and this removes the truly ugly manipulation of IFS. The process substituion could just as well be a herestring, but it breaks vim's syntax highlighting. Style over substance, mang. Signed-off-by: Dave Reisner --- scripts/repo-add.sh

[pacman-dev] [PATCH 2/3] repo-add: store multi-value fields as arrays

2011-06-20 Thread Dave Reisner
Fields like groups and depends should be stored as arrays. This requires rewriting our write_list_entry function to accomodate our new data type. This new function will not write to a file, but rather only format it. Signed-off-by: Dave Reisner --- scripts/repo-add.sh.in | 46

Re: [pacman-dev] [PATCH 3/3] repo-add: use format_entry for all desc/depends fields

2011-06-20 Thread Dave Reisner
On Mon, Jun 20, 2011 at 03:46:34PM -0400, Dave Reisner wrote: > This ranks high on the code readability scale. The same function formats > all of our data and writes to the metadata file at once. > --- > scripts/repo-add.sh.in | 52 --

Re: [pacman-dev] [PATCH] repo-add.8.txt: document valid DB file extensions

2011-06-20 Thread Dave Reisner
On Mon, Jun 20, 2011 at 06:30:29PM -0400, Eric Bélanger wrote: > On Mon, Jun 20, 2011 at 2:15 PM, Dave Reisner wrote: > > Signed-off-by: Dave Reisner > > --- > > This isn't documented anywhere except in the code, and every few months > > when I > > end up

Re: [pacman-dev] [PATCH] repo-add.8.txt: document valid DB file extensions

2011-06-21 Thread Dave Reisner
On Tue, Jun 21, 2011 at 11:38:58AM -0500, Dan McGee wrote: > On Mon, Jun 20, 2011 at 6:08 PM, Dave Reisner wrote: > > On Mon, Jun 20, 2011 at 06:30:29PM -0400, Eric Bélanger wrote: > >> On Mon, Jun 20, 2011 at 2:15 PM, Dave Reisner wrote: > >> &g

Re: [pacman-dev] [PATCH 0/3] repo-add desc/depends creation cleanup

2011-06-22 Thread Dave Reisner
On Wed, Jun 22, 2011 at 06:05:06PM +1000, Allan McRae wrote: > On 21/06/11 05:46, Dave Reisner wrote: > >This is basically what I referred to in my last patch about refactoring > >desc/depends writing. I snuck in an extra winner (the first) to get rid > >of the insane IFS twea

[pacman-dev] [PATCH 5/9] repo-add: enforce file extensions

2011-06-22 Thread Dave Reisner
Allow one of 4 archive extensions: .tar{,.gz,.xz,.bz2} for each of the 2 valid repo extensions: .db and .files Signed-off-by: Dave Reisner --- scripts/repo-add.sh.in |8 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/repo-add.sh.in b/scripts/repo-add.sh.in

[pacman-dev] [PATCH 0/9] repo-add cleanup

2011-06-22 Thread Dave Reisner
suite love. d Dave Reisner (9): repo-add: bashify reading of .PKGINFO file repo-add: store multi-value fields as arrays repo-add: use format_entry for all desc/depends fields repo-add.8.txt: document valid DB file extensions repo-add: enforce file extensions repo-add: fix path designa

[pacman-dev] [PATCH 1/9] repo-add: bashify reading of .PKGINFO file

2011-06-22 Thread Dave Reisner
grep and sed aren't needed here, and this removes the truly ugly manipulation of IFS. The process substituion could just as well be a herestring, but it breaks vim's syntax highlighting. Style over substance, mang. Signed-off-by: Dave Reisner --- scripts/repo-add.sh

[pacman-dev] [PATCH 7/9] repo-add: avoid using ls to check for presence of files

2011-06-22 Thread Dave Reisner
Signed-off-by: Dave Reisner --- scripts/repo-add.sh.in |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/repo-add.sh.in b/scripts/repo-add.sh.in index 029e17d..e75055f 100644 --- a/scripts/repo-add.sh.in +++ b/scripts/repo-add.sh.in @@ -593,7 +593,7 @@ if

[pacman-dev] [PATCH 6/9] repo-add: fix path designation regression

2011-06-22 Thread Dave Reisner
b899099 made path checking a bit more strict than I had intended, and would actually forbid creation of a repo in $PWD if only the filename was specified. readlink would be the fun and easy solution here, but it's avoided due to portability issues, making the validation process a bit more verbose.

[pacman-dev] [PATCH 9/9] repo-add: allow specifying symlink as repo file

2011-06-22 Thread Dave Reisner
If the repo file already exists, we allow specifying the symlink instead of the tarball itself. Signed-off-by: Dave Reisner --- I'm fairly sure this is a safe use of readlink, since it doesn't involve any of the flags for canonicalizing paths. I was able to test it on OSX with gre

[pacman-dev] [PATCH 2/9] repo-add: store multi-value fields as arrays

2011-06-22 Thread Dave Reisner
Fields like groups and depends should be stored as arrays. This requires rewriting our write_list_entry function to accomodate our new data type. This new function will not write to a file, but rather only format it. Signed-off-by: Dave Reisner --- scripts/repo-add.sh.in | 50

[pacman-dev] [PATCH 3/9] repo-add: use format_entry for all desc/depends fields

2011-06-22 Thread Dave Reisner
This ranks high on the code readability scale. The same function formats all of our data and writes to the metadata file at once. Signed-off-by: Dave Reisner --- scripts/repo-add.sh.in | 46 -- 1 files changed, 24 insertions(+), 22 deletions

[pacman-dev] [PATCH 4/9] repo-add.8.txt: document valid DB file extensions

2011-06-22 Thread Dave Reisner
Signed-off-by: Dave Reisner --- doc/repo-add.8.txt |4 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/doc/repo-add.8.txt b/doc/repo-add.8.txt index 0196882..36855af 100644 --- a/doc/repo-add.8.txt +++ b/doc/repo-add.8.txt @@ -29,6 +29,10 @@ command line. delta specified

Re: [pacman-dev] [PATCH 0/9] repo-add cleanup

2011-06-22 Thread Dave Reisner
On Wed, Jun 22, 2011 at 08:38:44PM -0400, Dave Reisner wrote: > Sigh. This started as a simple addition to the man page to document valid file > extensions, and look what happened. The first 4 patches are a resend -- I've > fixed > the 2 blockers that Allan pointed out, the w

[pacman-dev] Fwd: [PATCH 8/9] repo-add: move command invocation out of arg parsing loop

2011-06-23 Thread Dave Reisner
Forwarding this, as it seems to have been eaten by gmail as well on the initial send... d - Forwarded message from Dave Reisner - > Date: Wed, 22 Jun 2011 20:38:52 -0400 > From: Dave Reisner > To: pacman-dev@archlinux.org > Cc: Dave Reisner > Subject: [PATCH 8/9]

Re: [pacman-dev] [PATCH 7/9] repo-add: avoid using ls to check for presence of files

2011-06-23 Thread Dave Reisner
On Thu, Jun 23, 2011 at 11:06:45PM -0500, Dan McGee wrote: > On Wed, Jun 22, 2011 at 7:38 PM, Dave Reisner wrote: > > I agree with the commit message, but damn is this ugly. Can't we drop > the whole nullglob bit and just do something like: > > contents=* > if [

[pacman-dev] [PATCH] makepkg: fix incorrect parenthesis in gettext call

2011-06-24 Thread Dave Reisner
allan broke it in 4bdb868a. Signed-off-by: Dave Reisner --- scripts/makepkg.sh.in |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index e101a76..3d40bc1 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in

Re: [pacman-dev] [PATCH] makepkg: fix incorrect parenthesis in gettext call

2011-06-24 Thread Dave Reisner
On Fri, Jun 24, 2011 at 10:43:00PM +1000, Allan McRae wrote: > On 24/06/11 22:39, Dave Reisner wrote: > >allan broke it in 4bdb868a. > > > >Signed-off-by: Dave Reisner > >--- > > scripts/makepkg.sh.in |2 +- > > 1 files changed, 1 insertions(+), 1 d

Re: [pacman-dev] [PATCH] makepkg: fix incorrect parenthesis in gettext call

2011-06-24 Thread Dave Reisner
On Fri, Jun 24, 2011 at 10:47:58PM +1000, Allan McRae wrote: > On 24/06/11 22:43, Allan McRae wrote: > >On 24/06/11 22:39, Dave Reisner wrote: > >>allan broke it in 4bdb868a. > >> > >>Signed-off-by: Dave Reisner > >>--- > >>scripts/makepk

[pacman-dev] [PATCH] repo-add: add new command, repo-elephant

2011-06-24 Thread Dave Reisner
__ / \__/ \_ / / \ \`\ ) \''/ ( |\ `\__)/__/'_\ / ` //_|_|~|_|_| ^""'"' ""'"' Signed-off-by: Dave Reisner --- An elephant never forgets... or forgives... scripts/Makefile.am|7 +++

Re: [pacman-dev] [PATCH 1/4] Add an alpm_db_validity() public function

2011-06-27 Thread Dave Reisner
On Mon, Jun 27, 2011 at 04:39:36PM -0500, Dan McGee wrote: > This allows one to check if a database is valid or invalid. > > Signed-off-by: Dan McGee > --- > lib/libalpm/alpm.h |8 > lib/libalpm/be_local.c |1 + > lib/libalpm/be_sync.c |1 + > lib/libalpm/db.c |

[pacman-dev] [PATCH] lib/util: modify entry_prefix, not prefix

2011-06-29 Thread Dave Reisner
Modifying prefix caused tmp directories to be left behind after running scriptlets, and the path '/' to be passed to _alpm_rmrf. Broken in f01c6f. Signed-off-by: Dave Reisner --- lib/libalpm/util.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/lib/libalp

Re: [pacman-dev] [PATCH] repo-add: fix db creation one last time

2011-06-29 Thread Dave Reisner
On Thu, Jun 30, 2011 at 01:01:35PM +1000, Allan McRae wrote: > On 29/06/11 10:58, Dan McGee wrote: > >We fubar-ed this pretty good. > > > >1. The whole old/new move shuffle was totally busted if you used a > >relative path to your database, as we would just build the database in > >place. > >2. Our

[pacman-dev] [PATCH] repo-add.sh.in: avoid being clever with repo repacking

2011-06-29 Thread Dave Reisner
Revert to the old behavior that 6f5a90 attempted to simplify and go with the original proposed solution of using "ugly" bash to detect empty directories. Signed-off-by: Dave Reisner --- And here's such a patch... scripts/repo-add.sh.in |9 +++-- 1 files changed, 7 i

Re: [pacman-dev] [PATCH] repo-add: fix db creation one last time

2011-06-29 Thread Dave Reisner
On Wed, Jun 29, 2011 at 10:15:12PM -0500, Dan McGee wrote: > On Wed, Jun 29, 2011 at 10:06 PM, Dave Reisner wrote: > > On Thu, Jun 30, 2011 at 01:01:35PM +1000, Allan McRae wrote: > >> On 29/06/11 10:58, Dan McGee wrote: > >> >We fubar-ed this pretty good. > >

[pacman-dev] [PATCH 0/3] minor makepkg cleanups

2011-06-29 Thread Dave Reisner
Just some trivial code cleanups and simplifications I came across looking for other bugs. Dave Reisner (3): makepkg: remove unneeded echo makepkg: fix vim syntax highlighting makepkg: simplify SIGNPKG check scripts/makepkg.sh.in |8 +++- 1 files changed, 3 insertions(+), 5

[pacman-dev] [PATCH 1/3] makepkg: remove unneeded echo

2011-06-29 Thread Dave Reisner
Signed-off-by: Dave Reisner --- scripts/makepkg.sh.in |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index ed5cdef..c988554 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -284,7 +284,7 @@ check_option

[pacman-dev] [PATCH 2/3] makepkg: fix vim syntax highlighting

2011-06-29 Thread Dave Reisner
Signed-off-by: Dave Reisner --- scripts/makepkg.sh.in |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index c988554..b7246f1 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -1134,7 +1134,7 @@ create_package

[pacman-dev] [PATCH 3/3] makepkg: simplify SIGNPKG check

2011-06-29 Thread Dave Reisner
Signed-off-by: Dave Reisner --- scripts/makepkg.sh.in |4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index b7246f1..b844c65 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -2008,9 +2008,7 @@ if [[ -n

[pacman-dev] [PATCH] contrib/paclist: rewrite in bash

2011-06-29 Thread Dave Reisner
The original concept for this script was a bash implementation, but turned out to be unreasonable at the time due to the efficiencies of the database format. Since those have been resolved, we can rewrite this in bash as a much simpler script. Signed-off-by: Dave Reisner --- Restore this script

[pacman-dev] [PATCH] move proto files to new subdirectory, proto/

2011-06-29 Thread Dave Reisner
Signed-off-by: Dave Reisner --- Since we're moving to cleanup the root dir, this seemed like low hanging fruit. Yes Dan, I ran distcheck and it passed. ChangeLog.proto| 16 -- Makefile.am|6 +++- PKGBUILD-split.proto |

Re: [pacman-dev] [PATCH 2/3] makepkg: fix vim syntax highlighting

2011-06-29 Thread Dave Reisner
On Thu, Jun 30, 2011 at 06:15:23AM +0200, Florian Pritz wrote: > > diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in > > index c988554..b7246f1 100644 > > --- a/scripts/makepkg.sh.in > > +++ b/scripts/makepkg.sh.in > > @@ -1134,7 +1134,7 @@ create_package() { > >  > >      # check for c

[pacman-dev] [PATCH] lib/alpm: unlock the handle before freeing it

2011-06-29 Thread Dave Reisner
This avoids, probably among other things, leaving the lock file in place after a SIGINT interrupts a sync DB update. Fixes regression introduced in 4f8ae2b. Signed-off-by: Dave Reisner --- Dan this seems to work (surviving a variety of -Sy and -Syu testcases) and pactest doesn't complain

[pacman-dev] [PATCH] contrib/paclist: rewrite in bash

2011-06-30 Thread Dave Reisner
extend this a little, binding to gettext to keep our pacman translations intact. Signed-off-by: Dave Reisner --- Resend with Allan's suggestions addressed. I get to redeem myself and use the right diff flags as well. contrib/paclist.in | 129 -

Re: [pacman-dev] [PATCH] contrib/paclist: rewrite in bash

2011-06-30 Thread Dave Reisner
On Thu, Jun 30, 2011 at 11:29:50PM +1000, Allan McRae wrote: > On 30/06/11 23:10, Dave Reisner wrote: > >The original concept for this script was a bash implementation, but > >turned out to be unreasonable at the time due to the efficiencies of the > >database format.

[pacman-dev] repo-add test harness

2011-06-30 Thread Dave Reisner
The attached script is what I used for testing my repo-add changes, and worked out rather well. It's extremely primitive, but it does a bit of a smoke test again bash3 and bash4, which is important. I imagine that the next step might be to take a variety of .PKGINFO files and provide those as inpu

[pacman-dev] [PATCH 0/4] download: cover some edge cases, and cleanup

2011-07-01 Thread Dave Reisner
fully (eventually) let us move download progress calculations to the back end. Test it, break it, tell me it sucks. Dave Reisner (4): dload: handle irregular URLs lib/dload: prevent large file attacks absorb some _alpm_download params into payload struct absorb fileinfo struct into dl

[pacman-dev] [PATCH 1/4] dload: handle irregular URLs

2011-07-01 Thread Dave Reisner
From: Dave Reisner URLs might end with a slash and follow redirects, or could be a generated by a script such as /getpkg.php?id=12345. In both cases, we may have a better filename that we can write to, taken from either content-disposition header, or the effective URL. Specific to the first

[pacman-dev] [PATCH 2/4] lib/dload: prevent large file attacks

2011-07-01 Thread Dave Reisner
From: Dave Reisner This means creating a new struct which can pass more descriptive data from the back end sync functions to the downloader. In particular, we're interested in the download size read from the sync DB. When the remote server reports a size larger than this (via a content-l

[pacman-dev] [PATCH 3/4] absorb some _alpm_download params into payload struct

2011-07-01 Thread Dave Reisner
Restore some sanity to the number of arguments passed to _alpm_download and curl_download_internal. Signed-off-by: Dave Reisner --- lib/libalpm/be_sync.c | 12 +++-- lib/libalpm/dload.c | 118 lib/libalpm/dload.h |9 +++- lib/libalpm

[pacman-dev] [PATCH 4/4] absorb fileinfo struct into dload_payload

2011-07-01 Thread Dave Reisner
This transitional struct becomes delicious noms for dload_payload. Signed-off-by: Dave Reisner --- lib/libalpm/dload.c | 57 -- lib/libalpm/dload.h | 10 +--- 2 files changed, 29 insertions(+), 38 deletions(-) diff --git a/lib/libalpm

Re: [pacman-dev] [PATCH 3/4] absorb some _alpm_download params into payload struct

2011-07-02 Thread Dave Reisner
On Fri, Jul 01, 2011 at 08:59:25AM -0400, Dave Reisner wrote: > Restore some sanity to the number of arguments passed to _alpm_download > and curl_download_internal. > > Signed-off-by: Dave Reisner > --- > lib/libalpm/be_sync.c | 12 +++-- > lib/lib

Re: [pacman-dev] [PATCH 1/4] dload: handle irregular URLs

2011-07-03 Thread Dave Reisner
On Sun, Jul 03, 2011 at 01:56:05PM -0500, Dan McGee wrote: > On Fri, Jul 1, 2011 at 7:59 AM, Dave Reisner wrote: > > From: Dave Reisner > > > > URLs might end with a slash and follow redirects, or could be a > > generated by a script such as /getpkg.php?id=12345. In bo

Re: [pacman-dev] [PATCH 2/4] lib/dload: prevent large file attacks

2011-07-03 Thread Dave Reisner
On Sun, Jul 03, 2011 at 02:13:30PM -0500, Dan McGee wrote: > On Fri, Jul 1, 2011 at 7:59 AM, Dave Reisner wrote: > > From: Dave Reisner > > > > This means creating a new struct which can pass more descriptive data > > from the back end sync functions to the downl

Re: [pacman-dev] [PATCH 3/4] absorb some _alpm_download params into payload struct

2011-07-03 Thread Dave Reisner
On Sun, Jul 03, 2011 at 02:20:13PM -0500, Dan McGee wrote: > On Fri, Jul 1, 2011 at 7:59 AM, Dave Reisner wrote: > > Restore some sanity to the number of arguments passed to _alpm_download > > and curl_download_internal. > > > > Signed-off-by: Dave Reisner > &g

Re: [pacman-dev] [PATCH 4/4] absorb fileinfo struct into dload_payload

2011-07-03 Thread Dave Reisner
On Sun, Jul 03, 2011 at 02:26:10PM -0500, Dan McGee wrote: > On Fri, Jul 1, 2011 at 7:59 AM, Dave Reisner wrote: > > This transitional struct becomes delicious noms for dload_payload. > Ignore me on the previous patch; merging the two is better done in a > separate patch, so ke

Re: [pacman-dev] Download sources from git/hg/etc

2011-07-04 Thread Dave Reisner
On Mon, Jul 04, 2011 at 06:43:47PM +0200, se...@seblu.net wrote: > Hello, > > I would add a new feature in makepkg, which allow downloading of > git/hg/cvs/etc content directly by makepkg. This feature can be great > for packages in AUR. We have a lot of -git packages which can use this > to escap

Re: [pacman-dev] [PATCH 3/3] parse_options: accept multiple arguments

2011-07-05 Thread Dave Reisner
On Tue, Jul 05, 2011 at 09:51:31PM +1000, Allan McRae wrote: > Allow command-line options to accept multiple arguments without > additional quoting by taking the list of arguments until one > starting with a "-" is reached. > > The only current use of this is the --pkg option in makepkg. This > a

Re: [pacman-dev] [PATCH 5/7] pacman-key: fix quotation on several variable assignments

2011-07-08 Thread Dave Reisner
On Fri, Jul 08, 2011 at 09:59:30PM +1000, Allan McRae wrote: > From: Ivan Kanakarakis > > This commit adds quotes to several variable assignments. Unquoted values > can cause problems on several occasions if the value is empty. It is > safer to have every assignment quoted. Perhaps this is just

[pacman-dev] [PATCH 1/3] makepkg: remove unused -C option from option list

2011-07-08 Thread Dave Reisner
We nuke it from the completion file as well. Signed-off-by: Dave Reisner --- contrib/bash_completion.in |2 +- scripts/makepkg.sh.in |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/bash_completion.in b/contrib/bash_completion.in index 7f47f4b..3093c02

[pacman-dev] [PATCH 2/3] contrib/bash_completion: update with new makepkg opts

2011-07-08 Thread Dave Reisner
Adds new options for signing on package creation, as well as the check() functionality. Signed-off-by: Dave Reisner --- contrib/bash_completion.in |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/contrib/bash_completion.in b/contrib/bash_completion.in index 3093c02

[pacman-dev] [PATCH 3/3] contrib/log2pkglist: new contribution

2011-07-08 Thread Dave Reisner
gh to need this. Signed-off-by: Dave Reisner --- We've had a similar script floating around on the wiki and some other places, so this should be a nice addition to our contrib package. It has the added bonus of providing version numbers. contrib/Makefile.am |1 + contrib/log

Re: [pacman-dev] [PATCH 3/3] contrib/log2pkglist: new contribution

2011-07-08 Thread Dave Reisner
On Fri, Jul 08, 2011 at 08:51:51AM -0500, Dan McGee wrote: > On Fri, Jul 8, 2011 at 8:42 AM, Dave Reisner wrote: > > converts a pacman log file to a list of installed packages, which should > > match the output of `pacman -Q'. > > > > This isn't bullet proof,

Re: [pacman-dev] [PATCH 5/7] pacman-key: fix quotation on several variable assignments

2011-07-08 Thread Dave Reisner
On Sat, Jul 09, 2011 at 06:47:34AM +1000, Allan McRae wrote: > On 08/07/11 22:56, Dave Reisner wrote: > >>@@ -264,7 +264,7 @@ if [[ ! -r "${CONFIG}" ]]; then > >> fi > >> > >> # Get GPGDIR from pacman.conf iff not specified on command line >

Re: [pacman-dev] [PATCH 5/7] pacman-key: fix quotation on several variable assignments

2011-07-08 Thread Dave Reisner
On Sat, Jul 09, 2011 at 07:13:33AM +1000, Allan McRae wrote: > On 09/07/11 07:00, Dave Reisner wrote: > >On Sat, Jul 09, 2011 at 06:47:34AM +1000, Allan McRae wrote: > >>On 08/07/11 22:56, Dave Reisner wrote: > >>>>@@ -264,7 +264,7 @@ if [[ ! -r "${CONFIG}&quo

[pacman-dev] [PATCH] pacman-key: refactor get_from

2011-07-08 Thread Dave Reisner
: Dave Reisner --- scripts/pacman-key.sh.in | 18 ++ 1 files changed, 10 insertions(+), 8 deletions(-) diff --git a/scripts/pacman-key.sh.in b/scripts/pacman-key.sh.in index b884870..9fae0d8 100644 --- a/scripts/pacman-key.sh.in +++ b/scripts/pacman-key.sh.in @@ -74,17 +74,19

[pacman-dev] [PATCH] makepkg: don't try to verbump PKGBUILD on /dev/stdin

2011-07-10 Thread Dave Reisner
have changed to ensure that in the non-write case we create the new package with the correct version. Signed-off-by: Dave Reisner --- Extreme edge cases ftw. Allan, correct me if I'm wrong that this is the only place where we actually modify the PKGBUILD itself. I had myself a grep aroun

  1   2   3   4   5   6   7   8   9   10   >