GithubHelp home page GithubHelp logo

djgoku / tree-sitter-langs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from emacs-tree-sitter/tree-sitter-langs

0.0 2.0 0.0 476 KB

Language bundle for Emacs's tree-sitter package

Home Page: https://ubolonton.github.io/emacs-tree-sitter/languages/

License: MIT License

Emacs Lisp 100.00%

tree-sitter-langs's Introduction

tree-sitter-langs

This is a convenient language bundle for the Emacs package tree-sitter. It serves as an interim distribution mechanism, until tree-sitter is widespread enough for language-specific major modes to incorporate its functionalities.

For each supported language, this package provides:

  1. Pre-compiled grammar binaries for 3 major platforms: macOS, Linux and Windows, on x86_64. In the future, tree-sitter-langs may provide tooling for major modes to do this on their own.
  2. An optional highlights.scm file that provides highlighting patterns. This is mainly intended for major modes that are not aware of tree-sitter. A language major mode that wants to use tree-sitter for syntax highlighting should instead provide the query patterns on its own, using the mechanisms defined by tree-sitter-hl.

Building grammars from source

It’s more convenient to work with this repository as a submodule of emacs-tree-sitter. However, if you want to skip that, below are the steps to build grammars from source using only this repository.

Tools and dependencies

  • Install cask.
  • Install npm. (Some grammars depend on another npm-packaged grammar. For example: cpp, typescript.)
  • Install tree-sitter CLI tool (if you don’t use NodeJS, you can download the binary directly from GitHub).
  • Clone this repository and install its dependencies.
git clone https://github.com/ubolonton/tree-sitter-langs
cd tree-sitter-langs
cask install

Building a single grammar

cask eval "(progn (require 'tree-sitter-langs-build) (tree-sitter-langs-compile 'rust))"

Building the whole grammar bundle

cask eval "(progn (require 'tree-sitter-langs-build) (tree-sitter-langs-create-bundle))"

tree-sitter-langs's People

Contributors

davidpa9708 avatar douglasdavis avatar jcs090218 avatar kiennq avatar mplamann avatar sogaiu avatar tarsius avatar thehamsta avatar theothornhill avatar ubolonton avatar vconcat avatar vincent-p avatar wyuenho avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.