This blog post describes how to start Kontribute or how to start contributing Kotlin.
Who am I?
I’ve been kontributors since July 2016. I made more than 60 commits by now. I love Kotlin, my beautiful wife and lovely son.
I talked about this topic a few times in different places. After speaking at DroidKaigi 2018 and Kotlin Night Kolkata, some people gave me feed back that it is also helpful for new Kontributors if I make a blog post in English. I am too lazy to write this from scratch, so I re-used some of contents from those presentation.
This blog entry does not explain how to use git/github and how to write Kotlin.
Since I mainly contribute to Kotlin plguin features, this blog post focus on how to contribute kotlin plugin. However, once you undersntand how to do it, it is really easy to contribute to Kotlin Languages, Kotlin JS or Kotlin Native because it is in the same repository.
It “was” the hardest part but not anymore. This is the reason I updated this topic as v3. There are “only” 4 parts of setups
The first one is JDK.
You need to install 3 differenct versions of JDKs.
In order to use those JDK, you must setup environment variables like this
It’s quite annoying to set each environment variables. Here is what I did.
1 2 3 4
Intellij IDEA & Plugins
As for Intellij IDEA, you can use both community and ultimate version.
To make sure you are using latest kotlin plugin, check the following gif.
After setup Intellij IDEA, you can open kotlin plugin. First time you open the project, Intellij downloads all dependencies using gradle. It took me about 50 mins. Just wait.
After downloading dependencies, you will notice that there is no source code in Project view. To fix this problem, you will need to do the followings:
- Go to File | New | Module from Existing Sources | and then select
- After selecting the file,
Import Module from Gradledialog popup. Select
use default gradle wrapper
The following gif visually describes the steps
Setup is done. Let’s run it. To run it, select
IDEA run configuration and hit run button.
After waiting a few minites, the child IDEA shows up. What does this do is if you change your Kotlin project, the change is bundle to this child IDEA. You can test your new feature in this child IDEA.
If you cannot build or run the project, ask other kontributors! In next blog post, I will talk about how to intract with other Kontributors or JetBrains team.