Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQLite grammar? #57

Open
StevenACoffman opened this issue Dec 15, 2021 · 2 comments
Open

SQLite grammar? #57

StevenACoffman opened this issue Dec 15, 2021 · 2 comments

Comments

@StevenACoffman
Copy link

馃憢 Hi,
This go binding is pretty great! I would love to be able to use this for SQL, specifically SQLite (and possibly PostgreSQL). I've found https://github.com/dhcmrlchtdj/tree-sitter-sqlite but that's in javascript, and I'm not really sure where to start gluing bits and pieces together.

@smacker
Copy link
Owner

smacker commented Jan 10, 2022

Hi @StevenACoffman !

I'm a bit reluctant to merge this grammar into master at this point, but here you can see how to integrate the grammar: #58

Files sqlite/parser.c and sqlite/parser.h are automatically copied from https://github.com/dhcmrlchtdj/tree-sitter-sqlite by running bash vendor.sh download sqlite.
Only a tiny binding.go file is required to be created manually.

You can publish it in your fork or in a separate package and import in your code from there. It doesn't have to be located in smacker/go-tree-sitte.

@metalim
Copy link

metalim commented Aug 23, 2023

so basically all parsers "integrated" into this package are just stolen from other packages, and there's no info on how they were generated? Do I understand this correctly?

Repository owner deleted a comment from Maaajjssj Dec 15, 2023
alexeagle pushed a commit to aspect-build/aspect-cli that referenced this issue May 10, 2024
The go-tree-sitter maintainer doesn't want to checkin every language in the world into that repo
(see smacker/go-tree-sitter#57 (comment)).
So we're going to have to start linking our own languages into go for use in gazelle.

This just moves the languages we're already using, but we'll need more soon.

---

### Changes are visible to end-users: no

### Type of change

- Refactor (a code change that neither fixes a bug or adds a new
feature)

### Test plan

- Covered by existing test cases

---------

Co-authored-by: thesayyn <thesayyn@gmail.com>
GitOrigin-RevId: cf6d1d244bbd38af13f5e42780e7d7f3ccd196a2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants