Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Versions in composer #394

Closed
wyster opened this issue Jul 9, 2019 · 1 comment
Closed

Versions in composer #394

wyster opened this issue Jul 9, 2019 · 1 comment
Labels

Comments

@wyster
Copy link

@wyster wyster commented Jul 9, 2019

Hello! I'm about PR #262.

After any changes in composer.json command composer validate fail with error:

The lock file is not up to date with the latest changes in composer.json, it is recommended that you run composer update

If use composer update --lock hash in composer.lock updated and section version removed from composer.lock

Docs:
https://getcomposer.org/doc/03-cli.md#validate
https://getcomposer.org/doc/03-cli.md#update-u

--lock: Only updates the lock file hash to suppress warning about the lock file being out of date.

I added this trick in standard-version config:

"scripts": {
  "postbump": "composer update --lock"
}

In total:

  1. Not need update composer.lock
  2. Need run composer update --lock after changes composer.json, but command not very fast

Maybe it's need add to FAQ?

@bcoe bcoe added the bug label Jul 15, 2019
@bcoe
Copy link
Member

@bcoe bcoe commented Jul 15, 2019

@TilmannBach 👋 sounds like our composer feature might need some updates. Any thoughts?

pvgnd added a commit to pvgnd/standard-version that referenced this issue Dec 5, 2019
jbottigliero added a commit that referenced this issue Jan 16, 2020
…package and bump files.

- No need to bump version for `composer` as it relies on VCS tag to infer version (#495)
- Closes #394

BREAKING CHANGE: `composer.json` and `composer.lock` will no longer be read from or bumped by default. If you need to obtain a version or write a version to these files, please use `bumpFiles` and/or `packageFiles` options accordingly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Linked pull requests

Successfully merging a pull request may close this issue.

2 participants