This repository was archived by the owner on Apr 1, 2025. It is now read-only.
File tree 2 files changed +33
-2
lines changed
2 files changed +33
-2
lines changed Original file line number Diff line number Diff line change @@ -5,13 +5,13 @@ This package is concerned with the CodeGen generation of strongly-typed ASTs.
5
5
The provided ` semantic-ast ` executable is responsible for generating ASTs from language definitions. You can run it like so:
6
6
7
7
```
8
- cabal run semantic-ast -- --language=JSON
8
+ RUNFILES_DIR=path/to/haskell-tree-sitter cabal run semantic-ast -- --rootdir=. --language=JSON
9
9
```
10
10
11
11
You can also pass ` all ` to regenerate every language definition:
12
12
13
13
```
14
- cabal run semantic-ast -- --language=all
14
+ RUNFILES_DIR=path/to/haskell-tree-sitter cabal run semantic-ast -- --rootdir=. --language=all
15
15
```
16
16
17
17
[ Documentation] ( https://github.com/github/semantic/blob/master/docs/codegen.md )
Original file line number Diff line number Diff line change @@ -80,3 +80,34 @@ library
80
80
, unordered-containers ^>= 0.2.10
81
81
82
82
hs-source-dirs : src
83
+
84
+ executable generate-ast
85
+ import : haskell
86
+ hs-source-dirs : app
87
+ main-is : Main.hs
88
+ build-depends :
89
+ semantic-ast,
90
+ base,
91
+ filepath,
92
+ process,
93
+ template-haskell,
94
+ text,
95
+ semantic-source,
96
+ bazel-runfiles,
97
+ directory,
98
+ generic-lens,
99
+ lens,
100
+ neat-interpolation,
101
+ optparse-generic,
102
+ tree-sitter,
103
+ tree-sitter-c,
104
+ tree-sitter-go,
105
+ tree-sitter-java,
106
+ tree-sitter-json,
107
+ tree-sitter-php,
108
+ tree-sitter-python,
109
+ tree-sitter-ql,
110
+ tree-sitter-ruby,
111
+ tree-sitter-rust,
112
+ tree-sitter-tsx,
113
+ tree-sitter-typescript
You can’t perform that action at this time.
0 commit comments