Yarn would like to add a git tag when publishing a node module. However this folder is added to gitignore.
yarn publish dist
Output:
The following paths are ignored by one of your .gitignore files:
dist/package.json
Use -f if you really want to add them.
info Visit https://yarnpkg.com/en/docs/cli/publish for documentation about this command.
How can you keep dist in gitignore, but make an exception for yarn to be able to add the dist folder to a git commit?
I've tried:
-.npmignore without dist folder (-->ignored by yarn)
-add a files array to package.json
-anyone has other suggestions?