Git Product home page Git Product logo

kotlin-sublime-package's Introduction

Kotlin Sublime Text Package

This is Sublime Text package for Kotlin programming language.

Kotlin Sublime Text 2 Package Screenshoot

Overview

The following modules already implemented:

  • Kotlin Syntax Defenition Kotlin.tmLanguage

Download

Installation

There are three ways to install Kotlin Sublime Package:

  • Using archived package (kotlin.sublime-package)
  • Using version control system (GitHub)
  • Using raw files (Kotlin.tmLanguage) from repository tree

There is an instruction with detailed steps for any type of installation.

Contribution

If you want to contribute to this project, first of all you need to download the latest version of AAAPackageDev - useful tool for Sublime Text Packages developing. Then you can follow the tutorials:

There is also a full documentation of Sublime Text extending.

The best way to contribute is to send pull-requests though GitHub interface.

Links


by Vladimir Kostyukov, 2017

kotlin-sublime-package's People

Contributors

0legg avatar aroben avatar belyaev-mikhail avatar cy6ergn0m avatar idrougge avatar shubhamaggarwal avatar vkostyukov avatar willdestijl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

kotlin-sublime-package's Issues

Keyword list

You have list

Any
Array
Boolean
BooleanArray
Byte
ByteArray
Char
CharArray
Double
DoubleArray
Float
FloatArray
Int
IntArray
List
Long
LongArray
Map
Short
ShortArray
String
Unit
dynamic

I found more complete:

Any
Array
ArrayList
Boolean
BooleanArray
Byte
ByteArray
Char
CharArray
CharSequence
Collection
Comparable
Comparator
Double
DoubleArray
Float
FloatArray
Int
IntArray
Iterable
List
Long
LongArray
Map
MutableCollection
MutableList
MutableMap
Pair
Sequence
Short
ShortArray
String
StringArray

"Compile + run" doesn't work on Windows.

"cmd": "kotlinc \"${file}\" -include-runtime -d ${file_base_name}.jar || exit 1; java -jar ${file_base_name}.jar"

The above command will not run "java -jar ${file_base_name}.jar" on Windows.
It seems to be modified to the following to work.

"cmd": "(kotlinc \"${file}\" -include-runtime -d ${file_base_name}.jar || exit 1) && java -jar ${file_base_name}.jar",

I tested it on Windows and CentOS.๐Ÿ˜ƒ

Lexer for other ed?

It is hard to make "lexer" for CudText for Kotlin? I can make small donate for it.

"in" word

Word listed in 1) keywords, 2) modifiers (near "out")

Keywords in function call identifiers

Keywords in function call identifiers result in mis-parsing.

Example: eval("answer=42") which contains val

  • eval("answer is seen as an identifier set to 42
  • The rest of the document is seen as a string because of ")

This also happens with other words such as classify, objection and traitor

Breaks on interpolated strings

In a gradle build script,

val buildFront = tasks.register<NpxTask>("asdf") {
    environment.set(mapOf("BUILD_PATH" to "${output.get().getAsFile().toString()}/static"))
    // broken highlighting after this line
}

the ${output.get().getAsFile().toString()} expression causes broken highlighting.

A lot of keywords not checked for word boundaries

Anything starting with a "class" or "object" or maybe other keywords now triggers highlighting the line as a class header. If the same line somehow contains a '{' symbol, the rest of the file is not highlighted.

val x = className + "{"
val b = foo()
val a = bar()
val x = objectValue; val z = "{"
val b = foo()
val a = bar()

Interfaces without Blocks break the rest of the file until a Block appears

Interfaces don't require a block, but the highlighter won't highlight correctly until it finds a block for the interface.

interface Test

/**
 * Doc Block Comment
 */
val test = 1

/**
 * asdf
 */
val T_UNDEF = object {
    override fun toString() = "undefined type"
}

/**
 * Another Doc Block Comment
 */
val test2 = 2

With an empty block, everything works normally.

interface Test {}

/**
 * Doc Block Comment
 */
val test = 1

/**
 * asdf
 */
val T_UNDEF = object {
    override fun toString() = "undefined type"
}

/**
 * Another Doc Block Comment
 */
val test2 = 2

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.