Skip to content
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

Add-DBOBuild adds files identical to previous build #164

Open
brabantj opened this issue Nov 15, 2023 · 1 comment
Open

Add-DBOBuild adds files identical to previous build #164

brabantj opened this issue Nov 15, 2023 · 1 comment

Comments

@brabantj
Copy link

I am not sure why this happens but when I run the command
$newPackage = Add-DBOBuild -Path $package -ScriptPath $sqlPathItems -Build 5.4 -Type Unique, New, Modified

The new build has many of the same files as the last existing build in the package (5.3).
For example, if I look in the dbops.package.json, build 5.3 has a file like this one
{
"PackagePath": "90 - Scripts/abc.sql",
"Hash": "0x1B5018D66760F9053685CC3CFE5FD23C"
}
and build 5.4 will also have it with the same path and hash....

Build 5.2 has all the files
Build 5.3 seems to have only the new and modified ones since 5.2 which is ok
Build 5.4 has 90% the same files as 5.3 with same hash and files were not updated at all.

@nvarscar
Copy link
Collaborator

You should be able to tell the reasons why the file was added to the package by running the command with -Verbose mode on. The logic is here:
https://github.com/dataplat/dbops/blob/development/functions/Add-DBOBuild.ps1#L114-L133
, and it is enough to meet one criteria among (New, Unique, Modified) to be added to the build.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants