From fb1480d267c38f7909b423c00ee8314609480a78 Mon Sep 17 00:00:00 2001 From: Mirna Wong <89008547+mirnawong1@users.noreply.github.com> Date: Wed, 10 Apr 2024 18:26:10 +0100 Subject: [PATCH 1/6] Update version-control-basics.md update gitignore content per slack thread here: https://dbt-labs.slack.com/archives/C012TTNN0JK/p1712760453549829 --- .../docs/collaborate/git/version-control-basics.md | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/website/docs/docs/collaborate/git/version-control-basics.md b/website/docs/docs/collaborate/git/version-control-basics.md index c7eca740c8f..5b5199ebee6 100644 --- a/website/docs/docs/collaborate/git/version-control-basics.md +++ b/website/docs/docs/collaborate/git/version-control-basics.md @@ -54,11 +54,7 @@ Refer to [merge conflicts](/docs/collaborate/git/merge-conflicts) to learn how t ## The .gitignore file -To make sure dbt Cloud runs smoothly, you must exclude certain sub-folders in your git repository containing your dbt project from being tracked by git. You can achieve this by adding three lines to a special file named [.gitignore](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore). This file is placed in the root folder of your dbt project. - -Some git providers will automatically create a 'boilerplate' `.gitignore` file when the repository is created. However, based on dbt Labs' experience, these default `.gitignore` files typically don't include the required entries for dbt Cloud to function correctly. - -The `.gitignore` file can include unrelated files and folders if the code repository requires it. However, the following folders must be included in the `gitignore` file to ensure dbt Cloud operates smoothly: +dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) that automatically excludes the following sub-folders from your git repository to ensure smooth operation: ``` dbt_packages/ @@ -66,12 +62,15 @@ logs/ target/ ``` -**Note** — By using a trailing slash, these lines in the `gitignore` file serve as 'folder wildcards', excluding all files and folders within those folders from being tracked by git. +This file, found in the root of your dbt project, prevents these directories from being tracked by git. Although this global setting is in place, dbt Cloud also acknowledges individual `.gitignore` files, allowing you to specify additional exclusions as needed for your project. +It's worth noting that while some git providers generate a basic `.gitignore` file when the repository is created, these often lack the necessary exclusions for dbt Cloud. This means it's important to ensure you add the three lines mentioned previously in your `.gitignore` to ensure dbt Cloud operates smoothly. + +**Note** — By using a trailing slash, these lines in the `gitignore` file serve as 'folder wildcards', excluding all files and folders within those folders from being tracked by git. :::note -- **dbt Cloud projects created after Dec 1, 2022** — If you use the **Initialize dbt Project** button in the dbt Cloud IDE to setup a new and empty dbt project, dbt Cloud will automatically add a `.gitignore` file with the required entries. If a `.gitignore` file already exists, the necessary folders will be appended to the existing file. +- **dbt Cloud projects created after Dec 1, 2022** — If you use the **Initialize dbt Project** button in the dbt Cloud IDE to set up a new and empty dbt project, dbt Cloud will automatically add a `.gitignore` file with the required entries. If a `.gitignore` file already exists, the necessary folders will be appended to the existing file. - **Migrating project from Core to dbt Cloud** — Make sure you check the `.gitignore` file contains the necessary entries. dbt Core doesn't interact with git so dbt Cloud doesn't automatically add or verify entries in the `.gitignore` file. Additionally, if the repository already contains dbt code and doesn't require initialization, dbt Cloud won't add any missing entries to the .gitignore file. ::: From b11ed04c3a4ef98d86a7dafd084d303c85ff89a1 Mon Sep 17 00:00:00 2001 From: Mirna Wong <89008547+mirnawong1@users.noreply.github.com> Date: Wed, 10 Apr 2024 18:40:10 +0100 Subject: [PATCH 2/6] Update version-control-basics.md --- website/docs/docs/collaborate/git/version-control-basics.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/website/docs/docs/collaborate/git/version-control-basics.md b/website/docs/docs/collaborate/git/version-control-basics.md index 5b5199ebee6..3bbae9148cc 100644 --- a/website/docs/docs/collaborate/git/version-control-basics.md +++ b/website/docs/docs/collaborate/git/version-control-basics.md @@ -61,12 +61,11 @@ dbt_packages/ logs/ target/ ``` +**Note** — By using a trailing slash, these lines in the `gitignore` file serve as 'folder wildcards', excluding all files and folders within those folders from being tracked by git This file, found in the root of your dbt project, prevents these directories from being tracked by git. Although this global setting is in place, dbt Cloud also acknowledges individual `.gitignore` files, allowing you to specify additional exclusions as needed for your project. -It's worth noting that while some git providers generate a basic `.gitignore` file when the repository is created, these often lack the necessary exclusions for dbt Cloud. This means it's important to ensure you add the three lines mentioned previously in your `.gitignore` to ensure dbt Cloud operates smoothly. - -**Note** — By using a trailing slash, these lines in the `gitignore` file serve as 'folder wildcards', excluding all files and folders within those folders from being tracked by git. +It's worth noting that while some git providers generate a basic `.gitignore` file when the repository is created, these often lack the necessary exclusions for dbt Cloud. This means it's important to ensure you add the three lines mentioned previously in your `.gitignore` to ensure dbt Cloud operates smoothly.. :::note From aa6b2d7e7bc835d3edbf1d70e955de9b92c9f595 Mon Sep 17 00:00:00 2001 From: Mirna Wong <89008547+mirnawong1@users.noreply.github.com> Date: Wed, 10 Apr 2024 18:50:03 +0100 Subject: [PATCH 3/6] Update version-control-basics.md update per naomi's feedback --- .../docs/docs/collaborate/git/version-control-basics.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/website/docs/docs/collaborate/git/version-control-basics.md b/website/docs/docs/collaborate/git/version-control-basics.md index 3bbae9148cc..9010b1eafa9 100644 --- a/website/docs/docs/collaborate/git/version-control-basics.md +++ b/website/docs/docs/collaborate/git/version-control-basics.md @@ -54,18 +54,19 @@ Refer to [merge conflicts](/docs/collaborate/git/merge-conflicts) to learn how t ## The .gitignore file -dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) that automatically excludes the following sub-folders from your git repository to ensure smooth operation: +dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) that automatically excludes the following sub-folders from your git repository to ensure smooth operation. This global `.gitignore` is automatically applied to projects in dbt Cloud, ensuring these directories are not tracked, which is crucial for smooth dbt Cloud operation: ``` dbt_packages/ logs/ target/ ``` -**Note** — By using a trailing slash, these lines in the `gitignore` file serve as 'folder wildcards', excluding all files and folders within those folders from being tracked by git -This file, found in the root of your dbt project, prevents these directories from being tracked by git. Although this global setting is in place, dbt Cloud also acknowledges individual `.gitignore` files, allowing you to specify additional exclusions as needed for your project. +This inclusion uses a trailing slash, making these lines in the `.gitignore` file act as 'folder wildcards' that prevent any files or folders within them from being tracked by git. You can also specify additional exclusions as needed for your project. -It's worth noting that while some git providers generate a basic `.gitignore` file when the repository is created, these often lack the necessary exclusions for dbt Cloud. This means it's important to ensure you add the three lines mentioned previously in your `.gitignore` to ensure dbt Cloud operates smoothly.. +However, this global `.gitignore` _does not_ apply to dbt Core and dbt Cloud CLI users directly. Therefore, if you're working with dbt Core or dbt Cloud CLI, you need to manually add these three lines to your project's `.gitignore` file. + +It's worth noting that while some git providers generate a basic `.gitignore` file when the repository is created, these often lack the necessary exclusions for dbt Cloud. This means it's important to ensure you add the three lines mentioned previously in your `.gitignore` to ensure dbt Cloud operates smoothly. :::note From 62c6e30de36831641fdab10b956d77de99b727bd Mon Sep 17 00:00:00 2001 From: Mirna Wong <89008547+mirnawong1@users.noreply.github.com> Date: Thu, 11 Apr 2024 13:01:19 +0100 Subject: [PATCH 4/6] Update website/docs/docs/collaborate/git/version-control-basics.md --- website/docs/docs/collaborate/git/version-control-basics.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/docs/collaborate/git/version-control-basics.md b/website/docs/docs/collaborate/git/version-control-basics.md index 9010b1eafa9..e8e607d301f 100644 --- a/website/docs/docs/collaborate/git/version-control-basics.md +++ b/website/docs/docs/collaborate/git/version-control-basics.md @@ -54,7 +54,7 @@ Refer to [merge conflicts](/docs/collaborate/git/merge-conflicts) to learn how t ## The .gitignore file -dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) that automatically excludes the following sub-folders from your git repository to ensure smooth operation. This global `.gitignore` is automatically applied to projects in dbt Cloud, ensuring these directories are not tracked, which is crucial for smooth dbt Cloud operation: +dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) (ensuring these directories are not tracked) that automatically excludes the following sub-folders from your git repository to ensure smooth operation: ``` dbt_packages/ From d1a3bcf12b60cb9c8b0effcb44b22febefb59e61 Mon Sep 17 00:00:00 2001 From: Mirna Wong <89008547+mirnawong1@users.noreply.github.com> Date: Thu, 11 Apr 2024 13:01:48 +0100 Subject: [PATCH 5/6] Update website/docs/docs/collaborate/git/version-control-basics.md --- website/docs/docs/collaborate/git/version-control-basics.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/docs/collaborate/git/version-control-basics.md b/website/docs/docs/collaborate/git/version-control-basics.md index e8e607d301f..11e5035f7b8 100644 --- a/website/docs/docs/collaborate/git/version-control-basics.md +++ b/website/docs/docs/collaborate/git/version-control-basics.md @@ -54,7 +54,7 @@ Refer to [merge conflicts](/docs/collaborate/git/merge-conflicts) to learn how t ## The .gitignore file -dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) (ensuring these directories are not tracked) that automatically excludes the following sub-folders from your git repository to ensure smooth operation: +dbt Cloud implements a global [`.gitignore file`](https://github.com/dbt-labs/dbt-starter-project/blob/main/.gitignore) that automatically excludes the following sub-folders from your git repository to ensure smooth operation: ``` dbt_packages/ From 51296ed97960561f5c973dc5de9b28052ebcc5cd Mon Sep 17 00:00:00 2001 From: Mirna Wong <89008547+mirnawong1@users.noreply.github.com> Date: Thu, 11 Apr 2024 13:02:28 +0100 Subject: [PATCH 6/6] Update website/docs/docs/collaborate/git/version-control-basics.md --- website/docs/docs/collaborate/git/version-control-basics.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/docs/docs/collaborate/git/version-control-basics.md b/website/docs/docs/collaborate/git/version-control-basics.md index 11e5035f7b8..92f8349d2cd 100644 --- a/website/docs/docs/collaborate/git/version-control-basics.md +++ b/website/docs/docs/collaborate/git/version-control-basics.md @@ -64,7 +64,7 @@ target/ This inclusion uses a trailing slash, making these lines in the `.gitignore` file act as 'folder wildcards' that prevent any files or folders within them from being tracked by git. You can also specify additional exclusions as needed for your project. -However, this global `.gitignore` _does not_ apply to dbt Core and dbt Cloud CLI users directly. Therefore, if you're working with dbt Core or dbt Cloud CLI, you need to manually add these three lines to your project's `.gitignore` file. +However, this global `.gitignore` _does not_ apply to dbt Core and dbt Cloud CLI users directly. Therefore, if you're working with dbt Core or dbt Cloud CLI, you need to manually add the three lines mentioned previously to your project's `.gitignore` file. It's worth noting that while some git providers generate a basic `.gitignore` file when the repository is created, these often lack the necessary exclusions for dbt Cloud. This means it's important to ensure you add the three lines mentioned previously in your `.gitignore` to ensure dbt Cloud operates smoothly.