civicrm / cv

CiviCRM CLI Utility
25 stars 29 forks source link

require symfony/console ~2.8|^3 -- but the package is fixed to v6.4.7 #194

Open hesco opened 1 month ago

hesco commented 1 month ago

jenkins@efc9c26-01965:/opt/local/my_site_name$ composer require civicrm/cv

./composer.json has been updated Running composer update civicrm/cv Loading composer repositories with package information Updating dependencies Your requirements could not be resolved to an installable set of packages.

Problem 1

Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions. You can also try re-running composer require with an explicit version constraint, e.g. "composer require civicrm/cv:*" to figure out if any version is installable, or "composer require civicrm/cv:^2.1" if you know which you need.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

jenkins@efc9c26-01965:/opt/local/my_site_name$ jq '.require' composer.json

{ "civicrm/civicrm-core": "^5.73", "civicrm/civicrm-drupal-8": "^5.73", "civicrm/civicrm-packages": "^5.73", "composer/installers": "^2.0", "drupal/core-composer-scaffold": "^10.2", "drupal/core-project-message": "^10.2", "drupal/core-recommended": "^10.2" }

demeritcowboy commented 1 month ago

Hi @hesco the docs now suggest either downloading the phar so it can be shared among sites (it won't conflict), or if you really want to use composer then run composer require civicrm/cli-tools - see second point at https://github.com/civicrm/cv#download, or https://docs.civicrm.org/installation/en/latest/drupal/#drupal10-download

hesco commented 1 month ago

@demeritcowboy ++

Thanks mate, that did the trick.

The upside of automating these processes is that . . .

I am saved the tedium of reviewing that documentation every time I install a new site.

The downside of automating these processes is that . . .

I face the tedium of digging through my own automation code to root out these issues which would be avoided if I had only reviewed the documentation and hand built it from scratch, accounting for these upgraded processes as they are introduced.

I have spent far too long restoring my ability to upgrade this site.

demeritcowboy commented 1 month ago

Haha yes it's the downside of fast-moving software - anything you do is obsolete in a few months.