Skip to content
Online mini-IDE for Kotlin
Kotlin Java JavaScript CSS HTML TSQL
Branch: master
Clone or download

Latest commit

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.idea support kotlin 1.3.20 🚀 Jan 23, 2019
docker update mysql connector (#60) Oct 9, 2018
gradle/wrapper Update kotlin version Nov 3, 2017
kotlin.web.demo.backend tmp: change status for synch with frontend Aug 2, 2019
kotlin.web.demo.common Mark 1.4-M2 as preview version May 18, 2020
kotlin.web.demo.executors/src/main/java/org/jetbrains/webdemo/executors drop cause from error stream Mar 9, 2019
kotlin.web.demo.frontend Remove save feature Apr 26, 2020
kotlin.web.demo.server improve maze example (#59) Oct 12, 2018
kotlin.web.demo.test (minor) update tests Mar 30, 2018
versions Mark 1.4-M2 as preview version May 18, 2020
.gitignore support 1.3 experimental features (#61) Oct 10, 2018
LICENSE Add missing LICENSE file Apr 28, 2017
README.md
build.gradle CVE: CVE-2018-1000873 update jackson to 2.8 Mar 7, 2019
build.txt Remove % May 10, 2017
docker-compose.yml Add docker-compose files Jul 11, 2017
gradle.properties kotlin project version 1.2.60 Aug 2, 2018
gradlew update mysql connector (#60) Oct 9, 2018
gradlew.bat Update kotlin version Nov 3, 2017
install_tomcat.xml Corrects file name. Sep 22, 2017
kotlin.web.demo.iml Minor: rename artifacts. Jul 7, 2016
lgtm.yml Create lgtm.yml Oct 21, 2019
local.properties Add Kotlin 1.2-Beta2 version Oct 19, 2017
settings.gradle Move compilers versions to root directory Feb 9, 2018

README.md

official JetBrains project

This repository contains sources for try.kotl.in

Manual installation 🐳

Before starting the Kotlin-Web-Demo execute two gradle tasks: copyKotlinLibs for downloading kotlin libraries for compiler and war for building war-archive from IDE or terminal:

$ gradlew ::copyKotlinLibs
$ gradlew war

By default try.kotl.in uses port 8080, and if that's OK, just make it available at http://localhost:8080 via this command:

$ docker-compose up

To change the port number, tweak 'docker-compose.yml':

    ports:
      - "your_port:8080"

If you'd like to log in to JetBrains account, Google, Facebook, GitHub, or Twitter, add corresponding keys to this configuration file:

    <Environment name="github_key" value="YOUR-KEY" type="java.lang.String" override="false"/>
    <Environment name="github_secret" value="YOUR-SECRET-KEY" type="java.lang.String" override="false"/>

How to add your own courses 📝

  • Add a course name to manifest.json.
  • Use that name to create a folder next to the Examples folder and put your course content under it.
  • Make a folder for each of the course topics (and don't forget adding them to manifest.json).
  • After that, create:
    1. Test.kt — for test questions
    2. Task.kt — for preview
    3. Solution.kt — for answers to the test questions
    4. task.md - tasks descriptions
    5. manifest.json - to store 'junit' configuration

See Kotlin-Koans for examples.

How to add your dependencies to kotlin compiler 📚

Just put whatever you need as dependencies to build.gradle via gradle task called library:

 library "your dependency"

NOTE: If the library you're adding uses reflection, accesses the file system, or performs any other type of security-sensitive operations, don't forget to configure the executors.policy.template in web-demo-backend. Click here for more information about Java Security Police

How to set Java Security Police in executors.policy.template

If you want to configure a custom dependency, use the marker @WRAPPERS_LIB@:

grant codeBase "file:@WRAPPERS_LIB@/junit-4.12.jar" {
  permission java.lang.reflect.ReflectPermission "suppressAccessChecks";
  permission java.lang.RuntimePermission "setIO";
  permission java.io.FilePermission "<<ALL FILES>>", "read";
  permission java.lang.RuntimePermission "accessDeclaredMembers";
};

Feedback and Issue reporting 👷

We're constantly working on making it easier to add your own courses to try.kotl.in and would appreciate ideas, suggestions, and other feedback, so if you have any, please use our issue tracker to share it with us.

And, of course, if you have any bug reports, you can file them as well If you need any help with compiling or running the project locally, join the #kontributors channel in the Kotlin Slack, and we'll be happy to help you out.

You can’t perform that action at this time.