Commit Graph

94 Commits

Author SHA1 Message Date
Nick Rolfe
0a754334cf Don't generate the QL File class 2020-10-30 13:41:27 +00:00
Nick Rolfe
35cb379db7 Fix name of table for locations 2020-10-30 13:24:16 +00:00
Nick Rolfe
a54f923a73 Normalize the absolute path in the files table 2020-10-30 13:22:58 +00:00
Nick Rolfe
4b8bbd101c Give locations full ids matching the common spec 2020-10-30 13:06:21 +00:00
Nick Rolfe
79d15051be Fix full ids for files to match common spec 2020-10-30 12:45:23 +00:00
Nick Rolfe
7f03206b52 Use a key id for file entities 2020-10-30 11:29:04 +00:00
Nick Rolfe
826b4571a0 Canonicalize source file paths in main 2020-10-30 11:21:51 +00:00
Nick Rolfe
d47bd32b58 Now that we also generate conjunctions, use parentheses in disjunctions 2020-10-30 10:34:42 +00:00
Nick Rolfe
f198dc530f Use fromSource = 1
Co-authored-by: Arthur Baars <aibaars@github.com>
2020-10-30 10:25:09 +00:00
Nick Rolfe
2232700428 Correct comment
Co-authored-by: Arthur Baars <aibaars@github.com>
2020-10-30 10:24:24 +00:00
Nick Rolfe
4d5d80c749 Fix location handling to match common db schema requirements 2020-10-29 19:44:16 +00:00
Nick Rolfe
556507cec7 Merge pull request #18 from github/optional_fields
Don't generate an index for optional fields that occur at most once
2020-10-29 15:35:27 +00:00
Nick Rolfe
547d12ca58 Add more info to error message 2020-10-29 15:13:04 +00:00
Nick Rolfe
11c9c18de4 Don't generate an index for optional fields that occur at most once 2020-10-29 13:04:26 +00:00
Arthur Baars
fbb075b477 Merge pull request #17 from github/aibaars/locations-2
TRAP locations: always fix-up empty ranges
2020-10-29 12:15:52 +01:00
Arthur Baars
3350d9d3d4 TRAP locations: always fix-up empty ranges 2020-10-29 10:45:07 +01:00
Arthur Baars
ca91e15a4b Merge pull request #16 from github/aibaars/locations
Fix locations in the
2020-10-28 18:09:58 +01:00
Arthur Baars
4c04b8bb15 Add comment 2020-10-28 17:40:01 +01:00
Arthur Baars
d2f42552f6 Adjust source locations
Tree-sitter row and column numbers are 0-based while CodeQL expects 1-based.
In addition tree-sitter location ranges end-points are exclusive while
CodeQL's ranges are inclusive.
2020-10-28 17:30:03 +01:00
Nick Rolfe
743eca7992 Merge pull request #15 from github/aibaars/ql-folder
Add QL folder structure
2020-10-28 13:11:50 +00:00
Arthur Baars
638fd91e50 Update generator to write the ast.qll file directly into ql/src 2020-10-28 14:04:36 +01:00
Arthur Baars
28a99cfe83 Update path of generated dbscheme 2020-10-28 14:04:36 +01:00
Arthur Baars
88acbc883c Copy dbscheme stats into extractor pack 2020-10-28 14:04:36 +01:00
Arthur Baars
030d957535 Update stats with values measured on bunch of ruby databases 2020-10-28 14:04:36 +01:00
Arthur Baars
5d3f2de685 Add dbscheme to QL folder 2020-10-28 14:04:36 +01:00
Arthur Baars
2e102b8cdf Add folder structure for QL code 2020-10-28 14:04:36 +01:00
Arthur Baars
553e1ab465 Merge pull request #13 from github/aibaars/improve-workflow
Check formatting and cache builds
2020-10-28 14:04:05 +01:00
Arthur Baars
7e6c30b121 Check formatting and cache builds 2020-10-28 13:55:52 +01:00
Nick Rolfe
29899485c7 Merge pull request #11 from github/ql_gen
Generate QL classes
2020-10-28 12:25:53 +00:00
Nick Rolfe
e03d5da8cd Rename a field to avoid using raw identifiers 2020-10-28 12:14:54 +00:00
Nick Rolfe
f4b9c0c71a Merge remote-tracking branch 'origin/main' into ql_gen 2020-10-28 11:41:18 +00:00
Nick Rolfe
24b4586ddd Merge pull request #14 from github/aibaars/remove-storage-index
Extractor: fix child index values
2020-10-28 11:37:38 +00:00
Nick Rolfe
11152583d5 Add get_name() method to simplify logic in field handling 2020-10-28 11:30:50 +00:00
Nick Rolfe
53de99e6af Regenerate QL with fix to Top::getAFieldOrChild 2020-10-28 11:22:21 +00:00
Nick Rolfe
7b51030dd4 Merge remote-tracking branch 'origin/ql_gen' into ql_gen 2020-10-28 11:20:58 +00:00
Nick Rolfe
b4f9599dd9 Simplify hashmap insertion 2020-10-28 11:20:47 +00:00
Nick Rolfe
679ca6d0f1 Update Actions workflow to generate ruby_ast.qll 2020-10-28 11:04:09 +00:00
Nick Rolfe
17820e017c Fix Top::getAFieldOrChild() so it doesn't take an index arg
Co-authored-by: Arthur Baars <aibaars@github.com>
2020-10-28 11:02:42 +00:00
Nick Rolfe
bc22631c32 Simplify QL model following review feedback 2020-10-28 11:00:40 +00:00
Nick Rolfe
77fdafdc95 Simplify error handling with if let 2020-10-28 10:35:33 +00:00
Nick Rolfe
59580d51bb Merge remote-tracking branch 'origin/main' into ql_gen 2020-10-28 10:30:36 +00:00
Arthur Baars
fe1d8ec15f Extractor: fix child index values 2020-10-27 22:32:53 +01:00
Arthur Baars
0c15783f2b Merge pull request #12 from github/crates-language
Use tree-sitter-ruby crate instead of vendoring it
2020-10-27 20:53:48 +01:00
Nick Rolfe
a41c3e36f9 Give node_types a static lifetime. 2020-10-27 19:11:05 +00:00
Nick Rolfe
5484ff3dcf Use tree_sitter_ruby crate in generator 2020-10-27 18:13:40 +00:00
Douglas Creager
2663de86fb Don't clone submodules in Actions workflow
Since we don't have any submodules anymore!
2020-10-27 14:02:15 -04:00
Nick Rolfe
ce8de3feba Update generator binary name in Actions workflow 2020-10-27 17:56:37 +00:00
Douglas Creager
5f985be2d9 Use tree-sitter-ruby crate instead of vendoring it 2020-10-27 13:54:56 -04:00
Nick Rolfe
e05bcf9fb7 Generate QL classes 2020-10-27 17:46:11 +00:00
Arthur Baars
3e1c378aba Merge pull request #8 from github/aibaars/actions
Improve extractor build and add GitHub Actions configuration
2020-10-27 18:21:20 +01:00