add option ignoreFile to ignore file's contents like .gitignore
as mentioned in docs the commit will include everything in assets even if it is included in .gitignore.
you can add an option to ignore a file's contents like that
["@semantic-release/git", {
assets: ["**/*.*"],
ignoreFile= '.gitignore'
}]
this approach is used by many tools tile eslint and prettier
also, it is a good idea to add an option to include changed files only
Since this hasn't been closed or commented on, I have to imagine the maintainers would be okay with this. I'll make a PR for this sometime soon. :smile:
For posterity, this is related to #345 (a duplicate) and #55 (when this behavior was added).
To minimize maintenance burden, I'll make a boolean config flag named respectIgnoreFile. All setting it to true will do is drop the --force we send to the git add command.
EDIT: PR Created!
very nice effort @Kenneth-Sills, you saved too many verbose configurations for many developers with this PR