8000 Update documentation for validate command by PrinsFrank · Pull Request #12137 · composer/composer · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Update documentation for validate command #12137

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

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions doc/03-cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -729,8 +729,10 @@ packages depending on the packages that cause the conflict.
## validate

You should always run the `validate` command before you commit your
`composer.json` file, and before you tag a release. It will check if your
`composer.json` is valid.
`composer.json` file (and `composer.lock` [if applicable](01-basic-usage.md#commit-your-composer-lock-file-to-version-control)), and before you tag a release.

It will check if your
`composer.json` is valid. If a `composer.lock` exists, it will also check if it is up to date with the `composer.json`.

```shell
php composer.phar validate
Expand All @@ -740,7 +742,9 @@ php composer.phar validate

* **--no-check-all:** Do not emit a warning if requirements in `composer.json` use unbound or overly strict version constraints.
* **--no-check-lock:** Do not emit an error if `composer.lock` exists and is not up to date.
* **--check-lock** Check if lock file is up to date (even when [config.lock](06-config.md#lock) is false)
* **--no-check-publish:** Do not emit an error if `composer.json` is unsuitable for publishing as a package on Packagist but is otherwise valid.
* **--no-check-version:** Do not emit an error if the version field is present.
* **--with-dependencies:** Also validate the composer.json of all installed dependencies.
* **--strict:** Return a non-zero exit code for warnings as well as errors.

Expand Down
0