├── .cargo
└── config.toml
├── .github
├── FUNDING.yml
└── workflows
│ └── main.yml
├── .gitignore
├── .nlsp-settings
└── rust_analyzer.json
├── .pre-commit-config.yaml
├── Cargo.toml
├── LICENSE
├── README.md
├── _prepare_ci.sh
├── _typos.toml
├── build.rs
├── dprint.json
├── examples
├── all_languages.rs
├── custom_languages.rs
├── custom_renderer.rs
├── example_programs.toml
├── themes.rs
└── wasm
│ ├── dioxus
│ ├── .gitignore
│ ├── Cargo.lock
│ ├── Cargo.toml
│ ├── Dioxus.toml
│ ├── LICENSE
│ ├── README.md
│ ├── assets
│ │ └── main.css
│ └── src
│ │ └── main.rs
│ ├── node
│ ├── .gitignore
│ ├── README.md
│ ├── index.js
│ ├── package-lock.json
│ └── package.json
│ ├── vite
│ ├── .gitignore
│ ├── .vscode
│ │ └── extensions.json
│ ├── README.md
│ ├── index.html
│ ├── package-lock.json
│ ├── package.json
│ ├── src
│ │ ├── App.svelte
│ │ ├── app.css
│ │ ├── main.ts
│ │ └── vite-env.d.ts
│ ├── svelte.config.js
│ ├── tsconfig.json
│ ├── tsconfig.node.json
│ └── vite.config.ts
│ └── wasm-pack
│ ├── .gitignore
│ ├── .vscode
│ └── extensions.json
│ ├── Cargo.toml
│ ├── README.md
│ ├── index.html
│ ├── package-lock.json
│ ├── package.json
│ ├── src
│ ├── app.css
│ ├── lib.rs
│ ├── main.ts
│ └── vite-env.d.ts
│ ├── tsconfig.json
│ ├── tsconfig.node.json
│ └── vite.config.ts
├── lua-pattern
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
└── src
│ ├── error.rs
│ ├── lexer.rs
│ ├── lib.rs
│ ├── parser.rs
│ └── to_regex.rs
├── queries
├── asm
│ ├── highlights.scm
│ └── injections.scm
├── bash
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── bibtex
│ ├── highlights.scm
│ └── injections.scm
├── c
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── c_sharp
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── clojure
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── cmake
│ ├── highlights.scm
│ └── injections.scm
├── comment
│ └── highlights.scm
├── cpp
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── css
│ ├── highlights.scm
│ └── injections.scm
├── dart
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── diff
│ ├── highlights.scm
│ └── injections.scm
├── dockerfile
│ ├── highlights.scm
│ └── injections.scm
├── ebnf
│ ├── highlights.scm
│ └── injections.scm
├── ecma
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── ejs
│ ├── highlights.scm
│ └── injections.scm
├── elixir
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── erb
│ ├── highlights.scm
│ └── injections.scm
├── fish
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── gleam
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── go
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── haskell
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── hexdump
│ └── highlights.scm
├── html
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── html_tags
│ ├── highlights.scm
│ └── injections.scm
├── java
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── javascript
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── jsdoc
│ └── highlights.scm
├── json
│ ├── highlights.scm
│ └── locals.scm
├── json5
│ ├── highlights.scm
│ └── injections.scm
├── jsonc
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── jsx
│ ├── highlights.scm
│ └── injections.scm
├── julia
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── kotlin
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── lalrpop
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── latex
│ ├── highlights.scm
│ └── injections.scm
├── llvm
│ ├── highlights.scm
│ └── injections.scm
├── lua
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── luap
│ └── highlights.scm
├── make
│ ├── highlights.scm
│ └── injections.scm
├── markdown
│ ├── highlights.scm
│ └── injections.scm
├── markdown_inline
│ ├── highlights.scm
│ └── injections.scm
├── nix
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── ocaml
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── ocaml_interface
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── php
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── php_only
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── printf
│ └── highlights.scm
├── python
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── ql
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── regex
│ └── highlights.scm
├── ruby
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── rush
│ ├── highlights.scm
│ └── locals.scm
├── rust
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── scala
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── scss
│ ├── highlights.scm
│ └── injections.scm
├── sql
│ ├── highlights.scm
│ └── injections.scm
├── swift
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── toml
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── tsx
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── typescript
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── typst
│ ├── highlights.scm
│ └── injections.scm
├── ursa
│ ├── highlights.scm
│ └── locals.scm
├── verilog
│ ├── highlights.scm
│ └── injections.scm
├── wat
│ └── highlights.scm
├── yaml
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
└── zig
│ ├── highlights.scm
│ ├── injections.scm
│ └── locals.scm
├── rsexpr
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
├── src
│ ├── display.rs
│ ├── error.rs
│ ├── lex.rs
│ ├── lib.rs
│ └── parser.rs
└── tests
│ └── display.rs
├── src
├── lib.rs
├── processor.rs
└── renderer.rs
├── syntastica-core
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
└── src
│ ├── error.rs
│ ├── language_set.rs
│ ├── language_set
│ └── union.rs
│ ├── lib.rs
│ ├── style.rs
│ ├── theme.rs
│ └── theme_keys.rs
├── syntastica-highlight
├── Cargo.toml
├── LICENSE
├── README.md
└── src
│ └── lib.rs
├── syntastica-js
├── .cargo
│ └── config.toml
├── .gitignore
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
├── langs
│ ├── README.md
│ ├── asm
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── bash
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── bibtex
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── c
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── c_sharp
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── clojure
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── cmake
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── comment
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── cpp
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── css
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── dart
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── diff
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── dockerfile
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ebnf
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ejs
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── elixir
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── erb
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── fish
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── gleam
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── go
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── haskell
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── hexdump
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── html
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── java
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── javascript
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── jsdoc
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── json
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── json5
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── jsonc
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── julia
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── kotlin
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── lalrpop
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── latex
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── lua
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── luap
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── make
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── markdown
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── markdown_inline
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── nix
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ocaml
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ocaml_interface
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── php
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── php_only
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── printf
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── python
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ql
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── regex
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ruby
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── rush
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── rust
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── scala
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── scss
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── sql
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── swift
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── toml
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── tsx
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── typescript
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── typst
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── ursa
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── verilog
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── wat
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ ├── yaml
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ │ └── lib.rs
│ └── zig
│ │ ├── Cargo.toml
│ │ ├── LICENSE
│ │ ├── README.md
│ │ ├── build.rs
│ │ ├── package.json
│ │ └── src
│ │ └── lib.rs
├── package-lock.json
├── package.json
├── src
│ ├── index.ts
│ ├── lib.rs
│ ├── main.rs
│ └── syntastica-js.d.ts
├── tsconfig.json
└── typedoc.json
├── syntastica-macros
├── Cargo.toml
├── LICENSE
├── README.md
├── languages.toml
└── src
│ ├── lib.rs
│ └── schema.rs
├── syntastica-parsers-dynamic
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
└── src
│ ├── lib.rs
│ └── loader.rs
├── syntastica-parsers-git
├── .gitignore
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
├── build_helper.rs
└── src
│ └── lib.rs
├── syntastica-parsers-gitdep
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
└── src
│ └── lib.rs
├── syntastica-parsers
├── Cargo.toml
├── LICENSE
├── README.md
├── build.rs
└── src
│ └── lib.rs
├── syntastica-queries
├── Cargo.toml
├── LICENSE
├── README.md
└── src
│ └── lib.rs
├── syntastica-query-preprocessor
├── Cargo.toml
├── LICENSE
├── README.md
└── src
│ └── lib.rs
├── syntastica-themes
├── Cargo.toml
├── LICENSE
├── README.md
├── assets
│ └── theme-svgs
│ │ ├── abscs::abscs.svg
│ │ ├── aurora::aurora.svg
│ │ ├── blue_moon::blue_moon.svg
│ │ ├── boo::boo.svg
│ │ ├── catppuccin::frappe.svg
│ │ ├── catppuccin::latte.svg
│ │ ├── catppuccin::macchiato.svg
│ │ ├── catppuccin::mocha.svg
│ │ ├── darcula::darcula.svg
│ │ ├── dracula::dracula.svg
│ │ ├── everblush::everblush.svg
│ │ ├── everforest::dark.svg
│ │ ├── everforest::light.svg
│ │ ├── falcon::falcon.svg
│ │ ├── github::dark.svg
│ │ ├── github::dark_colorblind.svg
│ │ ├── github::dark_default.svg
│ │ ├── github::dark_dimmed.svg
│ │ ├── github::dark_high_contrast.svg
│ │ ├── github::dark_tritanopia.svg
│ │ ├── github::dimmed.svg
│ │ ├── github::light.svg
│ │ ├── github::light_colorblind.svg
│ │ ├── github::light_default.svg
│ │ ├── github::light_high_contrast.svg
│ │ ├── github::light_tritanopia.svg
│ │ ├── gruvbox::dark.svg
│ │ ├── gruvbox::light.svg
│ │ ├── material::darker.svg
│ │ ├── material::deep_ocean.svg
│ │ ├── material::lighter.svg
│ │ ├── material::oceanic.svg
│ │ ├── material::palenight.svg
│ │ ├── melange::melange.svg
│ │ ├── minimal::minimal.svg
│ │ ├── monochrome::monochrome.svg
│ │ ├── monokai::monokai.svg
│ │ ├── monokai::pro.svg
│ │ ├── monokai::ristretto.svg
│ │ ├── monokai::soda.svg
│ │ ├── moonfly::moonfly.svg
│ │ ├── moonlight::moonlight.svg
│ │ ├── neon::dark.svg
│ │ ├── neon::default.svg
│ │ ├── neon::doom.svg
│ │ ├── neon::light.svg
│ │ ├── nightfly::nightfly.svg
│ │ ├── nord::nord.svg
│ │ ├── oceanicnext::dark.svg
│ │ ├── oceanicnext::light.svg
│ │ ├── omni::omni.svg
│ │ ├── one::cool.svg
│ │ ├── one::dark.svg
│ │ ├── one::darker.svg
│ │ ├── one::deep.svg
│ │ ├── one::light.svg
│ │ ├── one::warm.svg
│ │ ├── one::warmer.svg
│ │ ├── oxocarbon::dark.svg
│ │ ├── oxocarbon::light.svg
│ │ ├── solarized::dark.svg
│ │ ├── solarized::light.svg
│ │ ├── tokyo::day.svg
│ │ ├── tokyo::moon.svg
│ │ ├── tokyo::night.svg
│ │ ├── tokyo::storm.svg
│ │ ├── vscode::dark.svg
│ │ ├── vscode::light.svg
│ │ └── zephyr::zephyr.svg
├── auto_extract.py
├── build.rs
├── nvim_extract.lua
├── src
│ ├── abscs.rs
│ ├── aurora.rs
│ ├── blue_moon.rs
│ ├── boo.rs
│ ├── catppuccin.rs
│ ├── darcula.rs
│ ├── dracula.rs
│ ├── everblush.rs
│ ├── everforest.rs
│ ├── falcon.rs
│ ├── github.rs
│ ├── gruvbox.rs
│ ├── lib.rs
│ ├── melange.rs
│ ├── minimal.rs
│ ├── monochrome.rs
│ ├── monokai.rs
│ ├── moonfly.rs
│ ├── moonlight.rs
│ ├── neon.rs
│ ├── nightfly.rs
│ ├── nord.rs
│ ├── oceanicnext.rs
│ ├── omni.rs
│ ├── one.rs
│ ├── oxocarbon.rs
│ ├── solarized.rs
│ ├── tokyo.rs
│ ├── vscode.rs
│ └── zephyr.rs
└── theme_list.md
├── tests
├── _shared.rs
├── validate_queries.rs
└── validate_queries_crates_io.rs
├── tree-sitter-wasm-build-tool
├── Cargo.toml
├── LICENSE
├── README.md
├── src
│ └── lib.rs
└── wasm-sysroot
│ ├── stdbool.h
│ ├── stdint.h
│ ├── stdio.h
│ ├── stdlib.h
│ ├── wctype.c
│ └── wctype.h
└── xtask
├── Cargo.toml
└── src
├── add_lang.rs
├── build_js_langs.rs
├── codegen.rs
├── codegen
├── generated_queries_readme.md
├── js_langs_readme.md
├── js_lists.rs
├── js_pkgs.rs
├── parser_lists.rs
├── parsers_dep.rs
├── parsers_git.rs
├── parsers_gitdep.rs
├── queries.rs
└── theme_list.rs
├── fetch_queries.rs
├── main.rs
├── set_version.rs
├── theme_svgs.rs
├── update_langs.rs
└── update_vite_example.rs
/.cargo/config.toml:
--------------------------------------------------------------------------------
1 | [alias]
2 | xtask = "run --package xtask --"
3 | make = "xtask"
4 | x = "xtask"
5 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | ko_fi: rubixdev
2 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | /target
2 | /Cargo.lock
3 | /ignored/
4 | /syntastica-js/pkg/
5 | /syntastica-queries/generated_queries/
6 |
--------------------------------------------------------------------------------
/.nlsp-settings/rust_analyzer.json:
--------------------------------------------------------------------------------
1 | {
2 | "rust-analyzer.cargo.features": "all"
3 | }
4 |
--------------------------------------------------------------------------------
/.pre-commit-config.yaml:
--------------------------------------------------------------------------------
1 | # See https://pre-commit.com for more information
2 | # See https://pre-commit.com/hooks.html for more hooks
3 | repos:
4 | - repo: https://github.com/pre-commit/pre-commit-hooks
5 | rev: v4.4.0
6 | hooks:
7 | - id: trailing-whitespace
8 | - id: end-of-file-fixer
9 | - id: check-yaml
10 | - id: check-toml
11 | - id: check-added-large-files
12 | - repo: https://github.com/doublify/pre-commit-rust
13 | rev: v1.0
14 | hooks:
15 | - id: clippy
16 | - repo: https://github.com/RubixDev/pre-commit-dprint
17 | rev: v0.40.2
18 | hooks:
19 | - id: dprint
20 | pass_filenames: false
21 | - repo: https://github.com/crate-ci/typos
22 | rev: typos-dict-v0.10.8
23 | hooks:
24 | - id: typos
25 |
--------------------------------------------------------------------------------
/_prepare_ci.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | file="./syntastica-parsers-gitdep/Cargo.toml"
4 | raw="$(cat "$file")"
5 | header="
6 | ###########################################
7 | ### All following code is autogenerated ###
8 | ### by running \`cargo xtask codegen\` in ###
9 | ### the syntastica workspace. #############
10 | ###########################################
11 | "
12 | echo -n "${raw//"$header"*/"$header"}" > "$file"
13 |
--------------------------------------------------------------------------------
/_typos.toml:
--------------------------------------------------------------------------------
1 | [default.extend-identifiers]
2 | darcula = "darcula"
3 | ake = "ake"
4 | nam = "nam"
5 |
--------------------------------------------------------------------------------
/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/examples/wasm/dioxus/.gitignore:
--------------------------------------------------------------------------------
1 | # Generated by Cargo
2 | # will have compiled files and executables
3 | /target
4 | .DS_Store
5 |
6 | # These are backup files generated by rustfmt
7 | **/*.rs.bk
8 |
--------------------------------------------------------------------------------
/examples/wasm/dioxus/Dioxus.toml:
--------------------------------------------------------------------------------
1 | [application]
2 | # App (Project) Name
3 | name = "syntastica-dioxus-demo"
4 |
5 | [web.app]
6 | # HTML title tag content
7 | title = "syntastica + Dioxus demo"
8 |
9 | # include `assets` in web platform
10 | [web.resource]
11 | # Additional CSS style files
12 | style = []
13 |
14 | # Additional JavaScript files
15 | script = []
16 |
17 | [web.resource.dev]
18 | # Javascript code file
19 | # serve: [dev-server] only
20 | script = []
21 |
--------------------------------------------------------------------------------
/examples/wasm/dioxus/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica` Dioxus Example
2 |
3 | This folder contains an example project showcasing use of `syntastica` with
4 | [`Dioxus`](https://dioxuslabs.com/).
5 |
6 | The demo can be found online
7 | [here](https://rubixdev.github.io/syntastica/demos/dioxus/).
8 |
9 | When targeting `wasm32-unknown-unknown` as required by wasm-pack/wasm-bindgen
10 | (which is used by dioxus), the `syntastica-parsers-git` collection must be used.
11 |
12 | You can run a development server locally using the Dioxus CLI by executing this
13 | command:
14 |
15 | ```bash
16 | dx serve
17 | ```
18 |
19 | ## Notes
20 |
21 | The main thing to look out for when targeting `wasm32-unknown-unknown` is using
22 | the `c2rust` tree-sitter runtime. To do this you must set
23 | `default-features = false` and enable the `runtime-c2rust` feature for all
24 | `syntastica` dependencies. It is also recommended to only enable the parsers
25 | that you actually need in order to keep the binary size small.
26 |
--------------------------------------------------------------------------------
/examples/wasm/dioxus/assets/main.css:
--------------------------------------------------------------------------------
1 | :root {
2 | color-scheme: dark;
3 | font-family: sans-serif;
4 | }
5 |
6 | body {
7 | background-color: #282c34;
8 | padding: 1rem;
9 | }
10 |
11 | .code {
12 | font-family: monospace;
13 | }
14 |
--------------------------------------------------------------------------------
/examples/wasm/node/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 |
--------------------------------------------------------------------------------
/examples/wasm/node/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica` NodeJS Example
2 |
3 | This folder contains an example project showcasing use of `syntastica` in NodeJS
4 | for terminal applications.
5 |
6 | You can run it locally by executing these commands:
7 |
8 | ```bash
9 | npm i
10 | node .
11 | ```
12 |
--------------------------------------------------------------------------------
/examples/wasm/node/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "syntastica-node-example",
3 | "private": true,
4 | "version": "0.0.0",
5 | "main": "index.js",
6 | "author": "RubixDev",
7 | "type": "module",
8 | "scripts": {},
9 | "dependencies": {
10 | "@syntastica/core": "^0.5.1",
11 | "@syntastica/lang-javascript": "^0.5.0",
12 | "@syntastica/lang-rust": "^0.5.0"
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/examples/wasm/vite/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/examples/wasm/vite/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["svelte.svelte-vscode"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/wasm/vite/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica` Vite + Svelte + TypeScript Example
2 |
3 | This folder contains an example project showcasing use of `syntastica` in
4 | websites using Vite, Svelte, and TypeScript.
5 |
6 | The demo can be found online
7 | [here](https://rubixdev.github.io/syntastica/demos/vite/).
8 |
9 | You can run a development server locally by executing these commands:
10 |
11 | ```bash
12 | npm i
13 | npm run dev
14 | ```
15 |
16 | ## Notes
17 |
18 | By default, `syntastica` fails to load its WebAssembly file correctly when
19 | running Vite's development server. To work around that, we can manually specify
20 | the URL to the Wasm file when initializing `syntastica` and make use of Vite's
21 | `?url` imports to get the correct URL. See [`App.svelte`](./src/App.svelte) for
22 | more info.
23 |
--------------------------------------------------------------------------------
/examples/wasm/vite/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | syntastica Demo
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/examples/wasm/vite/src/app.css:
--------------------------------------------------------------------------------
1 | :root {
2 | color-scheme: dark;
3 | font-family: sans-serif;
4 | }
5 |
6 | body {
7 | background-color: #282c34;
8 | margin: 1rem;
9 | }
10 |
--------------------------------------------------------------------------------
/examples/wasm/vite/src/main.ts:
--------------------------------------------------------------------------------
1 | import './app.css'
2 | import App from './App.svelte'
3 |
4 | const app = new App({
5 | target: document.body,
6 | })
7 |
8 | export default app
9 |
--------------------------------------------------------------------------------
/examples/wasm/vite/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 | ///
3 |
--------------------------------------------------------------------------------
/examples/wasm/vite/svelte.config.js:
--------------------------------------------------------------------------------
1 | import { vitePreprocess } from '@sveltejs/vite-plugin-svelte'
2 |
3 | export default {
4 | // Consult https://svelte.dev/docs#compile-time-svelte-preprocess
5 | // for more information about preprocessors
6 | preprocess: vitePreprocess(),
7 | }
8 |
--------------------------------------------------------------------------------
/examples/wasm/vite/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/svelte/tsconfig.json",
3 | "compilerOptions": {
4 | "target": "ESNext",
5 | "useDefineForClassFields": true,
6 | "module": "ESNext",
7 | "resolveJsonModule": true,
8 | /**
9 | * Typecheck JS in `.svelte` and `.js` files by default.
10 | * Disable checkJs if you'd like to use dynamic types in JS.
11 | * Note that setting allowJs false does not prevent the use
12 | * of JS in `.svelte` files.
13 | */
14 | "allowJs": true,
15 | "checkJs": true,
16 | "isolatedModules": true
17 | },
18 | "include": ["src/**/*.d.ts", "src/**/*.ts", "src/**/*.js", "src/**/*.svelte"],
19 | "references": [{ "path": "./tsconfig.node.json" }]
20 | }
21 |
--------------------------------------------------------------------------------
/examples/wasm/vite/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "composite": true,
4 | "skipLibCheck": true,
5 | "module": "ESNext",
6 | "moduleResolution": "bundler"
7 | },
8 | "include": ["vite.config.ts"]
9 | }
10 |
--------------------------------------------------------------------------------
/examples/wasm/vite/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { svelte } from '@sveltejs/vite-plugin-svelte'
2 | import { defineConfig } from 'vite'
3 |
4 | // https://vitejs.dev/config/
5 | export default defineConfig({
6 | plugins: [svelte()],
7 | })
8 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
26 | # Rust
27 | /target
28 | **/*.rs.bk
29 | Cargo.lock
30 | bin/
31 | pkg/
32 | wasm-pack.log
33 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["svelte.svelte-vscode"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/Cargo.toml:
--------------------------------------------------------------------------------
1 | [workspace]
2 |
3 | [package]
4 | name = "syntastica-wasm-pack"
5 | version = "0.1.0"
6 | authors = ["RubixDev "]
7 | edition = "2021"
8 |
9 | [lib]
10 | crate-type = ["cdylib", "rlib"]
11 |
12 | [dependencies]
13 | syntastica = { version = "0.6.0", path = "../../..", default-features = false, features = ["runtime-c2rust"] }
14 | syntastica-parsers-git = { version = "0.6.0", path = "../../../syntastica-parsers-git", default-features = false, features = ["runtime-c2rust", "rust"] }
15 | syntastica-themes = { version = "0.6.0", path = "../../../syntastica-themes", default-features = false, features = ["runtime-c2rust"] }
16 |
17 | js-sys = "0.3.77"
18 | wasm-bindgen = "0.2.100"
19 | wasm-bindgen-futures = "0.4.50"
20 | web-sys = { version = "0.3.77", features = ["console", "Document", "Element", "HtmlElement", "Node", "Window"] }
21 |
22 | [profile.release]
23 | # Tell `rustc` to optimize for small code size.
24 | opt-level = "s"
25 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica` wasm-pack Example
2 |
3 | This folder contains an example project showcasing use of `syntastica` in
4 | websites using `wasm-bindgen` and `wasm-pack`.
5 |
6 | The demo can be found online
7 | [here](https://rubixdev.github.io/syntastica/demos/wasm-pack/).
8 |
9 | You can run a development server locally by executing these commands:
10 |
11 | ```bash
12 | wasm-pack build --target web .
13 | npm i
14 | npm run dev
15 | ```
16 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | syntastica wasm-pack
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "syntastica-wasm-pack",
3 | "private": true,
4 | "version": "0.0.0",
5 | "type": "module",
6 | "scripts": {
7 | "dev": "vite",
8 | "build": "vite build",
9 | "preview": "vite preview"
10 | },
11 | "devDependencies": {
12 | "tslib": "^2.8.1",
13 | "typescript": "^5.8.2",
14 | "vite": "^4.5.9"
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/src/app.css:
--------------------------------------------------------------------------------
1 | :root {
2 | color-scheme: dark;
3 | font-family: sans-serif;
4 | }
5 |
6 | body {
7 | background-color: #282c34;
8 | padding: 1rem;
9 | }
10 |
11 | .code {
12 | font-family: monospace;
13 | }
14 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/src/main.ts:
--------------------------------------------------------------------------------
1 | import './app.css'
2 | import init from '../pkg/syntastica_wasm_pack'
3 |
4 | init()
5 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ESNext",
4 | "useDefineForClassFields": true,
5 | "module": "ESNext",
6 | "resolveJsonModule": true,
7 | "allowJs": true,
8 | "checkJs": true,
9 | "isolatedModules": true
10 | },
11 | "include": ["src/**/*.d.ts", "src/**/*.ts", "src/**/*.js"],
12 | "references": [{ "path": "./tsconfig.node.json" }]
13 | }
14 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "composite": true,
4 | "skipLibCheck": true,
5 | "module": "ESNext",
6 | "moduleResolution": "bundler"
7 | },
8 | "include": ["vite.config.ts"]
9 | }
10 |
--------------------------------------------------------------------------------
/examples/wasm/wasm-pack/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'vite'
2 |
3 | // https://vitejs.dev/config/
4 | export default defineConfig({})
5 |
--------------------------------------------------------------------------------
/lua-pattern/README.md:
--------------------------------------------------------------------------------
1 | # `lua-pattern`
2 |
3 | Parser for Lua patterns and conversion to regular expressions.
4 |
5 | This crate provides a basic parser for Lua patterns, and, with the `to-regex`
6 | feature enabled, conversion to standard regular expressions as usable by the
7 | [`regex`](https://crates.io/crates/regex) or
8 | [`fancy-regex`](https://crates.io/crates/fancy-regex) crate.
9 |
--------------------------------------------------------------------------------
/lua-pattern/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/queries/asm/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/asm/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | [
5 | (line_comment)
6 | (block_comment)
7 | ] @injection.content
8 | (#set! injection.language "comment")
9 | )
10 |
--------------------------------------------------------------------------------
/queries/bash/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/helix-editor/helix/blob/master/runtime/queries/bash/injections.scm
2 | ;; Licensed under the Mozilla Public License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (command
9 | name: (command_name
10 | (word) @_command
11 | )
12 | argument: (raw_string) @injection.content
13 | (#match? @_command "^[gnm]?awk$")
14 | (#set! injection.language "awk")
15 | )
16 |
17 | (
18 | (regex) @injection.content
19 | (#set! injection.language "regex")
20 | )
21 |
--------------------------------------------------------------------------------
/queries/bash/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/bash/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; Scopes
4 | (function_definition) @local.scope
5 |
6 | ; Definitions
7 | (variable_assignment
8 | name: (variable_name) @local.definition.var
9 | )
10 |
11 | (function_definition
12 | name: (word) @local.definition.function
13 | )
14 |
15 | ; References
16 | (variable_name) @local.reference
17 |
18 | (word) @local.reference
19 |
--------------------------------------------------------------------------------
/queries/bibtex/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/bibtex/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (junk) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/c_sharp/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/c_sharp/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/clojure/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/clojure/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/clojure/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/clojure/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; placeholder file to get incremental selection to work
4 |
--------------------------------------------------------------------------------
/queries/cmake/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/cmake/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | [
5 | (bracket_comment)
6 | (line_comment)
7 | ] @injection.content
8 | (#set! injection.language "comment")
9 | )
10 |
--------------------------------------------------------------------------------
/queries/cpp/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/cpp/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (preproc_arg) @injection.content
5 | (#set! injection.language "cpp")
6 | )
7 |
8 | (
9 | (comment) @injection.content
10 | (#set! injection.language "comment")
11 | )
12 |
13 | (
14 | (comment) @injection.content
15 | (#lua-match? @injection.content "/[*/][!*/][^a-zA-Z]")
16 | (#set! injection.language "doxygen")
17 | )
18 |
19 | (raw_string_literal
20 | delimiter: (raw_string_delimiter) @injection.language
21 | (raw_string_content) @injection.content
22 | )
23 |
--------------------------------------------------------------------------------
/queries/css/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/css/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/dart/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/dart/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/dart/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/dart/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; Definitions
4 | (function_signature
5 | name: (identifier) @local.definition.function
6 | )
7 |
8 | (formal_parameter
9 | name: (identifier) @local.definition.parameter
10 | )
11 |
12 | (initialized_variable_definition
13 | name: (identifier) @local.definition.var
14 | )
15 |
16 | (initialized_identifier
17 | (identifier) @local.definition.var
18 | )
19 |
20 | (static_final_declaration
21 | (identifier) @local.definition.var
22 | )
23 |
24 | ; References
25 | (identifier) @local.reference
26 |
27 | ; Scopes
28 | (class_definition
29 | body: (_) @local.scope
30 | )
31 |
32 | [
33 | (block)
34 | (if_statement)
35 | (for_statement)
36 | (while_statement)
37 | (try_statement)
38 | (catch_clause)
39 | (finally_clause)
40 | ] @local.scope
41 |
--------------------------------------------------------------------------------
/queries/diff/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/diff/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | (comment) @comment
4 |
5 | [
6 | (addition)
7 | (new_file)
8 | ] @diff.plus
9 |
10 | [
11 | (deletion)
12 | (old_file)
13 | ] @diff.minus
14 |
15 | (commit) @constant
16 |
17 | (location) @attribute
18 |
19 | (command
20 | "diff" @function
21 | (argument) @variable.parameter
22 | )
23 |
24 | (filename) @string.special.path
25 |
26 | (mode) @number
27 |
28 | (
29 | [
30 | ".."
31 | "+"
32 | "++"
33 | "+++"
34 | "++++"
35 | "-"
36 | "--"
37 | "---"
38 | "----"
39 | ] @punctuation.special
40 | (#set! priority 95)
41 | )
42 |
43 | [
44 | (binary_change)
45 | (similarity)
46 | (file_change)
47 | ] @label
48 |
49 | (index
50 | "index" @keyword
51 | )
52 |
53 | (similarity
54 | (score) @number
55 | "%" @number
56 | )
57 |
--------------------------------------------------------------------------------
/queries/diff/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/diff/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/dockerfile/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/dockerfile/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (
9 | (shell_command
10 | (shell_fragment) @injection.content
11 | )
12 | (#set! injection.language "bash")
13 | )
14 |
15 | (
16 | (run_instruction
17 | (heredoc_block) @injection.content
18 | )
19 | (#set! injection.language "bash")
20 | (#set! injection.include-children)
21 | )
22 |
--------------------------------------------------------------------------------
/queries/ebnf/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ebnf/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; Simple tokens ;;;;
4 | (terminal) @string
5 |
6 | (special_sequence) @string.special
7 |
8 | (integer) @number
9 |
10 | (comment) @comment
11 |
12 | ; Identifiers ;;;;
13 | ; Allow different highlighting for specific casings
14 | (
15 | (identifier) @type
16 | (#lua-match? @type "^%u")
17 | )
18 |
19 | (
20 | (identifier) @string.special.symbol
21 | (#lua-match? @string.special.symbol "^%l")
22 | )
23 |
24 | (
25 | (identifier) @constant
26 | (#lua-match? @constant "^%u[%u%d_]+$")
27 | )
28 |
29 | ; Punctuation ;;;;
30 | [
31 | ";"
32 | ","
33 | ] @punctuation.delimiter
34 |
35 | [
36 | "|"
37 | "*"
38 | "-"
39 | ] @operator
40 |
41 | "=" @keyword.operator
42 |
43 | [
44 | "("
45 | ")"
46 | "["
47 | "]"
48 | "{"
49 | "}"
50 | ] @punctuation.bracket
51 |
--------------------------------------------------------------------------------
/queries/ebnf/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ebnf/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/ejs/highlights.scm:
--------------------------------------------------------------------------------
1 | ; inherits erb
2 |
--------------------------------------------------------------------------------
/queries/ejs/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/embedded_template/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (content) @injection.content
5 | (#set! injection.language "html")
6 | (#set! injection.combined)
7 | )
8 |
9 | (comment) @comment
10 |
11 | (directive
12 | (code) @javascript @combined
13 | )
14 |
15 | (output_directive
16 | (code) @javascript @combined
17 | )
18 |
19 | (
20 | (code) @injection.content
21 | (#set! injection.language "javascript")
22 | (#set! injection.combined)
23 | )
24 |
--------------------------------------------------------------------------------
/queries/erb/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/embedded_template/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | (comment_directive) @comment
4 |
5 | [
6 | "<%#"
7 | "<%"
8 | "<%_"
9 | "<%|"
10 | "<%="
11 | "<%=="
12 | "<%|="
13 | "<%|=="
14 | "<%_"
15 | "<%-"
16 | "<%#"
17 | "<%graphql"
18 | "%>"
19 | "-%>"
20 | "_%>"
21 | "=%>"
22 | ] @keyword
23 |
--------------------------------------------------------------------------------
/queries/erb/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/embedded_template/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (content) @injection.content
5 | (#set! injection.language "html")
6 | (#set! injection.combined)
7 | )
8 |
9 | (comment) @comment
10 |
11 | (directive
12 | (code) @ruby @combined
13 | )
14 |
15 | (output_directive
16 | (code) @ruby @combined
17 | )
18 |
19 | (
20 | (code) @injection.content
21 | (#set! injection.language "ruby")
22 | (#set! injection.combined)
23 | )
24 |
--------------------------------------------------------------------------------
/queries/fish/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/fish/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/fish/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/fish/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; Scopes
4 | [
5 | (command)
6 | (function_definition)
7 | (if_statement)
8 | (for_statement)
9 | (begin_statement)
10 | (while_statement)
11 | (switch_statement)
12 | ] @local.scope
13 |
14 | ; Definitions
15 | (function_definition
16 | name: (word) @local.definition.function
17 | )
18 |
19 | ; References
20 | (variable_name) @local.reference
21 |
22 | (word) @local.reference
23 |
--------------------------------------------------------------------------------
/queries/gleam/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/gleam/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; Comments
4 | (
5 | [
6 | (module_comment)
7 | (statement_comment)
8 | (comment)
9 | ] @injection.content
10 | (#set! injection.language "comment")
11 | )
12 |
--------------------------------------------------------------------------------
/queries/gleam/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/gleam/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; Let Binding Definition
4 | (let
5 | pattern: (identifier) @local.definition
6 | )
7 |
8 | ; List Pattern Definitions
9 | (list_pattern
10 | (identifier) @local.definition
11 | )
12 |
13 | (list_pattern
14 | assign: (identifier) @local.definition
15 | )
16 |
17 | ; Tuple Pattern Definition
18 | (tuple_pattern
19 | (identifier) @local.definition
20 | )
21 |
22 | ; Record Pattern Definition
23 | (record_pattern_argument
24 | pattern: (identifier) @local.definition
25 | )
26 |
27 | ; Function Parameter Definition
28 | (function_parameter
29 | name: (identifier) @local.definition
30 | )
31 |
32 | ; References
33 | (identifier) @local.reference
34 |
35 | ; Block Scope
36 | (block) @local.scope
37 |
38 | ; Case Scope
39 | (case_clause) @local.scope
40 |
--------------------------------------------------------------------------------
/queries/haskell/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/haskell/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | (signature
4 | name: (variable)
5 | ) @local.definition
6 |
7 | (function
8 | name: (variable)
9 | ) @local.definition
10 |
11 | (pattern/variable) @local.definition
12 |
13 | (expression/variable) @local.reference
14 |
--------------------------------------------------------------------------------
/queries/hexdump/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/rush-rs/tree-sitter-hexdump/blob/main/queries/hexdump/highlights.scm
2 | ;; Licensed under the MIT license
3 | (line_comment) @comment
4 |
5 | (int) @number
6 |
7 | (string) @string
8 |
9 | ":" @punctuation.delimiter
10 |
--------------------------------------------------------------------------------
/queries/html/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/html/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: html_tags
4 | (doctype) @constant
5 |
6 | "
4 | (jsx_element
5 | (jsx_opening_element
6 | (identifier) @_name
7 | (#eq? @_name "style")
8 | (jsx_attribute) @_attr
9 | (#eq? @_attr "jsx")
10 | )
11 | (jsx_expression
12 | (
13 | (template_string) @injection.content
14 | (#set! injection.language "css")
15 | )
16 | (#offset! @injection.content 0 1 0 -1)
17 | )
18 | )
19 |
--------------------------------------------------------------------------------
/queries/lalrpop/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/lalrpop/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (
9 | [
10 | (normal_action)
11 | (failible_action)
12 | ] @injection.content
13 | (#set! injection.language "rust")
14 | )
15 |
16 | (
17 | (use) @injection.content
18 | (#set! injection.language "rust")
19 | )
20 |
21 | (
22 | (regex_literal) @injection.content
23 | (#set! injection.language "regex")
24 | (#offset! @injection.content 0 2 0 -1)
25 | )
26 |
--------------------------------------------------------------------------------
/queries/lalrpop/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/lalrpop/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | (nonterminal_name
4 | (macro_id) @local.definition.function
5 | )
6 |
7 | (nonterminal_name
8 | (identifier) @local.definition.function
9 | )
10 |
--------------------------------------------------------------------------------
/queries/llvm/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/llvm/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/make/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/make/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (
9 | (shell_text) @injection.content
10 | (#set! injection.language "bash")
11 | )
12 |
13 | (
14 | (shell_command) @injection.content
15 | (#set! injection.language "bash")
16 | )
17 |
--------------------------------------------------------------------------------
/queries/markdown_inline/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/markdown_inline/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (html_tag) @injection.content
5 | (#set! injection.language "html")
6 | (#set! injection.combined)
7 | )
8 |
9 | (
10 | (latex_block) @injection.content
11 | (#set! injection.language "latex")
12 | (#set! injection.include-children)
13 | )
14 |
--------------------------------------------------------------------------------
/queries/ocaml/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ocaml/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/ocaml_interface/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ocaml_interface/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: ocaml
4 |
--------------------------------------------------------------------------------
/queries/ocaml_interface/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ocaml_interface/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: ocaml
4 |
--------------------------------------------------------------------------------
/queries/php/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/php/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: php_only
4 |
--------------------------------------------------------------------------------
/queries/php/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/php/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: php_only
4 | (
5 | (text) @injection.content
6 | (#set! injection.language "html")
7 | (#set! injection.combined)
8 | )
9 |
--------------------------------------------------------------------------------
/queries/php/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/php/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: php_only
4 |
--------------------------------------------------------------------------------
/queries/printf/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/printf/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | (format) @character
4 |
--------------------------------------------------------------------------------
/queries/python/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/python/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (call
4 | function: (attribute
5 | object: (identifier) @_re
6 | )
7 | arguments: (argument_list
8 | .
9 | (string
10 | (string_content) @injection.content
11 | )
12 | )
13 | (#eq? @_re "re")
14 | (#set! injection.language "regex")
15 | )
16 |
17 | (
18 | (binary_operator
19 | left: (string
20 | (string_content) @injection.content
21 | )
22 | operator:
23 | "%"
24 | )
25 | (#set! injection.language "printf")
26 | )
27 |
28 | (
29 | (comment) @injection.content
30 | (#set! injection.language "comment")
31 | )
32 |
--------------------------------------------------------------------------------
/queries/ql/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ql/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | [
5 | (line_comment)
6 | (block_comment)
7 | (qldoc)
8 | ] @injection.content
9 | (#set! injection.language "comment")
10 | )
11 |
--------------------------------------------------------------------------------
/queries/ruby/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/ruby/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (heredoc_body
9 | (heredoc_content) @injection.content
10 | (heredoc_end) @injection.language
11 | )
12 |
13 | (regex
14 | (string_content) @injection.content
15 | (#set! injection.language "regex")
16 | )
17 |
18 | (
19 | (call
20 | receiver: (identifier) @_receiver
21 | method: (identifier) @_method
22 | arguments: (argument_list
23 | (pair
24 | key: (hash_key_symbol)
25 | value: (string
26 | (string_content) @injection.content
27 | )
28 | )
29 | )
30 | )
31 | (#eq? @_receiver "binding")
32 | (#any-of? @_method "b" "break")
33 | (#set! injection.self)
34 | )
35 |
--------------------------------------------------------------------------------
/queries/rush/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/rush-rs/tree-sitter-rush/blob/main/queries/rush/locals.scm
2 | ;; Licensed under the MIT license
3 | (block) @local.scope
4 |
5 | ; Functions
6 | (function_definition
7 | name: (ident) @local.definition.function
8 | )
9 |
10 | (parameter
11 | name: (ident) @local.definition.parameter
12 | )
13 |
14 | ; Variables
15 | (let_stmt
16 | name: (ident) @local.definition.var
17 | )
18 |
19 | (for_stmt
20 | name: (ident) @local.definition.var
21 | )
22 |
23 | ; References
24 | (ident) @local.reference
25 |
--------------------------------------------------------------------------------
/queries/scala/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/scala/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (
9 | (block_comment) @injection.content
10 | (#set! injection.language "comment")
11 | )
12 |
--------------------------------------------------------------------------------
/queries/scss/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/scss/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (single_line_comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/sql/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/sql/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (
9 | (marginalia) @injection.content
10 | (#set! injection.language "comment")
11 | )
12 |
--------------------------------------------------------------------------------
/queries/swift/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/swift/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | [
5 | (comment)
6 | (multiline_comment)
7 | ] @injection.content
8 | (#set! injection.language "comment")
9 | )
10 |
--------------------------------------------------------------------------------
/queries/swift/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/swift/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | (import_declaration
4 | (identifier) @local.definition.import
5 | )
6 |
7 | (function_declaration
8 | name: (simple_identifier) @local.definition.function
9 | )
10 |
11 | ; Scopes
12 | [
13 | (statements)
14 | (for_statement)
15 | (while_statement)
16 | (repeat_while_statement)
17 | (do_statement)
18 | (if_statement)
19 | (guard_statement)
20 | (switch_statement)
21 | (property_declaration)
22 | (function_declaration)
23 | (class_declaration)
24 | (protocol_declaration)
25 | ] @local.scope
26 |
--------------------------------------------------------------------------------
/queries/toml/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/toml/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | (bare_key) @property
4 |
5 | [
6 | (string)
7 | (quoted_key)
8 | ] @string
9 |
10 | (boolean) @boolean
11 |
12 | (comment) @comment
13 |
14 | (escape_sequence) @string.escape
15 |
16 | (integer) @number
17 |
18 | (float) @number.float
19 |
20 | [
21 | (local_date)
22 | (local_date_time)
23 | (local_time)
24 | (offset_date_time)
25 | ] @string.special
26 |
27 | "=" @operator
28 |
29 | [
30 | "."
31 | ","
32 | ] @punctuation.delimiter
33 |
34 | [
35 | "["
36 | "]"
37 | "[["
38 | "]]"
39 | "{"
40 | "}"
41 | ] @punctuation.bracket
42 |
--------------------------------------------------------------------------------
/queries/toml/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/toml/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
--------------------------------------------------------------------------------
/queries/toml/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/toml/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | [
4 | (table)
5 | (table_array_element)
6 | ] @local.scope
7 |
--------------------------------------------------------------------------------
/queries/tsx/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/tsx/highlights.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: typescript,jsx
4 |
--------------------------------------------------------------------------------
/queries/tsx/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/tsx/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: ecma,jsx
4 |
--------------------------------------------------------------------------------
/queries/tsx/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/tsx/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: typescript
4 |
--------------------------------------------------------------------------------
/queries/typescript/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/typescript/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | ; inherits: ecma
4 |
--------------------------------------------------------------------------------
/queries/typst/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/typst/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (raw_blck
9 | (ident) @injection.language
10 | (blob) @injection.content
11 | )
12 |
--------------------------------------------------------------------------------
/queries/ursa/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/ursalang/tree-sitter-ursa/blob/main/queries/locals.scm
2 | ;; Licensed under the ISC licence
3 | ; Scopes
4 | ;-------
5 | [
6 | (block)
7 | (fn)
8 | ] @local.scope
9 |
10 | ; Definitions
11 | ;------------
12 | (let
13 | identifier: (identifier) @local.definition
14 | )
15 |
16 | (for
17 | identifier: (identifier) @local.definition
18 | )
19 |
20 | ; References
21 | ;------------
22 | (identifier) @local.reference
23 |
--------------------------------------------------------------------------------
/queries/verilog/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/verilog/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (
9 | (macro_text) @injection.content
10 | (#set! injection.language "verilog")
11 | )
12 |
--------------------------------------------------------------------------------
/queries/wat/highlights.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/rush-rs/tree-sitter-wasm-queries/blob/main/queries/wat/highlights.scm
2 | ;; Licensed under the MIT license
3 | [
4 | (int)
5 | (nat)
6 | ] @number
7 |
8 | (float) @number.float
9 |
10 | (identifier) @string.special.symbol
11 |
12 | (string) @string
13 |
14 | (escape_sequence) @string.escape
15 |
16 | [
17 | (comment_line)
18 | (comment_block)
19 | ] @comment
20 |
21 | (value_type) @type.builtin
22 |
23 | (instr_plain) @function.call
24 |
25 | [
26 | "module"
27 | "func"
28 | "type"
29 | "export"
30 | "import"
31 | "param"
32 | "result"
33 | "mut"
34 | "local"
35 | "if"
36 | "else"
37 | "end"
38 | "block"
39 | "loop"
40 | "memory"
41 | "global"
42 | "start"
43 | ] @keyword
44 |
45 | [
46 | "("
47 | ")"
48 | ] @punctuation.bracket
49 |
--------------------------------------------------------------------------------
/queries/yaml/locals.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/yaml/locals.scm
2 | ;; Licensed under the Apache License 2.0
3 | [
4 | (stream)
5 | (document)
6 | (block_node)
7 | ] @local.scope
8 |
9 | (anchor_name) @local.definition
10 |
11 | (alias_name) @local.reference
12 |
--------------------------------------------------------------------------------
/queries/zig/injections.scm:
--------------------------------------------------------------------------------
1 | ;; Forked from https://github.com/nvim-treesitter/nvim-treesitter/blob/master/queries/zig/injections.scm
2 | ;; Licensed under the Apache License 2.0
3 | (
4 | (comment) @injection.content
5 | (#set! injection.language "comment")
6 | )
7 |
8 | (asm_output_item
9 | (string) @injection.content
10 | (#set! injection.language "asm")
11 | )
12 |
13 | (asm_input_item
14 | (string) @injection.content
15 | (#set! injection.language "asm")
16 | )
17 |
18 | (asm_clobbers
19 | (string) @injection.content
20 | (#set! injection.language "asm")
21 | )
22 |
--------------------------------------------------------------------------------
/rsexpr/README.md:
--------------------------------------------------------------------------------
1 | # `rsexpr`
2 |
3 | Small and simple S-expression parsing and manipulation with support for
4 | square-bracketed groups and strings. Used by
5 | [`syntastica`](https://crates.io/crates/syntastica) for processing tree-sitter
6 | queries.
7 |
--------------------------------------------------------------------------------
/rsexpr/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/rsexpr/src/error.rs:
--------------------------------------------------------------------------------
1 | use thiserror::Error;
2 |
3 | use crate::ParenKind;
4 |
5 | /// The default result type. The error variant is a vector of [`Error`](enum@Error)s
6 | pub type Result = std::result::Result>;
7 |
8 | /// The crate error type.
9 | #[derive(Debug, Error, PartialEq, Eq)]
10 | pub enum Error {
11 | /// The input is missing a closing parenthesis
12 | #[error("missing closing parenthesis `{0}`")]
13 | MissingClosingParen(ParenKind),
14 |
15 | /// The input has an unexpected extra closing parenthesis
16 | #[error("extra closing parenthesis `{0}`")]
17 | ExtraClosingParen(ParenKind),
18 |
19 | /// The input contains no S-expression
20 | #[error("input contains no S-expression")]
21 | EmptyInput,
22 |
23 | /// The input contains more than one S-expression
24 | #[error("input contains more than one S-expression")]
25 | ExtraSexprs,
26 | }
27 |
--------------------------------------------------------------------------------
/syntastica-core/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-core`
2 |
3 | Shared types and traits used by other
4 | [`syntastica`](https://crates.io/crates/syntastica) crates.
5 |
6 | See
7 | [the project overview](https://rubixdev.github.io/syntastica/syntastica/#crates-for-internal-use)
8 | for more information.
9 |
--------------------------------------------------------------------------------
/syntastica-core/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/syntastica-core/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![doc = include_str!("../README.md")]
2 | #![cfg_attr(
3 | feature = "docs",
4 | cfg_attr(doc, doc = ::document_features::document_features!(feature_label = r#"{feature}
"#))
5 | )]
6 | #![cfg_attr(all(doc, CHANNEL_NIGHTLY), feature(doc_auto_cfg))]
7 | #![warn(rust_2018_idioms, unreachable_pub)]
8 | #![deny(missing_docs)]
9 |
10 | #[cfg(all(not(feature = "runtime-c"), not(feature = "runtime-c2rust")))]
11 | compile_error!("Either `runtime-c` or `runtime-c2rust` must be enabled!");
12 | #[cfg(feature = "runtime-c")]
13 | #[doc(hidden)]
14 | pub use tree_sitter as ts_runtime;
15 | #[cfg(all(
16 | feature = "runtime-c2rust",
17 | not(feature = "runtime-c"), // if both features are enabled, use the c runtime
18 | ))]
19 | #[doc(hidden)]
20 | pub use tree_sitter_c2rust as ts_runtime;
21 |
22 | mod error;
23 | pub mod language_set;
24 | pub mod style;
25 | pub mod theme;
26 |
27 | pub use error::*;
28 |
--------------------------------------------------------------------------------
/syntastica-highlight/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-highlight`
2 |
3 | Stripped-down and slightly modified fork of tree-sitter-highlight for use by
4 | [`syntastica`](https://crates.io/crates/syntastica).
5 |
6 | See
7 | [the project overview](https://rubixdev.github.io/syntastica/syntastica/#crates-for-internal-use)
8 | for more information.
9 |
--------------------------------------------------------------------------------
/syntastica-js/.cargo/config.toml:
--------------------------------------------------------------------------------
1 | [build]
2 | target = "wasm32-unknown-emscripten"
3 |
--------------------------------------------------------------------------------
/syntastica-js/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules
2 | /docs
3 | *.wasm
4 |
--------------------------------------------------------------------------------
/syntastica-js/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Use syntastica from JavaScript"
10 |
11 | [dependencies]
12 | syntastica = { workspace = true, features = ["serde"] }
13 | syntastica-macros = { workspace = true, features = ["js"] }
14 | syntastica-themes.workspace = true
15 |
16 | serde = { workspace = true, features = ["derive"] }
17 | serde_json = "1.0.140"
18 |
--------------------------------------------------------------------------------
/syntastica-js/langs/README.md:
--------------------------------------------------------------------------------
1 | # Generated Language Packages for `syntastica-js`
2 |
3 | **DO NOT EDIT THESE FILES!** All files in this directory were automatically
4 | generated by running `cargo xtask codegen js-pkgs` in the syntastica workspace.
5 | If you wish to make any changes, edit the code in the
6 | [js-pkgs xtask](../../xtask/src/codegen/js_pkgs.rs) or the respective language
7 | definition in [`languages.toml`](../../syntastica-macros/languages.toml)
8 | instead.
9 |
--------------------------------------------------------------------------------
/syntastica-js/langs/asm/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-asm"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Asm language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/asm/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-asm`
2 |
3 | Asm language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/asm/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("asm");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/asm/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("asm");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bash/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-bash"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Bash language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bash/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-bash`
2 |
3 | Bash language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bash/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("bash");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bash/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("bash");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bibtex/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-bibtex"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Bibtex language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bibtex/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-bibtex`
2 |
3 | Bibtex language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bibtex/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("bibtex");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/bibtex/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("bibtex");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-c"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "C language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-c`
2 |
3 | C language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("c");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("c");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c_sharp/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-c_sharp"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "CSharp language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c_sharp/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-c_sharp`
2 |
3 | CSharp language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c_sharp/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("c_sharp");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/c_sharp/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("c_sharp");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/clojure/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-clojure"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Clojure language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/clojure/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-clojure`
2 |
3 | Clojure language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/clojure/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("clojure");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/clojure/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("clojure");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cmake/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-cmake"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Cmake language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cmake/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-cmake`
2 |
3 | Cmake language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cmake/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("cmake");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cmake/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("cmake");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/comment/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-comment"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Comment language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/comment/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-comment`
2 |
3 | Comment language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/comment/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("comment");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/comment/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("comment");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cpp/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-cpp"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Cpp language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cpp/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-cpp`
2 |
3 | Cpp language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cpp/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("cpp");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/cpp/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("cpp");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/css/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-css"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Css language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/css/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-css`
2 |
3 | Css language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/css/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("css");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/css/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("css");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dart/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-dart"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Dart language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dart/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-dart`
2 |
3 | Dart language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dart/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("dart");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dart/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("dart");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/diff/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-diff"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Diff language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/diff/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-diff`
2 |
3 | Diff language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/diff/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("diff");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/diff/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("diff");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dockerfile/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-dockerfile"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Dockerfile language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dockerfile/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-dockerfile`
2 |
3 | Dockerfile language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dockerfile/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("dockerfile");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/dockerfile/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("dockerfile");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ebnf/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ebnf"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Ebnf language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ebnf/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ebnf`
2 |
3 | Ebnf language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ebnf/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ebnf");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ebnf/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ebnf");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ejs/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ejs"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Ejs language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ejs/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ejs`
2 |
3 | Ejs language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ejs/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ejs");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ejs/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ejs");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/elixir/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-elixir"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Elixir language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/elixir/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-elixir`
2 |
3 | Elixir language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/elixir/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("elixir");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/elixir/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("elixir");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/erb/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-erb"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Erb language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/erb/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-erb`
2 |
3 | Erb language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/erb/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("erb");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/erb/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("erb");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/fish/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-fish"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Fish language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/fish/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-fish`
2 |
3 | Fish language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/fish/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("fish");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/fish/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("fish");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/gleam/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-gleam"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Gleam language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/gleam/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-gleam`
2 |
3 | Gleam language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/gleam/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("gleam");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/gleam/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("gleam");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/go/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-go"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Go language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/go/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-go`
2 |
3 | Go language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/go/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("go");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/go/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("go");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/haskell/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-haskell"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Haskell language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/haskell/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-haskell`
2 |
3 | Haskell language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/haskell/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("haskell");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/haskell/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("haskell");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/hexdump/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-hexdump"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Hexdump language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/hexdump/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-hexdump`
2 |
3 | Hexdump language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/hexdump/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("hexdump");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/hexdump/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("hexdump");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/html/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-html"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Html language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/html/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-html`
2 |
3 | Html language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/html/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("html");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/html/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("html");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/java/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-java"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Java language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/java/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-java`
2 |
3 | Java language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/java/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("java");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/java/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("java");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/javascript/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-javascript"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Javascript language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/javascript/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-javascript`
2 |
3 | Javascript language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/javascript/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("javascript");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/javascript/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("javascript");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsdoc/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-jsdoc"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Jsdoc language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsdoc/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-jsdoc`
2 |
3 | Jsdoc language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsdoc/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("jsdoc");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsdoc/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("jsdoc");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-json"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Json language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-json`
2 |
3 | Json language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("json");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("json");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json5/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-json5"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Json5 language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json5/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-json5`
2 |
3 | Json5 language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json5/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("json5");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/json5/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("json5");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsonc/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-jsonc"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Jsonc language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsonc/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-jsonc`
2 |
3 | Jsonc language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsonc/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("jsonc");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/jsonc/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("jsonc");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/julia/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-julia"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Julia language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/julia/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-julia`
2 |
3 | Julia language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/julia/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("julia");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/julia/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("julia");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/kotlin/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-kotlin"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Kotlin language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/kotlin/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-kotlin`
2 |
3 | Kotlin language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/kotlin/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("kotlin");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/kotlin/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("kotlin");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lalrpop/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-lalrpop"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Lalrpop language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lalrpop/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-lalrpop`
2 |
3 | Lalrpop language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lalrpop/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("lalrpop");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lalrpop/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("lalrpop");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/latex/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-latex"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Latex language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/latex/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-latex`
2 |
3 | Latex language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/latex/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("latex");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/latex/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("latex");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lua/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-lua"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Lua language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lua/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-lua`
2 |
3 | Lua language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lua/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("lua");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/lua/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("lua");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/luap/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-luap"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Luap language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/luap/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-luap`
2 |
3 | Luap language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/luap/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("luap");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/luap/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("luap");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/make/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-make"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Make language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/make/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-make`
2 |
3 | Make language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/make/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("make");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/make/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("make");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-markdown"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Markdown language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-markdown`
2 |
3 | Markdown language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("markdown");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("markdown");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown_inline/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-markdown_inline"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "MarkdownInline language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown_inline/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-markdown_inline`
2 |
3 | MarkdownInline language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown_inline/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("markdown_inline");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/markdown_inline/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("markdown_inline");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/nix/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-nix"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Nix language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/nix/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-nix`
2 |
3 | Nix language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/nix/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("nix");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/nix/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("nix");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ocaml"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Ocaml language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ocaml`
2 |
3 | Ocaml language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ocaml");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ocaml");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml_interface/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ocaml_interface"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "OcamlInterface language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml_interface/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ocaml_interface`
2 |
3 | OcamlInterface language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml_interface/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ocaml_interface");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ocaml_interface/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ocaml_interface");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-php"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Php language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-php`
2 |
3 | Php language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("php");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("php");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php_only/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-php_only"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "PhpOnly language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php_only/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-php_only`
2 |
3 | PhpOnly language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php_only/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("php_only");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/php_only/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("php_only");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/printf/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-printf"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Printf language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/printf/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-printf`
2 |
3 | Printf language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/printf/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("printf");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/printf/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("printf");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/python/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-python"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Python language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/python/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-python`
2 |
3 | Python language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/python/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("python");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/python/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("python");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ql/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ql"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Ql language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ql/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ql`
2 |
3 | Ql language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ql/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ql");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ql/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ql");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/regex/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-regex"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Regex language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/regex/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-regex`
2 |
3 | Regex language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/regex/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("regex");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/regex/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("regex");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ruby/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ruby"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Ruby language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ruby/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ruby`
2 |
3 | Ruby language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ruby/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ruby");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ruby/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ruby");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rush/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-rush"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Rush language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rush/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-rush`
2 |
3 | Rush language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rush/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("rush");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rush/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("rush");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rust/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-rust"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Rust language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rust/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-rust`
2 |
3 | Rust language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rust/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("rust");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/rust/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("rust");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scala/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-scala"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Scala language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scala/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-scala`
2 |
3 | Scala language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scala/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("scala");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scala/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("scala");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scss/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-scss"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Scss language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scss/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-scss`
2 |
3 | Scss language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scss/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("scss");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/scss/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("scss");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/sql/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-sql"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Sql language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/sql/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-sql`
2 |
3 | Sql language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/sql/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("sql");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/sql/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("sql");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/swift/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-swift"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Swift language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/swift/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-swift`
2 |
3 | Swift language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/swift/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("swift");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/swift/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("swift");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/toml/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-toml"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Toml language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/toml/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-toml`
2 |
3 | Toml language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/toml/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("toml");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/toml/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("toml");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/tsx/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-tsx"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Tsx language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/tsx/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-tsx`
2 |
3 | Tsx language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/tsx/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("tsx");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/tsx/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("tsx");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typescript/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-typescript"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Typescript language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typescript/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-typescript`
2 |
3 | Typescript language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typescript/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("typescript");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typescript/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("typescript");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typst/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-typst"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Typst language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typst/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-typst`
2 |
3 | Typst language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typst/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("typst");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/typst/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("typst");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ursa/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-ursa"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Ursa language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ursa/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-ursa`
2 |
3 | Ursa language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ursa/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("ursa");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/ursa/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("ursa");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/verilog/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-verilog"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Verilog language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/verilog/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-verilog`
2 |
3 | Verilog language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/verilog/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("verilog");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/verilog/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("verilog");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/wat/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-wat"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Wat language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/wat/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-wat`
2 |
3 | Wat language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/wat/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("wat");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/wat/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("wat");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/yaml/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-yaml"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Yaml language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/yaml/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-yaml`
2 |
3 | Yaml language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/yaml/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("yaml");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/yaml/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("yaml");
8 |
--------------------------------------------------------------------------------
/syntastica-js/langs/zig/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-js-zig"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_js/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Zig language support for syntastica-js"
10 |
11 | [lib]
12 | crate-type = ["cdylib"]
13 |
14 | [dependencies]
15 | syntastica-macros = { workspace = true, features = ["js"] }
16 | syntastica-queries.workspace = true
17 |
18 | tree-sitter.workspace = true
19 |
20 | [build-dependencies]
21 | syntastica-macros = { workspace = true, features = ["js"] }
22 |
23 | cc.workspace = true
24 | tree-sitter-generate.workspace = true
25 |
--------------------------------------------------------------------------------
/syntastica-js/langs/zig/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-js-zig`
2 |
3 | Zig language support for
4 | [`syntastica-js`](https://www.npmjs.com/package/@syntastica/core).
5 |
--------------------------------------------------------------------------------
/syntastica-js/langs/zig/build.rs:
--------------------------------------------------------------------------------
1 | const EMSCRIPTEN_FLAGS: &[&str] = &[
2 | "-sTOTAL_MEMORY=33554432",
3 | "-sSIDE_MODULE=2",
4 | "-sWASM=1",
5 | "-sNODEJS_CATCH_EXIT=0",
6 | ];
7 |
8 | fn main() -> Result<(), Box> {
9 | if std::env::var("TARGET").is_ok_and(|s| s == "wasm32-unknown-emscripten") {
10 | for flag in EMSCRIPTEN_FLAGS {
11 | println!("cargo::rustc-link-arg={flag}");
12 | }
13 |
14 | syntastica_macros::js_lang_build!("zig");
15 | }
16 | Ok(())
17 | }
18 |
19 | include!("../../../syntastica-parsers-git/build_helper.rs");
20 |
--------------------------------------------------------------------------------
/syntastica-js/langs/zig/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![no_std]
2 | #![warn(rust_2018_idioms)]
3 |
4 | use tree_sitter::Language;
5 |
6 | syntastica_macros::js_lang_info!();
7 | syntastica_macros::js_lang_lib!("zig");
8 |
--------------------------------------------------------------------------------
/syntastica-js/src/main.rs:
--------------------------------------------------------------------------------
1 | pub use syntastica_js::*;
2 |
3 | fn main() {}
4 |
--------------------------------------------------------------------------------
/syntastica-js/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | /* Visit https://aka.ms/tsconfig to read more about this file */
4 | "strict": true,
5 | "target": "es2016", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */
6 | "module": "es6", /* Specify what module code is generated. */
7 | "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */
8 | "outDir": "./pkg/", /* Specify an output folder for all emitted files. */
9 | "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables 'allowSyntheticDefaultImports' for type compatibility. */
10 | "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */
11 | "skipLibCheck": true /* Skip type checking all .d.ts files. */
12 | },
13 | "include": ["src/**/*"]
14 | }
15 |
--------------------------------------------------------------------------------
/syntastica-js/typedoc.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://typedoc.org/schema.json",
3 | "name": "syntastica",
4 | "entryPoints": ["./src"],
5 | "categorizeByGroup": false,
6 | "navigationLinks": {
7 | "Rust Docs": "https://rubixdev.github.io/syntastica/syntastica/",
8 | "GitHub": "https://github.com/RubixDev/syntastica/"
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/syntastica-macros/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-macros"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_macros/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "Macros for internal use in syntastica"
10 |
11 | [lib]
12 | proc-macro = true
13 |
14 | [features]
15 | default = []
16 | js = ["dep:syn"]
17 |
18 | [dependencies]
19 | heck = "0.5.0"
20 | once_cell.workspace = true
21 | proc-macro2 = "1.0.93"
22 | quote = "1.0.38"
23 | quote-use = "0.8.4"
24 | serde = { workspace = true, features = ["derive"] }
25 | syn = { version = "2.0.98", optional = true }
26 | tft = { workspace = true, features = ["serde"] }
27 | toml.workspace = true
28 |
--------------------------------------------------------------------------------
/syntastica-macros/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-macros`
2 |
3 | Macros for internal use in [`syntastica`](https://crates.io/crates/syntastica).
4 |
5 | See
6 | [the project overview](https://rubixdev.github.io/syntastica/syntastica/#crates-for-internal-use)
7 | for more information.
8 |
--------------------------------------------------------------------------------
/syntastica-parsers-dynamic/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-parsers-dynamic`
2 |
3 | A parser “collection” for `syntastica` which loads languages at runtime.
4 |
5 | See
6 | [the project overview](https://rubixdev.github.io/syntastica/syntastica/#parser-collections)
7 | for more information on all parser collections.
8 |
9 | This parser “collection” doesn't actually include any parsers. Instead, it
10 | provides a [`LanguageLoader`] that implements [`LanguageSet`] by loading
11 | languages at runtime from a given set of directories, very similar to how
12 | [`tree-sitter-loader`](https://crates.io/crates/tree-sitter-loader) does, which
13 | is used by the tree-sitter CLI.
14 |
--------------------------------------------------------------------------------
/syntastica-parsers-dynamic/build.rs:
--------------------------------------------------------------------------------
1 | fn main() {
2 | #[cfg(feature = "docs")]
3 | {
4 | // for documenting features when using nightly
5 | let channel = match rustc_version::version_meta().unwrap().channel {
6 | rustc_version::Channel::Dev => "CHANNEL_DEV",
7 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
8 | rustc_version::Channel::Beta => "CHANNEL_BETA",
9 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
10 | };
11 | println!("cargo::rustc-cfg={channel}");
12 | }
13 |
14 | println!("cargo::rerun-if-changed=build.rs");
15 | println!(
16 | "cargo::rustc-env=BUILD_TARGET={}",
17 | std::env::var("TARGET").unwrap()
18 | );
19 | println!(
20 | "cargo::rustc-env=BUILD_HOST={}",
21 | std::env::var("HOST").unwrap()
22 | );
23 | }
24 |
--------------------------------------------------------------------------------
/syntastica-parsers-git/.gitignore:
--------------------------------------------------------------------------------
1 | /parsers
2 |
--------------------------------------------------------------------------------
/syntastica-parsers-gitdep/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/syntastica-parsers-gitdep/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![doc = include_str!("../README.md")]
2 | //!
3 | #![cfg_attr(
4 | feature = "docs",
5 | cfg_attr(doc, doc = ::document_features::document_features!(feature_label = r#"{feature}
"#))
6 | )]
7 | #![cfg_attr(all(doc, CHANNEL_NIGHTLY), feature(doc_auto_cfg))]
8 | #![warn(rust_2018_idioms)]
9 | #![deny(missing_docs)]
10 |
11 | syntastica_macros::parsers_gitdep!();
12 |
--------------------------------------------------------------------------------
/syntastica-parsers/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/syntastica-parsers/src/lib.rs:
--------------------------------------------------------------------------------
1 | #![doc = include_str!("../README.md")]
2 | //!
3 | #![cfg_attr(
4 | feature = "docs",
5 | cfg_attr(doc, doc = ::document_features::document_features!(feature_label = r#"{feature}
"#))
6 | )]
7 | #![cfg_attr(all(doc, CHANNEL_NIGHTLY), feature(doc_auto_cfg))]
8 | #![warn(rust_2018_idioms)]
9 | #![deny(missing_docs)]
10 |
11 | syntastica_macros::parsers_dep!();
12 |
--------------------------------------------------------------------------------
/syntastica-queries/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-queries"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_queries/"
6 | edition.workspace = true
7 | include = ["LICENSE", "README.md", "src", "generated_queries"]
8 | license.workspace = true
9 | repository.workspace = true
10 | description = "Collection of tree-sitter queries for syntastica"
11 |
12 | [lints]
13 | workspace = true
14 |
15 | [dependencies]
16 |
17 | [package.metadata.docs.rs]
18 | all-features = true
19 |
--------------------------------------------------------------------------------
/syntastica-query-preprocessor/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "syntastica-query-preprocessor"
3 | version.workspace = true
4 | authors.workspace = true
5 | documentation = "https://rubixdev.github.io/syntastica/syntastica_query_preprocessor/"
6 | edition.workspace = true
7 | license.workspace = true
8 | repository.workspace = true
9 | description = "The tree-sitter query pre-processor used by syntastica"
10 |
11 | [dependencies]
12 | lazy-regex = "3.4.1"
13 | lua-pattern = { version = "0.1.3", features = ["to-regex"] }
14 | rsexpr = { version = "0.2.5", features = ["comments"] }
15 |
--------------------------------------------------------------------------------
/syntastica-themes/README.md:
--------------------------------------------------------------------------------
1 | # `syntastica-themes`
2 |
3 | A collection of themes for [`syntastica`](https://crates.io/crates/syntastica).
4 |
5 | See
6 | [the project overview](https://rubixdev.github.io/syntastica/syntastica/#theme-collection)
7 | for more information.
8 |
--------------------------------------------------------------------------------
/syntastica-themes/build.rs:
--------------------------------------------------------------------------------
1 | #[cfg(not(feature = "docs"))]
2 | fn main() {
3 | println!("cargo::rerun-if-changed=build.rs");
4 | }
5 |
6 | #[cfg(feature = "docs")]
7 | fn main() {
8 | // for documenting features when using nightly
9 | let channel = match rustc_version::version_meta().unwrap().channel {
10 | rustc_version::Channel::Dev => "CHANNEL_DEV",
11 | rustc_version::Channel::Nightly => "CHANNEL_NIGHTLY",
12 | rustc_version::Channel::Beta => "CHANNEL_BETA",
13 | rustc_version::Channel::Stable => "CHANNEL_STABLE",
14 | };
15 | println!("cargo::rustc-cfg={channel}");
16 | println!("cargo::rerun-if-changed=build.rs");
17 | }
18 |
--------------------------------------------------------------------------------
/tests/validate_queries.rs:
--------------------------------------------------------------------------------
1 | mod _shared;
2 | use _shared::*;
3 |
4 | syntastica_macros::queries_test!();
5 |
--------------------------------------------------------------------------------
/tests/validate_queries_crates_io.rs:
--------------------------------------------------------------------------------
1 | mod _shared;
2 | use _shared::*;
3 |
4 | syntastica_macros::queries_test_crates_io!();
5 |
--------------------------------------------------------------------------------
/tree-sitter-wasm-build-tool/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "tree-sitter-wasm-build-tool"
3 | version = "0.2.2"
4 | authors.workspace = true
5 | categories = ["development-tools::build-utils"]
6 | edition.workspace = true
7 | keywords = ["tree-sitter", "wasm", "build"]
8 | license.workspace = true
9 | repository.workspace = true
10 | description = "A crate to easily allow tree-sitter parsers to compile to Rust's `wasm32-unknown-unknown` target"
11 |
12 | [dependencies]
13 | cc.workspace = true
14 |
15 | [package.metadata.release]
16 | shared-version = false
17 | release = false
18 |
--------------------------------------------------------------------------------
/tree-sitter-wasm-build-tool/wasm-sysroot/stdbool.h:
--------------------------------------------------------------------------------
1 | #ifndef _STDBOOL_H
2 | #define _STDBOOL_H
3 |
4 | #ifndef __cplusplus
5 |
6 | #define true 1
7 | #define false 0
8 | #define bool _Bool
9 |
10 | #endif
11 |
12 | #define __bool_true_false_are_defined 1
13 |
14 | #endif
15 |
--------------------------------------------------------------------------------
/tree-sitter-wasm-build-tool/wasm-sysroot/stdint.h:
--------------------------------------------------------------------------------
1 | typedef signed char int8_t;
2 | typedef short int16_t;
3 | typedef long int32_t;
4 | typedef long long int64_t;
5 |
6 | typedef unsigned char uint8_t;
7 | typedef unsigned short uint16_t;
8 | typedef unsigned long uint32_t;
9 | typedef unsigned long long uint64_t;
10 |
--------------------------------------------------------------------------------
/tree-sitter-wasm-build-tool/wasm-sysroot/stdio.h:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/RubixDev/syntastica/22eda86181096e4606ad7b1d4f36c91e7269720d/tree-sitter-wasm-build-tool/wasm-sysroot/stdio.h
--------------------------------------------------------------------------------
/tree-sitter-wasm-build-tool/wasm-sysroot/stdlib.h:
--------------------------------------------------------------------------------
1 | #define NULL ((void*)0)
2 |
--------------------------------------------------------------------------------
/xtask/Cargo.toml:
--------------------------------------------------------------------------------
1 | [package]
2 | name = "xtask"
3 | version = "0.1.0"
4 | edition = "2021"
5 |
6 | [dependencies]
7 | syntastica-core = { workspace = true, features = ["runtime-c"] }
8 | syntastica-query-preprocessor.workspace = true
9 | syntastica-themes.workspace = true
10 |
11 | anyhow = "1.0.95"
12 | crates_io_api = "0.11.0"
13 | fancy-regex = "0.14.0"
14 | glob = "0.3.2"
15 | heck = "0.5.0"
16 | lazy-regex = "3.4.1"
17 | once_cell.workspace = true
18 | reqwest = { version = "0.12.12", default-features = false, features = ["rustls-tls", "blocking"] }
19 | rsexpr = { version = "0.2.5", features = ["comments"] }
20 | semver = "1.0.25"
21 | serde = { workspace = true, features = ["derive"] }
22 | serde_json = { version = "1.0.138" }
23 | tft = { workspace = true, features = ["serde"] }
24 | toml.workspace = true
25 |
26 | [package.metadata.release]
27 | shared-version = false
28 | release = false
29 |
--------------------------------------------------------------------------------
/xtask/src/build_js_langs.rs:
--------------------------------------------------------------------------------
1 | use std::process::Command;
2 |
3 | use anyhow::{bail, Result};
4 |
5 | pub fn run() -> Result<()> {
6 | let langs_dir = crate::WORKSPACE_DIR.join("syntastica-js/langs");
7 | for entry in langs_dir.read_dir()? {
8 | let entry = entry?;
9 | if !entry.file_type()?.is_dir() {
10 | continue;
11 | }
12 | let status = Command::new("npm")
13 | .current_dir(entry.path())
14 | .args(["run", "build"])
15 | .status()?;
16 | if !status.success() {
17 | bail!("npm exited with non-zero exit code: {status}");
18 | }
19 | }
20 |
21 | Ok(())
22 | }
23 |
--------------------------------------------------------------------------------
/xtask/src/codegen/generated_queries_readme.md:
--------------------------------------------------------------------------------
1 | # Generated Queries for `syntastica-queries`
2 |
3 | **DO NOT EDIT THESE FILES!** All files in this directory were automatically
4 | generated by running `cargo xtask codegen queries` in the syntastica workspace.
5 | If you wish to make changes to any query, edit the appropriate file in
6 | [the `queries` directory at the repository root](../../queries) instead.
7 |
--------------------------------------------------------------------------------
/xtask/src/codegen/js_langs_readme.md:
--------------------------------------------------------------------------------
1 | # Generated Language Packages for `syntastica-js`
2 |
3 | **DO NOT EDIT THESE FILES!** All files in this directory were automatically
4 | generated by running `cargo xtask codegen js-pkgs` in the syntastica workspace.
5 | If you wish to make any changes, edit the code in the
6 | [js-pkgs xtask](../../xtask/src/codegen/js_pkgs.rs) or the respective language
7 | definition in [`languages.toml`](../../syntastica-macros/languages.toml)
8 | instead.
9 |
--------------------------------------------------------------------------------
/xtask/src/codegen/js_lists.rs:
--------------------------------------------------------------------------------
1 | use std::fs;
2 |
3 | use anyhow::Result;
4 |
5 | const HEADER: &str = r##"
6 | // DISCLAIMER: All code below this line is generated with `cargo xtask codegen js-list`
7 | // in the syntastica workspace. Do not edit this code manually!
8 | /**
9 | * A list of all builtin themes.
10 | *
11 | * @see The {@link BuiltinTheme} type.
12 | */
13 | export const BUILTIN_THEMES = [
14 | "##;
15 |
16 | pub fn write() -> Result<()> {
17 | let ts_path = crate::WORKSPACE_DIR.join("syntastica-js/src/index.ts");
18 | let mut ts = fs::read_to_string(&ts_path)?;
19 |
20 | if let Some((preserve, _)) = ts.split_once(HEADER) {
21 | ts.truncate(preserve.len());
22 | }
23 | ts += HEADER;
24 |
25 | for theme in super::theme_list::find_all_themes()? {
26 | ts += " '";
27 | ts += &theme;
28 | ts += "',\n";
29 | }
30 | ts += "] as const\n";
31 |
32 | fs::write(&ts_path, ts)?;
33 |
34 | Ok(())
35 | }
36 |
--------------------------------------------------------------------------------
/xtask/src/update_vite_example.rs:
--------------------------------------------------------------------------------
1 | use std::process::Command;
2 |
3 | use anyhow::{bail, Result};
4 |
5 | pub fn run() -> Result<()> {
6 | let langs = crate::LANGUAGE_CONFIG
7 | .languages
8 | .iter()
9 | .filter(|lang| lang.wasm)
10 | .map(|lang| &lang.name)
11 | .collect::>();
12 | let demo_dir = crate::WORKSPACE_DIR.join("examples/wasm/vite");
13 | let status = Command::new("npm")
14 | .current_dir(&demo_dir)
15 | .arg("install")
16 | .args(langs.iter().map(|lang| format!("@syntastica/lang-{lang}")))
17 | .status()?;
18 | if !status.success() {
19 | bail!("npm exited with non-zero exit code: {status}");
20 | }
21 |
22 | Ok(())
23 | }
24 |
--------------------------------------------------------------------------------