Giter VIP home page Giter VIP logo

lite-xl-tokenizer's Introduction

Lite XL C-Tokenizer Plugin

This repository provides a standalone copy of the work done by Adam on the native implementation of the Lua tokenizer found on his simplified branch https://github.com/adamharrison/lite-xl-simplified/tree/c-tokenizer for testing purposes.

Building

You will need to have meson and a working build environment for your operating system. Then, to build just execute the following commands:

meson setup build
meson compile -C build

By default we configured meson to download Lua and pcre2 and statically link to it. To disable this behavior and instead link against system libraries, use --wrap-mode default

meson setup --wrap-mode default build

Also you can link to luajit instead by adding -Djit=true

meson setup -Djit=true build

Installation

To install just copy the generated library file to your libraries directory:

cp build/tokenizer.so ~/.config/lite-xl/libraries/

Then install the Lua plugin to take advantage of the native tokenizer plugin:

cp plugins/ctokenizer.lua ~/.config/lite-xl/plugins/

Usage:

You can enable and disable the native tokenizer from the settings or by modifying the value of config.plugins.ctokenizer.enabled to true or false.

Also, you can enable config.plugins.ctokenizer.log_time to measure the time it takes to tokenize a range of lines.

lite-xl-tokenizer's People

Contributors

jgmdev avatar

Watchers

 avatar  avatar

Forkers

delta-official

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.