Re: Gitorious and debian/watch file

2013-11-27 Thread Dmitry Smirnov
On Tue, 26 Nov 2013 07:38:22 Bart Martens wrote:
 I suggest to use this :
 
   |  version=3
   |  opts=filenamemangle=s/\S*download=//g \
   |  
 http://qa.debian.org/cgi-bin/fakeupstream.cgi?upstream=gitorious/osm-c-tools/osmctools
  \
   |  
 .*=osmctools(?:[_\-]v?|)(\d[^\s/]*)\.(?:tar\.xz|txz|tar\.bz2|tbz2|tar\.gz|tgz)
 

Thanks Bart, it works perfectly. I owe you for this advise.

-- 
Cheers,
 Dmitry Smirnov
 GPG key : 4096R/53968D1B


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/201311272113.34714.only...@debian.org



Re: Gitorious and debian/watch file

2013-11-25 Thread Tomasz Buchert
On 24/11/13 20:39, Mateusz Łukasik wrote:
 W dniu 24.11.2013 o 18:09 Tomasz Buchert tomasz.buch...@inria.fr pisze:
 
 
 Hi guys,
 any news for this problem with gitorious?
 
 Cheers,
 Tomasz
 
 
 Here is solution: https://wiki.debian.org/debian/watch/

Hi Mateusz,
the whole point is that the solution does *not* work :)
Gitorious has changed the URL scheme and there is no easy
way to extract tarball links. I will ping them to provide
something for us.

Cheers,
Tomasz


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20131125105826.ga3...@piscopia.math



Re: Gitorious and debian/watch file

2013-11-25 Thread Bart Martens
On Tue, Oct 15, 2013 at 05:19:12PM +0200, Blanc Pierre wrote:
 Hello,

 I need help to create a wonderful watch file.

 The source is gitorious.

 I read again and again this page :
 https://wiki.debian.org/debian/watch#Gitorious
 I did test again and again but nothing works.

 I did also search on codesearch.debian.net from #debian-mentors advice.
 And I saw, I was not alone.

 I try here, maybe someone has successful with watch file and Gitorious
 symbiosis.

On Tue, Oct 15, 2013 at 05:33:04PM +0200, Pierre Blanc wrote:
 It's a general question non specific to my package :)
 
 The url is https://gitorious.org/osm-c-tools/osmctools

I suggest to use this :

  |  version=3
  |  opts=filenamemangle=s/\S*download=//g \
  |  
http://qa.debian.org/cgi-bin/fakeupstream.cgi?upstream=gitorious/osm-c-tools/osmctools
 \
  |  
.*=osmctools(?:[_\-]v?|)(\d[^\s/]*)\.(?:tar\.xz|txz|tar\.bz2|tbz2|tar\.gz|tgz)

Regards,

Bart Martens


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20131125203822.ga29...@master.debian.org



Re: Gitorious and debian/watch file

2013-11-24 Thread Tomasz Buchert

Hi guys,
any news for this problem with gitorious?

Cheers,
Tomasz


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/20131124170910.ga6...@piscopia.math



Re: Gitorious and debian/watch file

2013-11-24 Thread Eriberto
What is the problem? Can you copy your watch file here?

Thanks!

Eriberto

2013/11/24 Tomasz Buchert tomasz.buch...@inria.fr:

 Hi guys,
 any news for this problem with gitorious?


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/CAP+dXJeif3s-oSHDG88F+5DBu=xi7bzzy4jguzdfgcqqnbj...@mail.gmail.com



Re: Gitorious and debian/watch file

2013-11-24 Thread Mateusz Łukasik

W dniu 24.11.2013 o 18:09 Tomasz Buchert tomasz.buch...@inria.fr pisze:



Hi guys,
any news for this problem with gitorious?

Cheers,
Tomasz



Here is solution: https://wiki.debian.org/debian/watch/


--
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/op.w62jkcxpifijsr@laptop



Re: Gitorious and debian/watch file

2013-11-24 Thread Andrew Shadura
Hello,

On Sun, 24 Nov 2013 20:39:38 +0100
Mateusz Łukasik mat...@linuxmint.pl wrote:

 Here is solution: https://wiki.debian.org/debian/watch/

As far as I know, it no longer works.

-- 
Cheers,
  Andrew


signature.asc
Description: PGP signature


Re: Gitorious and debian/watch file

2013-10-16 Thread Pierre Blanc
Thanks for your help.

Gitorious watch service will be nice on alioth, but I don't know if is possible.

Anyway, I will try to contact upstream gitorious team, to add this feature.

Best regards.

-- 
Cordialement,
Blanc Pierre


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/CAOGTLeLwx6pv4jtZdmyZ++dn9M2zf=ud0xA3Md7wbB9HiH=w...@mail.gmail.com



Re: Gitorious and debian/watch file

2013-10-15 Thread Paul Wise
When asking questions about watch files, at minimum you should point
at the download page or website of the project you are asking about.
Otherwise we have no idea how to answer your question.

-- 
bye,
pabs

http://wiki.debian.org/PaulWise


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/CAKTje6F-5EhzO8LrVUmeHG8ivue4onQ8OOG857A=nzytdp5...@mail.gmail.com



Re: Gitorious and debian/watch file

2013-10-15 Thread Pierre Blanc
It's a general question non specific to my package :)

The url is https://gitorious.org/osm-c-tools/osmctools

On Tue, Oct 15, 2013 at 5:27 PM, Paul Wise p...@debian.org wrote:
 When asking questions about watch files, at minimum you should point
 at the download page or website of the project you are asking about.
 Otherwise we have no idea how to answer your question.

 --
 bye,
 pabs

 http://wiki.debian.org/PaulWise


 --
 To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
 with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
 Archive: 
 http://lists.debian.org/CAKTje6F-5EhzO8LrVUmeHG8ivue4onQ8OOG857A=nzytdp5...@mail.gmail.com




-- 
Cordialement,
Blanc Pierre


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/CAOGTLeJBhyGwJsJQGmH7zWtAtRjX3ePCyN7BXosD=07ox9s...@mail.gmail.com



Re: Gitorious and debian/watch file

2013-10-15 Thread Sebastiaan Couwenberg
Creating a watch file for Gitorious will most likely require a redirect
service to translate the refs JSON to download URLs.

Take for example your osm-c-tools package, it has JSON data with the
repo branches and tags available at:

https://gitorious.org/osm-c-tools/osmctools/refs

The tags can be translated to the tarball URL using the hash:

https://gitorious.org/osm-c-tools/osmctools/archive/9cb724682b14840e1fd020eee7a380926424d603.tar.gz

It's an ugly filename, but you can mangle that in the watch to become
osmctools-0.1.tar.gz

Kind Regards,

Bas

-- 
GnuPG: 0xE88D4AF1 (new) / 0x77A975AD (old)


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/525d6220.6020...@xs4all.nl



Re: Gitorious and debian/watch file

2013-10-15 Thread Paul Wise
On Tue, Oct 15, 2013 at 11:33 PM, Pierre Blanc wrote:

 It's a general question non specific to my package :)

Hmm, none of these work any longer:

http://codesearch.debian.net/search?q=gitorious.org+path%3Adebian%2Fwatch

Unfortunately it appears that gitorious changed their code and now it
is incompatible with uscan. Please contact gitorious and ask them to
create pages with links to archives for each of the tags for a git
repo.

-- 
bye,
pabs

http://wiki.debian.org/PaulWise


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/caktje6g7pqwcoe5mtjkvnr5aos61qknnfu9xsaulupsf-kc...@mail.gmail.com



Re: Gitorious and debian/watch file

2013-10-15 Thread Andrew Shadura
Hello,

On 15 October 2013 17:41, Sebastiaan Couwenberg sebas...@xs4all.nl wrote:
 https://gitorious.org/osm-c-tools/osmctools/archive/
 9cb724682b14840e1fd020eee7a380926424d603.tar.gz

 It's an ugly filename, but you can mangle that in the watch to become
 osmctools-0.1.tar.gz

Same link works for tags: https://gitorious.org/osm-c-tools/osmctools/0.1.tar.gz

So the only real problem is to find the right tag.

-- 
WBR, Andrew


-- 
To UNSUBSCRIBE, email to debian-mentors-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org
Archive: 
http://lists.debian.org/CACujMDOYmKnPw28KMKF0Yt3V=klbnt+zq-irtqadrk5hdyu...@mail.gmail.com



Re: Gitorious and debian/watch file

2013-10-15 Thread Sebastiaan Couwenberg
On 10/15/2013 05:58 PM, Andrew Shadura wrote:
 Same link works for tags: 
 https://gitorious.org/osm-c-tools/osmctools/0.1.tar.gz

That's nice to know, but it only works when you add 'archive/' before
the 0.1.tar.gz.

 So the only real problem is to find the right tag.

Those are listed in the refs JSON.

I've wipped up a QD Gitorious watch service, you can see it working for
osm-c-tools at:

http://linuxminded.nl/tmp/gitorious-watch/?project=osm-c-toolsrepo=osmctools

The code in question comes down to the gitorious-watch.pl as attached,
that's a CLI tool and just a proof-of-concept. The online code just
formats the output as HTML.

I could make this into a CGI to run on Alioth where previous watch file
redirect services were also hosted IIRC.

Regards,

Bas

-- 
GnuPG: 0xE88D4AF1 (new) / 0x77A975AD (old)
#!/usr/bin/perl -w

use strict;
use File::Basename;
use Getopt::Long qw(:config bundling no_ignore_case);
use HTTP::Request::Common;
use LWP::UserAgent;
use URI::Escape;
use JSON;

my %cfg = (
	project = '',
	repo= '',
	verbose = 0,
	help= 0,
  );

my $result = GetOptions(
			 'p|project=s' = \$cfg{project},
			 'r|repo=s'= \$cfg{repo},
			 'v|verbose'   = \$cfg{verbose},
			 'h|help'  = \$cfg{help},
		   );

if(!$result || $cfg{help}) {
	print STDERR \n if(!$result);

	print Usage: . basename($0) . -p PROJECT -r REPO [OPTIONS]\n\n;
	print Options:\n;
	print -p, --project NAME   Project name on Gitorious\n;
	print -r, --repo NAME  Repository name on Gitorious\n;
	print -v, --verbose  Enable verbose output\n;
	print -h, --help Display this usage information\n;
	
	exit 1;
}

my $ua = LWP::UserAgent-new(agent = 'gitorious-redirect');

if($cfg{project}  $cfg{repo}) {
	my $base_url  = 'https://gitorious.org/';
	   $base_url .= URI::Escape::uri_escape($cfg{project}).'/';
	   $base_url .= URI::Escape::uri_escape($cfg{repo});

	my $url = $base_url.'/refs';

	print Retrieving URL: $url ...  if($cfg{verbose});

my $req = HTTP::Request-new(GET = $url);
my $res = $ua-request($req);

	if($res-is_success) {
		print Success\n if($cfg{verbose});

my $json = $res-content;
		my $data = JSON::decode_json($json);

		if($data-{tags}  @{$data-{tags}}) {
			print Tag | URL\n;
			foreach my $tag (@{$data-{tags}}) {
my ($name, $hash) = @{$tag};

my $url  = $base_url.'/archive/';
   $url .= URI::Escape::uri_escape($hash).'.tar.gz';

print $name | $url\n;
			}
		}
		else {
			print Error: No tags found in Gitorious repo!\n;

			exit 1;
		}
}
else {
		print Failed!\n if($cfg{verbose});
print Error: Failed to retrieve URL! ($url)\n;
print HTTP Status: .$res-code. .$res-message.\n;

		exit 1;
}
}
else {
	print No project and/or repo specified, cannot query Gitorious without them.\n;

	exit 1;
}



Re: Gitorious and debian/watch file

2013-10-15 Thread Andrew Shadura
Hello,

On Tue, 15 Oct 2013 18:25:37 +0200
Sebastiaan Couwenberg sebas...@xs4all.nl wrote:
 On 10/15/2013 05:58 PM, Andrew Shadura wrote:
  Same link works for tags:
  https://gitorious.org/osm-c-tools/osmctools/0.1.tar.gz

 That's nice to know, but it only works when you add 'archive/' before
 the 0.1.tar.gz.

Oops, my bad, I've accidentally removed that from the URL.

-- 
WBR, Andrew


signature.asc
Description: PGP signature