Skip to content

Commit ad7b09e

Browse files
slhcksindresorhus
andauthored
improve messages related to new files and dependencies (#702)
Co-authored-by: Sindre Sorhus <[email protected]>
1 parent 0a7abf4 commit ad7b09e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

source/ui.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -94,15 +94,15 @@ const checkNewFilesAndDependencies = async (pkg, rootDir) => {
9494

9595
const messages = [];
9696
if (newFiles.unpublished.length > 0) {
97-
messages.push(`The following new files will not be part of your published package:\n${util.joinList(newFiles.unpublished)}`);
97+
messages.push(`The following new files will not be part of your published package:\n${util.joinList(newFiles.unpublished)}\n\nIf you intended to publish them, add them to the \`files\` field in package.json.`);
9898
}
9999

100100
if (newFiles.firstTime.length > 0) {
101-
messages.push(`The following new files will be published for the first time:\n${util.joinList(newFiles.firstTime)}`);
101+
messages.push(`The following new files will be published for the first time:\n${util.joinList(newFiles.firstTime)}\n\nPlease make sure only the intended files are listed.`);
102102
}
103103

104104
if (newDependencies.length > 0) {
105-
messages.push(`The following new dependencies will be part of your published package:\n${util.joinList(newDependencies)}`);
105+
messages.push(`The following new dependencies will be part of your published package:\n${util.joinList(newDependencies)}\n\nPlease make sure these new dependencies are intentional.`);
106106
}
107107

108108
if (!isInteractive()) {

0 commit comments

Comments
 (0)