Android Apps without Android Studio - 1
I installed Android Studio to make android apps. But it used all he RAM of my Laptop and still froze. So, I deleted it. Then I downloaded Intellij Idea. This time it didn’t freeze until I clicked on ‘build’. It downloaded gradle every time I tried building or assembling the apk and keeps filling the memory.
Next, I tried Flutter with Dart. It worked but it was a bad experience. The apk sizes were HUGE. For example : The basic app that only prints “Hello World” on the screen had the apk size of 73 MB. Reason: Flutter builds single apk for both 32 bit and 64 bit. Flutter needs a lot of workarounds.
I was able to build apps with just command line and a text editor (VS Code).
So, after getting annoyed with Flutter, I tried finding a way to make Kotlin apps using only command line and a text editor.
And for my surprise, there was only one article on the whole google search results that explained how to do it. I tried the tutorial. But it was 2 year old and Android structure has changed a lot since then. So, it didn’t work. But it gave me the idea how to do it.
So, I have made this series of posts for those who have laptops or PCs with RAM < 3.8 GB
Note: The installation instructions are for Windows but most of these should work on other platforms.
Create a Directory named ‘Droid’ in the drive of your choice. I have created ‘F:/Droid’.
Do not create this folder in Program Files, it won't work
Install Java
Install only Java 8 (1.8)
The website requires login, but there are workarounds.
You can rather install openJDK_8. So, it’s your choice.
Install/Extract the exe/File to the Droid Folder.
F:\Droid\Java\
Install Kotlin
Go To Kotlin Website and download the latest release of Kotlin Compiler.
Extract the file to the Droid Folder.
F:\Droid\kotlinc\
Install Gradle
Go To Gradle Website and download the latest gradle.
Extract the file to the Droid Folder.
F:\Droid\gradle\
Install Platform Tools
Now download the Android SDK. Go to the normal install page and scroll to the bottom at Command Line Tools. There you’ll find the zips which are only around 80MB. Here is the link for Windows. This is a zip file.
Extract the file to the Droid Folder.
F:\Droid\android\
We will be needing this folder again while installing sdk tools.
Setting Paths
Open your environment variables and add the bin directories to path.
F:\Droid\kotlinc\bin;
F:\Droid\gradle\bin;
F:\Droid\Java\jdk8\bin;
F:\Droid\android\platform-tools;
F:\Droid\android\tools\bin;
We are not done yet
We have to set ENVIRONMENT_VARIABLES also.
I have added those in the next post, so that we can have comments regarding downloads under one post and for paths in another.
We have downloaded 80 % of the things we will need. The remaining 20 % will be covered in the next post.