Move IgnoredTables into ignore_patterns.go

This commit is contained in:
Nick Tobey
2023-04-27 15:53:00 -07:00
parent 211e3ce6a5
commit db7600a822
2 changed files with 7 additions and 6 deletions
@@ -31,6 +31,13 @@ type ignorePattern struct {
ignore bool
}
// IgnoredTables contains the results of comparing a series of tables to a set of dolt_ignore patterns.
type IgnoredTables struct {
Ignore []string
DontIgnore []string
Conflicts []DoltIgnoreConflictError
}
// IgnoreResult is an enum containing the result of matching a table name against the list of ignored table patterns
type IgnoreResult int
-6
View File
@@ -1055,12 +1055,6 @@ func UnionTableNames(ctx context.Context, roots ...*RootValue) ([]string, error)
return tblNames, nil
}
type IgnoredTables struct {
Ignore []string
DontIgnore []string
Conflicts []DoltIgnoreConflictError
}
// FilterIgnoredTables takes a slice of table names and divides it into new slices based on whether the table is ignored, not ignored, or matches conflicting ignore patterns.
func FilterIgnoredTables(ctx context.Context, tables []string, roots Roots) (ignoredTables IgnoredTables, err error) {
ignorePatterns, err := GetIgnoredTablePatterns(ctx, roots)