From 17ebf3a11fb5e46f3a264ced96d65c90901dc134 Mon Sep 17 00:00:00 2001 From: Andre Klapper Date: Sat, 20 May 2023 17:45:54 +0200 Subject: [PATCH] Remove PHP version suffixes on "Missing Required Extensions"; Mention dnf Summary: Explicitly mentioning PHP5 packages is outdated and confusing. Also, mentioning dnf together with yum (apparently yum is still in use!). Good for yum users. Closes T15352 Test Plan: Applied this change and strings on the "Missing Required Extensions" page rendered as expected. Reviewers: O1 Blessed Committers, valerio.bozzolan, jgleeson Reviewed By: O1 Blessed Committers, valerio.bozzolan, jgleeson Subscribers: jgleeson, bfs, speck, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno Maniphest Tasks: T15352 Differential Revision: https://we.phorge.it/D25203 --- .../config/view/PhabricatorSetupIssueView.php | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/applications/config/view/PhabricatorSetupIssueView.php b/src/applications/config/view/PhabricatorSetupIssueView.php index 003725d5fc..bfeae20684 100644 --- a/src/applications/config/view/PhabricatorSetupIssueView.php +++ b/src/applications/config/view/PhabricatorSetupIssueView.php @@ -73,20 +73,22 @@ final class PhabricatorSetupIssueView extends AphrontView { 'Install these %d PHP extension(s):', count($extensions)); $install_info = pht( - 'You can usually install a PHP extension using %s or %s. Common '. - 'package names are %s or %s. Try commands like these:', + 'You can usually install a PHP extension using %s, %s, or %s. A '. + 'common package name is %s. Try commands like these:', phutil_tag('tt', array(), 'apt-get'), + phutil_tag('tt', array(), 'dnf'), phutil_tag('tt', array(), 'yum'), - hsprintf('php-%s', pht('extname')), - hsprintf('php5-%s', pht('extname'))); + hsprintf('php-%s', pht('extname'))); // TODO: We should do a better job of detecting how to install extensions // on the current system. $install_commands = hsprintf( - "\$ sudo apt-get install php5-extname ". + "\$ sudo apt-get install php-extname ". "# Debian / Ubuntu\n". - "\$ sudo yum install php-extname ". - "# Red Hat / Derivatives"); + "\$ sudo dnf install php-extname ". + "# Red Hat / Derivatives\n". + "\$ sudo yum install php-extname ". + "# Older Red Hat versions"); $fallback_info = pht( "If those commands don't work, try Google. The process of installing ".