Skip to content

Commit

Permalink
init: clarify that .dvc is added to Git automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
jorgeorpinel committed Apr 23, 2020
1 parent 8d8a36e commit f7c9ab1
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 20 deletions.
9 changes: 5 additions & 4 deletions content/docs/command-reference/init.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,11 @@ advanced scenarios:
- [Initializing DVC without Git](#how-does-it-affect-dvc-commands) - support for
SCM other than Git, deployment automation cases, etc.

At DVC initialization, a new `.dvc/` directory will be created for internal
configuration and cache
[files and directories](/doc/user-guide/dvc-files-and-directories) that are
hidden from the user.
At DVC initialization, a new `.dvc/` directory is created for internal
configuration and <abbr>cache</abbr>
[files and directories](/doc/user-guide/dvc-files-and-directories), that are
hidden from the user. This directory is automatically staged with `git add`, so
it can be easily committed with Git.

### Initializing DVC in subdirectories

Expand Down
15 changes: 7 additions & 8 deletions content/docs/tutorials/deep/preparation.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,19 +58,18 @@ $ pip install -r code/requirements.txt

## Initialize

DVC works on top of Git repositories. You run DVC initialization in a repository
directory to create DVC meta files and directories.

At DVC initialization, a new `.dvc/` directory will be created for internal
configuration and cache
[files and directories](/doc/user-guide/dvc-files-and-directories) that are
hidden from the user. We describe some DVC internals below for a better
understanding of how it works.
DVC works best inside Git repositories like the one we're in. Initialize DVC
with:

```dvc
$ dvc init
...
At DVC initialization, a new `.dvc/` directory is created for internal
configuration and <abbr>cache</abbr>
[files and directories](/doc/user-guide/dvc-files-and-directories), that are
hidden from the user. This directory is automatically staged with `git add`, so it can be easily committed with Git:
$ ls -a .dvc
. .. .gitignore config tmp
Expand Down
9 changes: 5 additions & 4 deletions content/docs/tutorials/pipelines.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,11 @@ When we run `dvc add` `Posts.xml.zip`, DVC creates a

### Expand to learn about DVC internals

At DVC initialization, a new `.dvc/` directory will be created for internal
configuration and cache
[files and directories](/doc/user-guide/dvc-files-and-directories) that are
hidden from the user.
At DVC initialization, a new `.dvc/` directory is created for internal
configuration and <abbr>cache</abbr>
[files and directories](/doc/user-guide/dvc-files-and-directories), that are
hidden from the user. This directory is automatically staged with `git add`, so
it can be easily committed with Git.

Note that the DVC-file created by `dvc add` has no dependencies, a.k.a. an
_orphan_ [stage file](/doc/command-reference/run):
Expand Down
9 changes: 5 additions & 4 deletions content/docs/use-cases/versioning-data-and-model-files.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,11 @@ initialize the <abbr>DVC project</abbr> on top of the existing repository:
$ dvc init
```

At DVC initialization, a new `.dvc/` directory will be created for internal
configuration and cache
[files and directories](/doc/user-guide/dvc-files-and-directories) that are
hidden from the user. These can safely be tracked with Git:
At DVC initialization, a new `.dvc/` directory is created for internal
configuration and <abbr>cache</abbr>
[files and directories](/doc/user-guide/dvc-files-and-directories), that are
hidden from the user. This directory is automatically staged with `git add`, so
it can be easily committed with Git:

```dvc
$ git status
Expand Down

0 comments on commit f7c9ab1

Please sign in to comment.