From 8e631e0f12d7506282ec2a3f2701ab5a68f82914 Mon Sep 17 00:00:00 2001 From: Wim Leers Date: Fri, 1 Sep 2023 17:52:14 +0200 Subject: [PATCH 1/2] PHP defaults to no user agent. (Drupal.org's) GitLab requires it. So: specify a user agent to make it happy. --- src/Command/App/NewFromDrupal7Command.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Command/App/NewFromDrupal7Command.php b/src/Command/App/NewFromDrupal7Command.php index f9973fa9c..047bd1646 100644 --- a/src/Command/App/NewFromDrupal7Command.php +++ b/src/Command/App/NewFromDrupal7Command.php @@ -148,6 +148,9 @@ protected function execute(InputInterface $input, OutputInterface $output): int return Command::FAILURE; } } + // PHP defaults to no user agent. (Drupal.org's) GitLab requires it. + // @see https://www.php.net/manual/en/filesystem.configuration.php#ini.user-agent + ini_set('user_agent', 'ACLI'); $recommendations_resource = fopen($recommendations_location, 'r'); $recommendations = Recommendations::createFromResource($recommendations_resource); fclose($recommendations_resource); From 0307191ea8cf5febc5ddce6f070b04ff7376c8b5 Mon Sep 17 00:00:00 2001 From: Wim Leers Date: Fri, 1 Sep 2023 18:04:37 +0200 Subject: [PATCH 2/2] Default to using the latest AMA recommendations instead of the hardcoded MVP. --- src/Command/App/NewFromDrupal7Command.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Command/App/NewFromDrupal7Command.php b/src/Command/App/NewFromDrupal7Command.php index 047bd1646..ad1dabbc3 100644 --- a/src/Command/App/NewFromDrupal7Command.php +++ b/src/Command/App/NewFromDrupal7Command.php @@ -137,7 +137,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int fclose($config_resource); // Parse recommendations for project builder. - $recommendations_location = __DIR__ . '/../../../config/from_d7_recommendations.json'; + $recommendations_location = "https://git.drupalcode.org/project/acquia_migrate/-/raw/recommendations/recommendations.json"; if ($input->getOption('recommendations') !== NULL) { $raw_recommendations_location = $input->getOption('recommendations'); try {