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

Should document declaring bumpFiles removes default functionality #506

Open
NickDJM opened this issue Dec 13, 2019 · 1 comment
Open

Should document declaring bumpFiles removes default functionality #506

NickDJM opened this issue Dec 13, 2019 · 1 comment
Labels

Comments

@NickDJM
Copy link

NickDJM commented Dec 13, 2019

Issue

In v7.1.0:

When you declare a custom file in bumpFiles standard-version will no longer update normal package.json, composer.json, lockfiles, etc. declared in the defaults.

This is fine (I don't think this is a bug because maybe you don't want it to bother with the defaults), but I think it should be mentioned in the documentation that when you do declare bumpFiles in your config, it will no longer update the defaults.

Example with no declared bumpFiles

> standard-version "--dry-run"

✔ bumping version in package.json from 1.0.0 to 1.1.0
✔ bumping version in composer.json from 1.0.0 to 1.1.0
✔ created CHANGELOG.md
✔ outputting changes to CHANGELOG.md

---
CHANGELOG output...
---

✔ committing composer.json and package.json and CHANGELOG.md
✔ tagging release v1.1.0

Example with only the custom bumpFiles

Config file

// Declare other config above...

config.bumpFiles = [
  {
    filename: "drupal_module_template.info.yml",
    updater: require.resolve("standard-version-updater-yaml")
  }
];

module.exports = config;

Output

> standard-version "--dry-run"

✔ bumping version in drupal_module_template.info.yml from 1.0.0 to 1.1.0
✔ created CHANGELOG.md
✔ outputting changes to CHANGELOG.md

---
CHANGELOG output...
---

✔ committing drupal_module_template.info.yml and CHANGELOG.md
✔ tagging release v1.1.0

Example with all bumpFiles declared

Config file

// Declare other config above...

config.bumpFiles = [
  "package.json",
  "composer.json",
  "package-lock.json",
  "composer.lock",
  {
    filename: "drupal_module_template.info.yml",
    updater: require.resolve("standard-version-updater-yaml")
  }
];

module.exports = config;

Output

> standard-version "--dry-run"

✔ bumping version in package.json from 1.0.0 to 1.1.0
✔ bumping version in composer.json from 1.0.0 to 1.1.0
✔ bumping version in drupal_module_template.info.yml from 1.0.0 to 1.1.0
✔ created CHANGELOG.md
✔ outputting changes to CHANGELOG.md

---
CHANGELOG output...
---

✔ committing drupal_module_template.info.yml and composer.json and package.json and CHANGELOG.md
✔ tagging release v1.1.0
@jbottigliero
Copy link
Member

You are correct, the arguments (bumpFiles) you provide will NOT be merged with the defaults – we can revisit this language, thanks for opening the issue!

coreboot-org-bot pushed a commit to coreboot/arm-trusted-firmware that referenced this issue Jan 26, 2022
Standard Version was not bumping the package metadata files as it
should have been. It's not clear to me why, but there is an open
[GitHub issue][1] for documenting this behaviour.

[1]: conventional-changelog/standard-version#506

Change-Id: Ie89a81272fe507a3d2e1cd33c6ac1bdcc8ac3d75
Signed-off-by: Chris Kay <chris.kay@arm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

2 participants