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

Metadata feature #252

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

jhonny111s
Copy link

On many occasions we want to be able to add general information to our changelog, and we can obtain that metadata from git config and from the package. In this case I would like to receive feedback to make this feature safe.

This would be a subset of information that we could obtain in metadata

{
      now: "20 January 2021",
      version: "1.0.0",
      name: "my-repository",
      description: "description-repository",
      user: { name: "John Doe", email: "[email protected]" }
}

see template-metadata

.split('\n')
.reduce((acum, item) => {
const [key, value] = item.split(DIVIDER)
return merge(acum, dotNotationToObject(key, value))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why lodash and not Object.assign?

@@ -0,0 +1,42 @@
const merge = require('lodash/merge');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

using lodash is a CVE magnet; please use lodash.merge instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants