You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When adding a new rule, the `s/new-rule` script will create stubs for your rule in Rust and in Documentation site.
234
232
235
233
```bash
236
234
s/new-rule 'prefer big serial'
237
235
```
238
236
239
-
### releasing a new version
237
+
### Releasing a New Version
240
238
241
239
1. Update the `CHANGELOG.md`
242
240
@@ -253,17 +251,12 @@ s/new-rule 'prefer big serial'
253
251
254
252
Use the text and version from the `CHANGELOG.md`
255
253
256
-
### algolia
254
+
### Algolia
257
255
258
256
The squawkhq.com Algolia index can be found on [the crawler website](https://crawler.algolia.com/admin/crawlers/9bf0dffb-bc5a-4d46-9b8d-2f1197285213/overview). Algolia reindexes the site every day at 5:30 (UTC).
259
257
260
-
## how it works
261
-
262
-
squawk wraps calls to [libpg_query-sys](https://github.com/tdbgamer/libpg_query-sys) in a safe
263
-
interface and parses the JSON into easier to work with structures.
264
-
libpg_query-sys in turn uses [bindgen](https://rust-lang.github.io/rust-bindgen/) to bind to
265
-
[libpg_query](https://github.com/lfittl/libpg_query), which itself wraps Postgres' SQL
266
-
parser in a bit of C code that outputs the parsed AST into a JSON string.
258
+
## How it Works
267
259
268
-
Squawk then runs the rule functions over the parsed AST, gathers and pretty
269
-
prints the rule violations.
260
+
Squawk uses its parser (based on rust-analyzer's parser) to create a CST. The
261
+
linters then use an AST layered on top of the CST to navigate and record
0 commit comments