The Art of Thinking Clearly

Image for post
Image for post
The Art of Thinking Clearly

We are thinking every day. Most of us think at any given moment.

Are our thoughts really clear? Most probably not as we are subject to biases.

This book shines light into which biases and fallacies exist, which errors we make in day-to-day thinking, how we can identify and eradicate them.

One of my favorite bias is information bias. It is the delusion that more information guarantees better decisions.

Elon Musk’s Biography

Image for post
Image for post
Elon Musk’s Biography

Albeit this biography has been published in 2015 and is now already over four years old, it contains a lot of useful information on Elon that describe his way of thinking and reasoning about problems. …


Image for post
Image for post
Basic overview of AOSP

Google has the AOSP (Android Open Source Project) where you can find most of the source code regarding the Android ecosystem. Gradle Plugins, R8/D8, Lint and many other things are located there.

Submitting a patch is easier than expected. Last year, I’ve submitted my first patch — https://android-review.googlesource.com/c/platform/tools/base/+/783316

So let’s get started and see how we can set up our machine so we can contribute.

Authentication

We need to authenticate our self with Google. …


The Lean Startup

Image for post
Image for post
The Lean Startup

Another book about startups.

Customers don’t see how much time it takes to build something. They only care if it serves their needs.

This book explains one way to approach building your product.

Just like the name suggests, it starts with something small, which will be reiterated many times and continuously improved.

Highly recommended if you want to start building something.

Zero to One

Image for post
Image for post
Zero to One

If you are copying from someone, you aren’t learning from them. You’re not innovative and always behind.

This book sprinkles a lot of ideas and concepts about how you can build the future.

It contains a lot of questions throughout the book that can help to refine your idea and hopefully eventually succeed. …


Image for post
Image for post
Some random books

For the majority of my life, I’ve always hated reading books. In school, you had to read. Parents have usually urged you to read. Homework mostly consisted of reading. I’ve always felt that more than 90 percent of the things that I’ve read were boring and didn’t intrigue me. Hence reading was associated with hatred.

At around the age of 17/18, my English wasn’t good. I was highly motivated to get better at it though. So I started reading simple English books and worked my way up from B1 via B2 to C1. Every word that I didn’t know I looked up on my phone, made a screenshot and went through them daily. …


Android Lint is deeply integrated into Android Studio. Issues that are reported will be highlighted either as warnings or errors.

Image for post
Image for post
Lint warning about synthetic accessor methods

Since Android Studio 3.0.0 the integration has gotten even better as we can quick-fix issues by pressing Alt + Enter.

Image for post
Image for post
Lint telling us to make Foo#foo package private

After doing so the warning is gone.

Image for post
Image for post
No Lint warning anymore \o/

While that is super good there hasn’t been anything for the Terminal. Not anymore. Starting with Android Gradle Plugin 3.2.0 Lint got a lot smarter and you can simply execute the lintFix Gradle task.

Image for post
Image for post

It will fix all of the issues it can and break the build since changes were done after compilation. …


Willpower

Image for post
Image for post
Willpower

Everything that we do requires some Willpower, including reading this article.

The book explains what Willpower is, where it is coming from, how we can influence our Willpower and what to do against depleted willpower.

A rested will is a stronger will.

Know your limits. Keep track of things. Pick your battles. Reward yourself. You can fool everyone but yourself.

How To Win Friends And Influence People

Image for post
Image for post
How To Win Friends And Influence People

This book is a must for everyone who’s interacting socially. It’s split up into four parts:

  • Fundamental techniques in handling people
  • Six ways to make people like you
  • How to win people to your way of thinking
  • Be a leader: How to change people without giving offense or arousing…


This article is the first post of a series of personal book recommendations. I mainly write technical blogs here on Medium although the recommendations here will cover every aspect of life. Each time I’ll introduce you three books that I’ve read personally and enjoyed.

ReWork

Image for post
Image for post
Rework

From the founders of Basecamp (ex 37signals) Rework is in complete contrast to most business books.

Instead of writing about what’s already been written in every other business book, it’ll get straight to the bottom.

Everyone can start a business. You don’t need a 5-year plan. …


When implementing in-app billing or subscriptions back in the days you had to use the AIDL file. You had to copy it into your project and then use the raw bare bone API. Luckily, the documentation was decent. The API is still slightly cumbersome and even Google realized that - they introduced their Google Play Billing library.

While the new API is much better, I am personally not that comfortable with it. Too many callbacks, too many Builders and overall a bit verbose.

Personally, I prefer working with RxJava and it can be applied quite nicely to billing. …


Starting with the Android Gradle Plugin 3.1.0 you can apply Android Lint to Java / Kotlin modules.

Setup

It’s as simple as adding the dependency of the Android Gradle Plugin and applying the Lint Plugin.

buildscript {
repositories {
google()
}
dependencies {
classpath "com.android.tools.build:gradle:3.1.0"
}
}
apply plugin: "java-library"
apply plugin: "com.android.lint"

Configuration

Configuring Lint can be done with the lintOptions DSL.

lintOptions {
abortOnError true
warningsAsErrors true
// Many many more.
}

You can look up all of the possible configurations here. The same configuration can also be used inside android modules with the android {} block.

Supported Lint issues

The number of supported built-in Lint checks is much lower though since not every Lint check that targets Android is also applicable to non-android projects. …


Image for post
Image for post

ktlint is an anti-bikeshedding linter with built-in formatter for the Kotlin language. It’s open source, in active development and friendly to first time contributors. If you know Checkstyle it’s very familiar and specialises in formatting for Kotlin. Extending ktlint with your own custom rule is super straightforward.

As a matter of fact writing a rule for Detekt — another tool for analyzing Kotlin code — is very similar and this article is based on https://medium.com/@vanniktech/writing-your-first-detekt-rule-ee940e56428d

Use case

Almost never should you import types from an internal package like it is done below:

import com.foo.bar.internal.InternalClassclass MyClass(val internalClass: InternalClass)

We don’t want to bother with things like this every time we review pull requests. Instead — a machine is much better at things like this. Hence we can write a ktlint rule that will detect internal imports. …

Niklas Baudy

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store