Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:116224 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 99083 invoked from network); 5 Oct 2021 12:58:50 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 5 Oct 2021 12:58:50 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 2CDDE1804C6 for ; Tue, 5 Oct 2021 06:43:17 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS208722 37.140.128.0/18 X-Spam-Virus: No X-Envelope-From: Received: from forward500o.mail.yandex.net (forward500o.mail.yandex.net [37.140.190.195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Tue, 5 Oct 2021 06:43:15 -0700 (PDT) Received: from vla1-f69017ba06d0.qloud-c.yandex.net (vla1-f69017ba06d0.qloud-c.yandex.net [IPv6:2a02:6b8:c0d:1e02:0:640:f690:17ba]) by forward500o.mail.yandex.net (Yandex) with ESMTP id 50383941558 for ; Tue, 5 Oct 2021 16:43:13 +0300 (MSK) Received: from vla1-62318bfe5573.qloud-c.yandex.net (2a02:6b8:c0d:3819:0:640:6231:8bfe [2a02:6b8:c0d:3819:0:640:6231:8bfe]) by vla1-f69017ba06d0.qloud-c.yandex.net (mxback/Yandex) with ESMTP id IJS1yey1mT-hCDODx1Q; Tue, 05 Oct 2021 16:43:13 +0300 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=php.watch; s=mail; t=1633441393; bh=yAm3g5T0HdekLRXyJTOCpjjkZ6QHrhlXtiVhrAkZZq8=; h=To:Subject:From:Date:References:Cc:Message-ID:In-Reply-To; b=qWMmFCG1l9a59S5LV14uYsijp0lQ2gOCYTLxTS0ScOREeS2jqqBqEqY0+JTPyVkZE BY+Xf0RQgN6AIAJtOOtT1zUdbVWfzYTzVJFvCDzJQ/G4F/+FOFvA8cJ2eOBCaXIdC9 5VBnFMwU98/02OQ402sF6jScBW9fWVi6ZN3uvkko= Authentication-Results: vla1-f69017ba06d0.qloud-c.yandex.net; dkim=pass header.i=@php.watch Received: by vla1-62318bfe5573.qloud-c.yandex.net (smtp/Yandex) with ESMTPS id CxBAnUpnKQ-hCAuVc6I; Tue, 05 Oct 2021 16:43:12 +0300 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client certificate not present) Received: by mail-ot1-f41.google.com with SMTP id l16-20020a9d6a90000000b0053b71f7dc83so25858363otq.7 for ; Tue, 05 Oct 2021 06:43:12 -0700 (PDT) X-Gm-Message-State: AOAM5338az4chDe2+xVtyM3hw/x3VQBp/Y4gNjKTT3I6FUukMR3UHsrN aKhtVPZApX2hFzqlcmj92ONomotXAFHHq35mTro= X-Google-Smtp-Source: ABdhPJxWY8ivqbqmzK7/MdqdWoe13ojl6iEE07YXoLDjwtZbCdztyFSOW1Pm0k16l7harnVW4THBnUTI79rlB3ML764= X-Received: by 2002:a9d:4e82:: with SMTP id v2mr13905829otk.376.1633441390889; Tue, 05 Oct 2021 06:43:10 -0700 (PDT) MIME-Version: 1.0 References: <5872e8bb-d944-2fae-938f-ae1948b2660b@gmail.com> <18cf67d6-dca7-22e0-3a9a-8fc5f1b36539@heigl.org> In-Reply-To: Date: Tue, 5 Oct 2021 19:12:45 +0530 X-Gmail-Original-Message-ID: Message-ID: To: Hans Henrik Bergan Cc: PHP internals Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] Unbreak git.php.net links? From: ayesh@php.watch (Ayesh Karunaratne) > here is an initial implementation: > https://github.com/divinity76/git-php-net-redirector/blob/main/src/redire= ctor.php > it is just a minimum-effort implementation, anyone feel free to make > something better (also i have no idea how the "p" argument is supposed to > be parsed, so i just guessed) > > it passes "Stanislav Malyshev"'s initial sample url, but it probably fail= s > on any other formats, if anyone has test urls, share em > > > > On Mon, 4 Oct 2021 at 08:38, Hans Henrik Bergan > wrote: > > > >So who's going to work on it? Doesn't make sense to have 5 people work > > > on it independently from each other ;-) > > > > if nobody else wants to do it, i can make an initial implementation on > > october 9th (6 days from now), > > > > but wouldn't surprise me at all if someone else wants to do it ^^ > > > > > > On Mon, 4 Oct 2021 at 08:01, Andreas Heigl wrote: > > > >> Hey all. > >> > >> On 04.10.21 07:52, Hans Henrik Bergan wrote: > >> > there's also plenty of broken links on reddit to git.php.net , ref > >> > https://www.google.com/search?q=3Dgit.php.net+site%3Areddit.com > >> > > >> > it wouldn't be hard to set up a redirector parsing commit ids out of= the > >> > url and redirecting to github, > >> > +1 from me. > >> > >> So who's going to work on it? Doesn't make sense to have 5 people work > >> on it independently from each other ;-) > >> > >> Cheers > >> > >> Andreas > >> -- > >> ,,, > >> (o o) > >> +---------------------------------------------------------ooO-(_)-Ooo-= + > >> | Andreas Heigl = | > >> | mailto:andreas@heigl.org N 50=C2=B022'59.5" E 08=C2= =B023'58" | > >> | https://andreas.heigl.org = | > >> +---------------------------------------------------------------------= + > >> | https://hei.gl/appointmentwithandreas = | > >> +---------------------------------------------------------------------= + > >> > > Hi Stanislav/Hans, Thanks for opening this conversation and the initial implementation. Having worked with a few cgit repositories before, I happen to recall some of the other URL patterns. I worked on a similar implementation to Hans's at https://github.com/Ayesh/git-php-redirect > something better (also i have no idea how the "p" argument is supposed to > be parsed, so i just guessed) It is the name of the git repository on git.php.net. There were several other repos for PECL, bug tracker, docs in multiple languages, etc. I have added support for a static list that maps git.php.net names to GitHub repo under `php` organization namespace. In addition to the URL patterns Hans have covered (p=3Dphp-src;h=3DHEX{40}), I thought to add a few more patterns: - FROM: http://git.php.net/?p=3Dphp-src.git;a=3Dcommit;h=3D5af586be ( `/[a-z0-9]{7,}$/` ) TO: https://github.com/php/php-src/commit/5af586be - FROM: https://git.php.net/?p=3Dphp-src.git;a=3Dshortlog;h=3Drefs/tags/php= -8.0.0RC2 TO: https://github.com/php/php-src/releases/tag/php-8.1.0RC3 - FROM: https://git.php.net/?p=3Dphp-src.git;a=3D{tree,log,shortlog};h=3Dre= fs/heads/master;hb=3Drefs/heads/master TO: https://github.com/php/php-src/{tree,commits,commits}/master - FROM: http://git.php.net/?p=3Dphp-src.git;a=3Dlog TO: https://github.com/php/php-src Cheers, Ayesh.