Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:120340 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 97496 invoked from network); 18 May 2023 14:27:44 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 18 May 2023 14:27:44 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 452101804C6 for ; Thu, 18 May 2023 07:27:43 -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.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 18 May 2023 07:27:42 -0700 (PDT) Received: by mail-wr1-f41.google.com with SMTP id ffacd0b85a97d-3090408e09bso1399394f8f.2 for ; Thu, 18 May 2023 07:27:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684420061; x=1687012061; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=CqiRxFlh4qtVCeHHuvl+4aIn9dFNGZJ+OkcIV0r9Pi8=; b=OIfWMxxFunuu1s2OtTH7kKS+0drmyIWSAAeYDzB2l6/nHrz7iphTYISc3xvg6DNfwg QE0o++nvxw5NabWs9YYveSOU9q8mFv+G18lXjoe7a51bbnSzIMkuLjM3PHuvzlSNfIIw mQU+7hxL7292tolYODBFk9WZCbYfHOy0uSqSTt1cTNH2nUTD+S65sqXF9B8W4mfJDQW1 +YcKwgXXd/+quJnL8VKfY2jyBftcrzO1H7liZk/mQLbqN9lG5E4kfPfx2oRsdpltLag/ rRZfZjw9PsCE+5F7na/0GHS2uV8IwMIpC68tLMW3zeQGGdIG+Ixm2LBhmUImDnymzqUL +SvA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684420061; x=1687012061; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=CqiRxFlh4qtVCeHHuvl+4aIn9dFNGZJ+OkcIV0r9Pi8=; b=as0NC9YSC8pZnbupu/+TzRV3meyi/kp9TkhBhe6tzryHn3q/MICBDGHsBjeKxgNGzP wU/Tp6SRXLhAd8fj0qcxhkjfNMAoMP9gIljLeCuWRokQ8bWtgV4YnaWIv5LNXFPUPLgC nMnJ08bvAyak2QKrcNe6InOaF/BmNkvjrwjs6gu+6SSQ89ZRao8aj0/sceQDRzsDrdeY S4+klFP2+tCi/eHTBqDoxvJGIar+jB9Vjdp6M0fZecOuzr+dYjyyUkPY+E1009S6BPgP c2IaYUcUf5lJtjlpTnDNKgr+KGhx++Tq4mkFagr8VnUWgRhYlj/mPt2kPRXZ/kCNMbBD ZP/Q== X-Gm-Message-State: AC+VfDy7c8btpr7F0EoUa+RC+YlD/+h/9njl3jNfkD5LdFPJgxskm0X2 gxUvnbtgLGW6CgivPQJu9G+bm2oW0mA5h03btMlY75L5g/A= X-Google-Smtp-Source: ACHHUZ43JI1NctrxEcbMWZ7Wooq7umwuTXoRfhd6Vf+9FGczGuDTGRmU9plMl6MfcloUv41NZrFG73YteZNmodn6crc= X-Received: by 2002:a5d:4452:0:b0:307:8d6a:a48e with SMTP id x18-20020a5d4452000000b003078d6aa48emr1620784wrr.52.1684420061061; Thu, 18 May 2023 07:27:41 -0700 (PDT) MIME-Version: 1.0 References: <000201d9897f$aa9f9fa0$ffdedee0$@roze.lv> In-Reply-To: Date: Thu, 18 May 2023 15:27:28 +0100 Message-ID: To: PHP internals Content-Type: multipart/alternative; boundary="00000000000064673a05fbf89b10" Subject: Re: [PHP-DEV] PHP Package for PHP From: rowan.collins@gmail.com (Rowan Tommins) --00000000000064673a05fbf89b10 Content-Type: text/plain; charset="UTF-8" On Thu, 18 May 2023 at 14:12, Deleu wrote: > > Or PEAR? > > Like that particular path_join() request is exactly > > > https://pear.php.net/package/File_Util/docs/latest/File/File_Util/File_Util.html#methodbuildPath > > > I have worked with PHP for 14 years now and I know nothing about PEAR. It > either says something about me or about PEAR. > For many years PEAR was the official package repository for PHP. The client was shipped with every install of PHP, and still serves as the basis for PECL, the official distribution for PHP extensions. From the point of most users, it has been entirely replaced by Composer, and I think some of the reasons for that are very relevant to this discussion: - PEAR required a package to be installed globally on a server; Composer allows (and encourages) it to be local to a particular project - PEAR was a "walled garden" - you had to request permission to publish a new package, or take over an existing one; Composer is a "bazaar" - anyone can publish a package to Packagist, and projects can be forked - PEAR tried to be a cohesive ecosystem - it had a unified coding standard, and a strong policy of package interoperability, aiming for a common "feel" across all packages; Composer leaves developers to combine packages however they want On the one hand, PEAR was a single "baseline" that everyone expected; on the other hand, packages tended to be slow to adapt to new needs and fashions, and inflexible to different environments. So instead, people moved to: - Frameworks; which themselves have mostly adopted a "component-based" approach interoperating via Composer packages - Non-framework groups like The League of Extraordinary Packages https://thephpleague.com/ - Single packages that have become de facto standards - large projects like Guzzle and Monolog; and smaller utilities that do one task well, like Ramsey/UUID There are two ways I can see a "standard PHP package" working: - As a server-wide install, part of the distributed PHP. That inherits all the downsides of PEAR, but might be appropriate for a fairly small subset of really low-level functions. - As a set of Composer packages, managed completely outside the PHP lifecycle, in which case it's not clear how it would be different from all the packages that are already out there. Bottom line, I think there is some merit in having part of the standard library be written in PHP rather than C, but we'd still want to be very conservative in what went in there, because most of the downsides of locking it to the PHP release cycle would still be there, and Composer seems to be serving the community pretty well for a lot of functionality. Regards, -- Rowan Tommins [IMSoP] --00000000000064673a05fbf89b10--