mirror of
https://github.com/github/semantic.git
synced 2024-11-22 23:29:37 +03:00
hacky crap to get semantic-ruby working
This commit is contained in:
parent
f85e082e2f
commit
48604a9d81
@ -79,6 +79,7 @@ stack_snapshot(
|
||||
"trifecta",
|
||||
"tree-sitter",
|
||||
"tree-sitter-python",
|
||||
"tree-sitter-ruby",
|
||||
"unordered-containers",
|
||||
],
|
||||
tools = ["@happy"]
|
||||
|
49
semantic-ruby/BUILD.bazel
Normal file
49
semantic-ruby/BUILD.bazel
Normal file
@ -0,0 +1,49 @@
|
||||
# Set all target’s visibility in this package to "public".
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
# Load rules_haskell rules.
|
||||
load(
|
||||
"@rules_haskell//haskell:defs.bzl",
|
||||
"haskell_toolchain_library",
|
||||
"haskell_library",
|
||||
"haskell_binary",
|
||||
)
|
||||
|
||||
load("@rules_haskell//haskell:cabal.bzl", "haskell_cabal_binary", "haskell_cabal_library")
|
||||
|
||||
# haskell_toolchain_library can access builtin GHC packages
|
||||
# and assign them a bazel target name, so that they
|
||||
# can be referenced as dependencies.
|
||||
haskell_toolchain_library(name = "base")
|
||||
|
||||
# You can add your own libraries with haskell_library.
|
||||
haskell_library(
|
||||
name = "lib",
|
||||
src_strip_prefix = "src",
|
||||
srcs = glob(['src/**/*.hs']),
|
||||
deps = [
|
||||
":base",
|
||||
"//semantic-analysis:lib",
|
||||
"//semantic-ast:lib",
|
||||
"//semantic-core:lib",
|
||||
"//semantic-scope-graph:lib",
|
||||
"//semantic-source:lib",
|
||||
"//semantic-tags:lib",
|
||||
"@stackage//:aeson",
|
||||
"@stackage//:algebraic-graphs",
|
||||
"@stackage//:containers",
|
||||
"@stackage//:fused-effects",
|
||||
"@stackage//:fused-syntax",
|
||||
"@stackage//:generic-lens",
|
||||
"@stackage//:generic-monoid",
|
||||
"@stackage//:hashable",
|
||||
"@stackage//:lens",
|
||||
"@stackage//:pathtype",
|
||||
"@stackage//:semilattices",
|
||||
"@stackage//:template-haskell",
|
||||
"@stackage//:text",
|
||||
"@stackage//:tree-sitter",
|
||||
"@stackage//:tree-sitter-ruby",
|
||||
]
|
||||
|
||||
)
|
@ -20,4 +20,4 @@ import AST.GenerateSyntax
|
||||
import Language.Haskell.TH.Syntax (runIO)
|
||||
import qualified TreeSitter.Ruby as Ruby (getNodeTypesPath, getTestCorpusDir, tree_sitter_ruby)
|
||||
|
||||
runIO Ruby.getNodeTypesPath >>= astDeclarationsForLanguage Ruby.tree_sitter_ruby
|
||||
astDeclarationsForLanguage Ruby.tree_sitter_ruby "/Users/patrickt/src/semantic/semantic-ruby/src/Language/Ruby/node-types.json"
|
||||
|
3378
semantic-ruby/src/Language/Ruby/node-types.json
Normal file
3378
semantic-ruby/src/Language/Ruby/node-types.json
Normal file
File diff suppressed because it is too large
Load Diff
@ -10,3 +10,4 @@ packages:
|
||||
- fused-effects-1.0.2.0
|
||||
- tree-sitter-0.9.0.1
|
||||
- tree-sitter-python-0.9.0.2
|
||||
- tree-sitter-ruby-0.5.0.2
|
||||
|
Loading…
Reference in New Issue
Block a user