mirror of
https://github.com/github/codeql.git
synced 2025-12-17 01:03:14 +01:00
Update generator to write the ast.qll file directly into ql/src
This commit is contained in:
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
@@ -50,7 +50,7 @@ jobs:
|
||||
if: ${{ matrix.os == 'ubuntu-latest' }}
|
||||
with:
|
||||
name: ruby_ast.qll
|
||||
path: ruby_ast.qll
|
||||
path: ql/src/codeql_ruby/ast.qll
|
||||
- uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: extractor-${{ matrix.os }}
|
||||
|
||||
@@ -12,11 +12,11 @@ cargo build --release
|
||||
|
||||
## Generating the database schema and QL library
|
||||
|
||||
The generated `ruby.dbscheme` and `ruby_ast.qll` files are included in the repository, but they can be re-generated as follows:
|
||||
The generated `ql/src/ruby.dbscheme` and `ql/src/codeql_ruby/ast.qll` files are included in the repository, but they can be re-generated as follows:
|
||||
|
||||
```bash
|
||||
# Run the generator
|
||||
cargo run --release -p ruby-generator
|
||||
# Then auto-format the QL library
|
||||
codeql query format -i ruby_ast.qll
|
||||
codeql query format -i ql/src/codeql_ruby/ast.qll
|
||||
```
|
||||
|
||||
@@ -287,7 +287,7 @@ fn main() {
|
||||
name: "Ruby".to_string(),
|
||||
node_types: tree_sitter_ruby::NODE_TYPES,
|
||||
dbscheme_path: PathBuf::from("ql/src/ruby.dbscheme"),
|
||||
ql_library_path: PathBuf::from("ruby_ast.qll"),
|
||||
ql_library_path: PathBuf::from("ql/src/codeql_ruby/ast.qll"),
|
||||
};
|
||||
match node_types::read_node_types_str(&ruby.node_types) {
|
||||
Err(e) => {
|
||||
|
||||
Reference in New Issue
Block a user