Re: [arch-general] 'Check out-of-date packages' tool

2013-05-16 Thread Anatol Pomozov
Hi

On Tue, May 14, 2013 at 6:13 PM, Sébastien Luttringer  wrote:
> On Sat, May 11, 2013 at 8:26 PM, Anatol Pomozov
>  wrote:
>> Hi everyone
>>
>> Per discussion in 'pacman-dev' maillist [1] I implemented a tool that tries
>> to find Arch out-of-date packages. The tool scans PKGBUILD files is
>> /var/abs directory, extracts download url and then tries to probe download
>> urls for the next version. Next versions look like
>>
>> X.Y.Z+1
>> X.Y+1.0
>> X+1.0.0
>>
>> If any of the new versions presents on the download server it reports to
>> user as 'new version available'.
>>
>> Here is the tool sources https://github.com/anatol/pkgoutofdate To make its
>> usage even more pleasant I added it to AUR
>> https://aur.archlinux.org/packages/pkgoutofdate-git/
>>
> I use this[1] software since jully 2012 for my packages.
> Now, it handle comparaison against archweb, local pacman, abs tree, aur rpc
> or a local cache.
> You need to configure it[2] to check your packages, it's not automagic
> like yours by parsing abs tree.  But I don't want that :)

Two tools implemented to solve the problem of discovering out-of-date
packages indicates that this issue is important. Arch developer have
you though about adding such functionality into standard Arch toolkit?


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-14 Thread Sébastien Luttringer
On Sat, May 11, 2013 at 8:26 PM, Anatol Pomozov
 wrote:
> Hi everyone
>
> Per discussion in 'pacman-dev' maillist [1] I implemented a tool that tries
> to find Arch out-of-date packages. The tool scans PKGBUILD files is
> /var/abs directory, extracts download url and then tries to probe download
> urls for the next version. Next versions look like
>
> X.Y.Z+1
> X.Y+1.0
> X+1.0.0
>
> If any of the new versions presents on the download server it reports to
> user as 'new version available'.
>
> Here is the tool sources https://github.com/anatol/pkgoutofdate To make its
> usage even more pleasant I added it to AUR
> https://aur.archlinux.org/packages/pkgoutofdate-git/
>
I use this[1] software since jully 2012 for my packages.
Now, it handle comparaison against archweb, local pacman, abs tree, aur rpc
or a local cache.
You need to configure it[2] to check your packages, it's not automagic
like yours by parsing abs tree.  But I don't want that :)

Cheers,

[1] https://github.com/seblu/archversion/
[2] https://github.com/seblu/archversion/blob/master/misc/example2.conf
--
Sébastien "Seblu" Luttringer
https://www.seblu.net
GPG: 0x2072D77A


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-13 Thread Anatol Pomozov
Hi

On Mon, May 13, 2013 at 9:51 AM, Don deJuan  wrote:
> On 05/12/2013 03:21 PM, Anatol Pomozov wrote:
>> Hi
>>
>>
>> On Sat, May 11, 2013 at 1:25 PM, Don deJuan  wrote:
>>
>>> On 05/11/2013 11:26 AM, Anatol Pomozov wrote:
 Hi everyone

 Per discussion in 'pacman-dev' maillist [1] I implemented a tool that
>>> tries
 to find Arch out-of-date packages. The tool scans PKGBUILD files is
 /var/abs directory, extracts download url and then tries to probe
>>> download
 urls for the next version. Next versions look like

 X.Y.Z+1
 X.Y+1.0
 X+1.0.0

 If any of the new versions presents on the download server it reports to
 user as 'new version available'.

 Here is the tool sources https://github.com/anatol/pkgoutofdate To make
>>> its
 usage even more pleasant I added it to AUR
 https://aur.archlinux.org/packages/pkgoutofdate-git/

 To use it please install pkgoutofdate-git package:

 $ yaourt -S pkgoutofdate-git

 Then update abs database and run tool itself:

 $ sudo abs && pkgoutofdate

 That's it. The result looks like

 ...
 closure-linter: new version found - 2.3.8 => 2.3.9
 perl-data-dump: new version found - 1.21 => 1.22
 wgetpaste: new version found - 2.20 => 2.21
 fillets-ng-data: new version found - 1.0.0 => 1.0.1
 tablelist: new version found - 5.5 => 5.6
 ..


 There are some fals positive and negative results though, mostly because
 download servers return different sort of weird responses. I still work
>>> on
 work-arounds for all these cases.

 Hope you find this tool useful and it will help to make Arch software
>>> even
 more bleeding edge.

 [1]

>>> https://mailman.archlinux.org/pipermail/pacman-dev/2013-March/thread.html#16850
>>> Does this only work for packages found in the ABS or will it also work
>>> for AUR packages one might be maintaining?
>>>
>> Only ABS right now. I did it because it is easy to traverse files under
>> /var/abs and parse them.
>>
>> AUR requires additional step on fetching PKGBUILD from server. It should be
>> fairly easy to add it. What is the recommended way to fetch files from aur?
>> Just 'wget https://aur.archlinux.org/packages/pk/pkgoutofdate-git/PKGBUILD'?
> I would do it that was as it seems the easiest way to get just the
> PKGBUILD.
>
> Or could you add a flag where we can pass a directory, say where we
> store PKGBUILDs for the AUR we maintain.

Added "-d" flag, now you can specify custom directory where to scan
for PKGBUILD files.


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-13 Thread Don deJuan
On 05/12/2013 03:21 PM, Anatol Pomozov wrote:
> Hi
>
>
> On Sat, May 11, 2013 at 1:25 PM, Don deJuan  wrote:
>
>> On 05/11/2013 11:26 AM, Anatol Pomozov wrote:
>>> Hi everyone
>>>
>>> Per discussion in 'pacman-dev' maillist [1] I implemented a tool that
>> tries
>>> to find Arch out-of-date packages. The tool scans PKGBUILD files is
>>> /var/abs directory, extracts download url and then tries to probe
>> download
>>> urls for the next version. Next versions look like
>>>
>>> X.Y.Z+1
>>> X.Y+1.0
>>> X+1.0.0
>>>
>>> If any of the new versions presents on the download server it reports to
>>> user as 'new version available'.
>>>
>>> Here is the tool sources https://github.com/anatol/pkgoutofdate To make
>> its
>>> usage even more pleasant I added it to AUR
>>> https://aur.archlinux.org/packages/pkgoutofdate-git/
>>>
>>> To use it please install pkgoutofdate-git package:
>>>
>>> $ yaourt -S pkgoutofdate-git
>>>
>>> Then update abs database and run tool itself:
>>>
>>> $ sudo abs && pkgoutofdate
>>>
>>> That's it. The result looks like
>>>
>>> ...
>>> closure-linter: new version found - 2.3.8 => 2.3.9
>>> perl-data-dump: new version found - 1.21 => 1.22
>>> wgetpaste: new version found - 2.20 => 2.21
>>> fillets-ng-data: new version found - 1.0.0 => 1.0.1
>>> tablelist: new version found - 5.5 => 5.6
>>> ..
>>>
>>>
>>> There are some fals positive and negative results though, mostly because
>>> download servers return different sort of weird responses. I still work
>> on
>>> work-arounds for all these cases.
>>>
>>> Hope you find this tool useful and it will help to make Arch software
>> even
>>> more bleeding edge.
>>>
>>> [1]
>>>
>> https://mailman.archlinux.org/pipermail/pacman-dev/2013-March/thread.html#16850
>> Does this only work for packages found in the ABS or will it also work
>> for AUR packages one might be maintaining?
>>
> Only ABS right now. I did it because it is easy to traverse files under
> /var/abs and parse them.
>
> AUR requires additional step on fetching PKGBUILD from server. It should be
> fairly easy to add it. What is the recommended way to fetch files from aur?
> Just 'wget https://aur.archlinux.org/packages/pk/pkgoutofdate-git/PKGBUILD'?
I would do it that was as it seems the easiest way to get just the
PKGBUILD.

Or could you add a flag where we can pass a directory, say where we
store PKGBUILDs for the AUR we maintain.

Thanks for the great tool though.


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-12 Thread Anatol Pomozov
Hi


On Sun, May 12, 2013 at 8:07 AM, Ross Lagerwall  wrote:
>
> On Sat, May 11, 2013 at 11:26:19AM -0700, Anatol Pomozov wrote:
> > There are some fals positive and negative results though, mostly because
> > download servers return different sort of weird responses. I still work on
> > work-arounds for all these cases.
> >
>
> Have you any ideas how to avoid showing development releases as new
> releases? For example, Perl 5.17 shows as a new release but AFAIK it is
> only a development release...


Currently pkgoutofdate does not have such functionality. Different
projects have different release strategies. Some projects use -betaXXX
for development releases, some use odd minor numbers in version. These
information is project specific and should be stored in PKGBUILD.

I proposed a solution in the FS#34447 [1]. The idea is that in case if
a project has specific release cycle then PKGBUILD will contain
additional function, let's say "released_version()", this function
should provide pkgoutofdate "recommended version".

For example for project "less" http://www.greenwoodsoftware.com/less/
the function will go to homepage, fetch its text, parse for ancor word
and get the version:

released_version() {
  curl -s http://www.greenwoodsoftware.com/less/ | grep -Po "The
current released version is less-(\d+)" | grep -Po "\d+"
}

This function returns number from homepage (currently 458). The number
compared with version in PKGBUILD and it is smaller (or just
different) then package considered out of date.

This solution is somewhat similar to macport's livecheck implementation [2].

As I said this requires only for minority of projects. Most projects
are just fine with "the next version" algorithm described in the first
message.


https://bugs.archlinux.org/task/34447
http://guide.macports.org/chunked/reference.livecheck.html


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-12 Thread Anatol Pomozov
Hi


On Sat, May 11, 2013 at 1:25 PM, Don deJuan  wrote:

> On 05/11/2013 11:26 AM, Anatol Pomozov wrote:
> > Hi everyone
> >
> > Per discussion in 'pacman-dev' maillist [1] I implemented a tool that
> tries
> > to find Arch out-of-date packages. The tool scans PKGBUILD files is
> > /var/abs directory, extracts download url and then tries to probe
> download
> > urls for the next version. Next versions look like
> >
> > X.Y.Z+1
> > X.Y+1.0
> > X+1.0.0
> >
> > If any of the new versions presents on the download server it reports to
> > user as 'new version available'.
> >
> > Here is the tool sources https://github.com/anatol/pkgoutofdate To make
> its
> > usage even more pleasant I added it to AUR
> > https://aur.archlinux.org/packages/pkgoutofdate-git/
> >
> > To use it please install pkgoutofdate-git package:
> >
> > $ yaourt -S pkgoutofdate-git
> >
> > Then update abs database and run tool itself:
> >
> > $ sudo abs && pkgoutofdate
> >
> > That's it. The result looks like
> >
> > ...
> > closure-linter: new version found - 2.3.8 => 2.3.9
> > perl-data-dump: new version found - 1.21 => 1.22
> > wgetpaste: new version found - 2.20 => 2.21
> > fillets-ng-data: new version found - 1.0.0 => 1.0.1
> > tablelist: new version found - 5.5 => 5.6
> > ..
> >
> >
> > There are some fals positive and negative results though, mostly because
> > download servers return different sort of weird responses. I still work
> on
> > work-arounds for all these cases.
> >
> > Hope you find this tool useful and it will help to make Arch software
> even
> > more bleeding edge.
> >
> > [1]
> >
> https://mailman.archlinux.org/pipermail/pacman-dev/2013-March/thread.html#16850
> Does this only work for packages found in the ABS or will it also work
> for AUR packages one might be maintaining?
>

Only ABS right now. I did it because it is easy to traverse files under
/var/abs and parse them.

AUR requires additional step on fetching PKGBUILD from server. It should be
fairly easy to add it. What is the recommended way to fetch files from aur?
Just 'wget https://aur.archlinux.org/packages/pk/pkgoutofdate-git/PKGBUILD'?


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-12 Thread Ross Lagerwall
On Sat, May 11, 2013 at 11:26:19AM -0700, Anatol Pomozov wrote:
> There are some fals positive and negative results though, mostly because
> download servers return different sort of weird responses. I still work on
> work-arounds for all these cases.
> 

Have you any ideas how to avoid showing development releases as new
releases? For example, Perl 5.17 shows as a new release but AFAIK it is
only a development release...
-- 
Ross Lagerwall


Re: [arch-general] 'Check out-of-date packages' tool

2013-05-12 Thread Don deJuan
On 05/11/2013 11:26 AM, Anatol Pomozov wrote:
> Hi everyone
>
> Per discussion in 'pacman-dev' maillist [1] I implemented a tool that tries
> to find Arch out-of-date packages. The tool scans PKGBUILD files is
> /var/abs directory, extracts download url and then tries to probe download
> urls for the next version. Next versions look like
>
> X.Y.Z+1
> X.Y+1.0
> X+1.0.0
>
> If any of the new versions presents on the download server it reports to
> user as 'new version available'.
>
> Here is the tool sources https://github.com/anatol/pkgoutofdate To make its
> usage even more pleasant I added it to AUR
> https://aur.archlinux.org/packages/pkgoutofdate-git/
>
> To use it please install pkgoutofdate-git package:
>
> $ yaourt -S pkgoutofdate-git
>
> Then update abs database and run tool itself:
>
> $ sudo abs && pkgoutofdate
>
> That's it. The result looks like
>
> ...
> closure-linter: new version found - 2.3.8 => 2.3.9
> perl-data-dump: new version found - 1.21 => 1.22
> wgetpaste: new version found - 2.20 => 2.21
> fillets-ng-data: new version found - 1.0.0 => 1.0.1
> tablelist: new version found - 5.5 => 5.6
> ..
>
>
> There are some fals positive and negative results though, mostly because
> download servers return different sort of weird responses. I still work on
> work-arounds for all these cases.
>
> Hope you find this tool useful and it will help to make Arch software even
> more bleeding edge.
>
> [1]
> https://mailman.archlinux.org/pipermail/pacman-dev/2013-March/thread.html#16850
Does this only work for packages found in the ABS or will it also work
for AUR packages one might be maintaining?

Thanks