Skip to content

Commit f3fd30c

Browse files
committed
progress
1 parent 9d34d82 commit f3fd30c

File tree

4 files changed

+52
-16
lines changed

4 files changed

+52
-16
lines changed

crates/pgls_diagnostics_categories/src/categories.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,6 @@ define_categories! {
9292
"lint",
9393
"lint/performance",
9494
"lint/safety",
95-
// splinter groups start
96-
"dblint",
97-
"dblint/splinter",
98-
// splinter groups end
9995
// Lint groups end
100-
}
96+
}
97+

packages/@postgres-language-server/backend-jsonrpc/src/workspace.ts

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,28 @@ export type Category =
9595
| "lint/safety/requireConcurrentIndexDeletion"
9696
| "lint/safety/runningStatementWhileHoldingAccessExclusive"
9797
| "lint/safety/transactionNesting"
98+
| "dblint/splinter/authRlsInitplan"
99+
| "dblint/splinter/authUsersExposed"
100+
| "dblint/splinter/duplicateIndex"
101+
| "dblint/splinter/extensionInPublic"
102+
| "dblint/splinter/extensionVersionsOutdated"
103+
| "dblint/splinter/fkeyToAuthUnique"
104+
| "dblint/splinter/foreignTableInApi"
105+
| "dblint/splinter/functionSearchPathMutable"
106+
| "dblint/splinter/insecureQueueExposedInApi"
107+
| "dblint/splinter/materializedViewInApi"
108+
| "dblint/splinter/multiplePermissivePolicies"
109+
| "dblint/splinter/noPrimaryKey"
110+
| "dblint/splinter/policyExistsRlsDisabled"
111+
| "dblint/splinter/rlsDisabledInPublic"
112+
| "dblint/splinter/rlsEnabledNoPolicy"
113+
| "dblint/splinter/rlsReferencesUserMetadata"
114+
| "dblint/splinter/securityDefinerView"
115+
| "dblint/splinter/tableBloat"
116+
| "dblint/splinter/unindexedForeignKeys"
117+
| "dblint/splinter/unknown"
118+
| "dblint/splinter/unsupportedRegTypes"
119+
| "dblint/splinter/unusedIndex"
98120
| "stdin"
99121
| "check"
100122
| "configuration"
@@ -111,7 +133,9 @@ export type Category =
111133
| "dummy"
112134
| "lint"
113135
| "lint/performance"
114-
| "lint/safety";
136+
| "lint/safety"
137+
| "dblint"
138+
| "dblint/splinter";
115139
export interface Location {
116140
path?: Resource_for_String;
117141
sourceCode?: string;

packages/@postgrestools/backend-jsonrpc/src/workspace.ts

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,28 @@ export type Category =
9595
| "lint/safety/requireConcurrentIndexDeletion"
9696
| "lint/safety/runningStatementWhileHoldingAccessExclusive"
9797
| "lint/safety/transactionNesting"
98+
| "dblint/splinter/authRlsInitplan"
99+
| "dblint/splinter/authUsersExposed"
100+
| "dblint/splinter/duplicateIndex"
101+
| "dblint/splinter/extensionInPublic"
102+
| "dblint/splinter/extensionVersionsOutdated"
103+
| "dblint/splinter/fkeyToAuthUnique"
104+
| "dblint/splinter/foreignTableInApi"
105+
| "dblint/splinter/functionSearchPathMutable"
106+
| "dblint/splinter/insecureQueueExposedInApi"
107+
| "dblint/splinter/materializedViewInApi"
108+
| "dblint/splinter/multiplePermissivePolicies"
109+
| "dblint/splinter/noPrimaryKey"
110+
| "dblint/splinter/policyExistsRlsDisabled"
111+
| "dblint/splinter/rlsDisabledInPublic"
112+
| "dblint/splinter/rlsEnabledNoPolicy"
113+
| "dblint/splinter/rlsReferencesUserMetadata"
114+
| "dblint/splinter/securityDefinerView"
115+
| "dblint/splinter/tableBloat"
116+
| "dblint/splinter/unindexedForeignKeys"
117+
| "dblint/splinter/unknown"
118+
| "dblint/splinter/unsupportedRegTypes"
119+
| "dblint/splinter/unusedIndex"
98120
| "stdin"
99121
| "check"
100122
| "configuration"
@@ -111,7 +133,9 @@ export type Category =
111133
| "dummy"
112134
| "lint"
113135
| "lint/performance"
114-
| "lint/safety";
136+
| "lint/safety"
137+
| "dblint"
138+
| "dblint/splinter";
115139
export interface Location {
116140
path?: Resource_for_String;
117141
sourceCode?: string;

xtask/codegen/src/generate_splinter.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -128,15 +128,6 @@ fn update_categories_file(rules: BTreeMap<String, RuleInfo>) -> Result<()> {
128128
&format!("\n{}\n ", splinter_entries),
129129
)?;
130130

131-
// Replace content between splinter groups markers
132-
let groups_start = "// splinter groups start";
133-
let groups_end = "// splinter groups end";
134-
135-
let groups_content = "\n \"dblint\",\n \"dblint/splinter\",\n ";
136-
137-
let new_content =
138-
replace_between_markers(&new_content, groups_start, groups_end, groups_content)?;
139-
140131
fs2::write(categories_path, new_content)?;
141132

142133
Ok(())

0 commit comments

Comments
 (0)