Skip to content

Commit

Permalink
Updating deps command page (#4526)
Browse files Browse the repository at this point in the history
## What are you changing in this pull request and why?

Addressing community feedback here:
https://dbt-labs.slack.com/archives/C02NCQ9483C/p1700602038744759

Closes #4481

## Checklist

- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
so my content adheres to these guidelines.
- [x] For [docs
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#about-versioning),
review how to [version a whole
page](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
and [version a block of
content](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-blocks-of-content).
- [x] Add a checklist item for anything that needs to happen before this
PR is merged, such as "needs technical review" or "change base branch."
  • Loading branch information
matthewshaver authored Dec 18, 2023
2 parents cc78366 + b84d3d5 commit d229620
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion website/docs/reference/commands/deps.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,11 @@ Update your versions in packages.yml, then run dbt deps

dbt generates the `package-lock.yml` file in the _project_root_ where `packages.yml` is recorded, which contains all the resolved packages, the first time you run `dbt deps`. Each subsequent run records the packages installed in this file. If the subsequent `dbt deps` runs contain no updated packages in `dependencies.yml` or `packages.yml`, dbt-core installs from `package-lock.yml`.

When you update the package spec and run `dbt deps` again, the package-lock and package files update accordingly. You can run `dbt deps --lock` to update the `package-lock.yml` with the most recent dependencies from `packages`.
When you update the package spec and run `dbt deps` again, the `package-lock.yml` and `packages.yml` files update accordingly.

There are two flags related to `package-lock.yml`:
- `dbt deps --lock` — creates or updates the `package-lock.yml` file but does not install the packages.
- `dbt deps --upgrade` — creates or updates the `package-lock.yml` file with the most recent dependencies from `packages.yml`. Also install the packages unless the `--lock` flag is also passed.

The `--add-package` flag allows you to add a package to the `packages.yml` with configurable `--version` and `--source` information. The `--dry-run` flag, when set to `False`(default), recompiles the `package-lock.yml` file after a new package is added to the `packages.yml` file. Set the flag to `True` for the changes to not persist.

Expand Down

0 comments on commit d229620

Please sign in to comment.