Skip to content

Instantly share code, notes, and snippets.


Drew ousenko

View GitHub Profile

Things I believe

This is a collection of the things I believe about software development. I have worked for years building backend and data processing systems, so read the below within that context.

Agree? Disagree? Feel free to let me know at @JanStette. See also my blog at


Keep it simple, stupid. You ain't gonna need it.


Uninstall brew package and dependencies

Remove package's dependencies (does not remove package):

brew deps [FORMULA] | xargs brew remove --ignore-dependencies

Remove package:

ousenko /
Created Oct 8, 2018
Disable bunch of #$!@ in Sierra (Version 2.1)
# IMPORTANT: You will need to disable SIP aka Rootless in order to fully execute this script, you can reenable it after.
# WARNING: It might disable things that you may not like. Please double check the services in the TODISABLE vars.
# Get active services: launchctl list | grep -v "\-\t0"
# Find a service: grep -lR [service] /System/Library/Launch* /Library/Launch* ~/Library/LaunchAgents
# Agents to disable
TODISABLE=('' '' '' '' '' '' '' '' '' '' '' '' '' '' '' '' '' '' '
ousenko / version.gradle
Last active Sep 4, 2018
Android versioning based on git tags
View version.gradle
* This gradle ext script sets two variables: gitBasedVersionCode and gitBasedVersionName
* These variables are derived from Git history, assuming you use git tags to mark your (micro-)releases
* Using this scheme is a convenient way to automatically derive versions for you application artifacts.
* To begin with it, just set an annotated tag like: `git tag -a 0.1 -m "some artifact version" `
ext {
ousenko / RxScanner
Last active Dec 18, 2017
Rx Wrapper around Bluetooth Low Energy scan process
View RxScanner
import android.bluetooth.BluetoothAdapter;
import android.bluetooth.BluetoothDevice;
import android.text.TextUtils;
import rx.Observable;
import rx.Subscriber;
import rx.functions.Action0;
import rx.schedulers.Schedulers;