[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [Debian Wiki] Mise à jour de « debian/watch » par PaulWise



Le Tue, Jul 30, 2013 at 07:37:12AM -0000, Debian Wiki a écrit :
> 
>   == Common mistakes ==
>   
>    * Not escaping dots, which match any character. The solution is {{{\.}}} instead of {{{.}}} in the regex.
> -  * A file extension regex that is not flexible enough. The solution is {{{\.(?:tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz)))}}}
> +  * A file extension regex that is not flexible enough. The solution is {{{\.(?:zip|tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz)))}}}
>    * Not anchoring the version group at the right place. The solution is to include something before {{{(\d\S*)}}} like {{{fooproj-(\d\S*)\.tar\.gz}}}
>    * Not starting the version part of the regex with a digit. The solution is to use {{{\d}}} instead of {{{.}}}
>    * Not being flexible enough in the path to the file. The solution is to use {{{http://example.com/someproject/ .*/program-(\d\S*)\.tar\.gz}}} instead of {{{http://example.com/someproject/ /path/to/program/downloads/program-(\d\S*)\.tar\.gz}}}

Hi all,

just a brief comment while seeing this change to the Debian wiki page.  "Not
flexible enough" is very open-ended and calls for continuous updates of watch
files that work perfectly at the moment of their update.

I think that all of this suggests that we would benefit of having this
complexity transferred to uscan:  if the file looks like a compressed tar
archive, like 'foo.tar.gz', then look for other common compressions or formats
if no file is found. 

My concern is that the entries in the watch files are getting dense, where the
informative part ('foo') gets shadowed by the flexible part
('\.(?:zip|tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz)))'), which is why usually I do not
follow the recommendation above.

Cheers,

-- 
Charles Plessy
Debian Med packaging team,
http://www.debian.org/devel/debian-med
Tsurumi, Kanagawa, Japan


Reply to: