-
Notifications
You must be signed in to change notification settings - Fork 667
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
Update pub-lish.md #5803
Update pub-lish.md #5803
Conversation
Visit the preview URL for this PR (updated for commit 42a7745): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jonasfj : A few tweaks for clarification.
### `--skip-validation` | ||
|
||
Publishes without going through the client-side validation process or resolving dependencies. | ||
This is useful for advanced users who knows why the validation might fail and wishes to side step a particularly issues. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion: This needs semantic breaks and active voice.
This is useful for advanced users who knows why the validation might fail and wishes to side step a particularly issues. | |
To side step a particular issue, you might want to use this option. | |
Advanced users might know why the validation might fail, | |
but know the issue would be resolved in other related work. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I updated it to:
This is useful for advanced users who knows why the validation fails and wishes to side step a particularly issues.
I can see how it makes sense to write:
To side step a particular issue, you might want to use this option.
But I kind of wanted to suggest that you should only do this if you are an advanced user and you know what you're doing. And know what particular issue you're side stepping.
The following appears to me like a statement about the knowledge that an "advanced user" may or may not have.
Advanced users might know why the validation might fail,
but know the issue would be resolved in other related work.
I don't understand it.
**Example:** When publishing to pub.dev it may take a few minutes for a newly published package to become available. | ||
Hence, if you are publishing two dependent packages, where the second depends on the first. | ||
You can either wait a few minutes in between publishing the first and the second, or use `--skip-validation` | ||
to publish the second package immediately, by side-stepping client-side valiation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nitpick: Use semantic breaks, write in active voice per GSG, and fix spelling.
**Example:** When publishing to pub.dev it may take a few minutes for a newly published package to become available. | |
Hence, if you are publishing two dependent packages, where the second depends on the first. | |
You can either wait a few minutes in between publishing the first and the second, or use `--skip-validation` | |
to publish the second package immediately, by side-stepping client-side valiation. | |
**Example:** Consider a scenario where you want to publish two packages at the same time. When you publish multiple packages to pub.dev, | |
a few minutes might pass before one package becomes available to other packages. | |
So, if package B depends on package A, | |
this publishing delay would result in a validation error for package B. | |
To avoid this error, you have two choices. | |
1. Wait a few minutes in between publishing the package A and package B. | |
1. Add the `--skip-validation` option to package B. | |
This prevents package B from validating the presence of package A. | |
As you are publishing them at the same time, | |
you know they will both exist on pub.dev | |
and not cause any errors for package users. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't mind splitting the options into bullet points, but this is just a concise example outlining one example where this option is useful. It's not an instruction in how to handle a particular scenario.
I think for reference documentation, it's better to be correct and concise, than easily readable.
I think that some of the wording here causes the example to be less accurate.
Documentation for
dart pub publish --skip-validation
.