Open source software that powers real production systems, and the macOS tooling that keeps high-output engineering teams productive.
Below is a useful script when you want to see which processes are using a specific port.
Read more →For the life of me I can never remember where this sits in the settings, all I know is that it irritates me constantly 🙂 So to turn off handoff, run the script below:
Read more →I frequently forget this command shortcut, so this post is simply because I am lazy. To clear your history in iTerm press Command + K. Control + L only clears the screen, so as soon as you run the next command you will see the scroll back again. If you want to view your command […]
Read more →If you have multiple connections on your device (and maybe you have a zero trust client installed); how do you find out which network interface on your device will be used to route the traffic? Below is a route get request for googles DNS service: If you have multiple interfaces enabled, then the first item […]
Read more →If you’re like me, little things bother you. When I turn on my bluetooth headset and it connects to my Macbook when its closed/sleeping, I get very frustrated. So I wrote a simple script to fix this behaviour. After running the script below, when you close the lid on your Macbook it will automatically turn […]
Read more →Below is a dump of examples of doing pretty much the same thing differently. I mostly use netstat and lsof, coupled with some bash scripts. You can argue that this is overkill, but below is a simple bash function that you can paste into terminal and call it whenever you want to see which application/process […]
Read more →Each day that I wake up I try and figure out if I can do less work than yesterday. With this in mind I was playing around to see if there is a way to save me typing my password each time I SUDO. It turns out this is quite a simple change… Open Terminal […]
Read more →Back in the day I had to do quite a bit of COM / .Net interop. For some reason (and I cannot remember what it was), I need to be able to enumerate the COM running objects table (ROT). I think it was to do with createboject/getobject and trying to synthesis a singleton for an […]
Read more →1. What ShedLock Is and How It Works Spring Boot makes it trivial to schedule a task. You add @EnableScheduling to a configuration class, annotate a method with @Scheduled, and the framework fires it on your chosen cron or interval. The problem surfaces the moment you deploy more than one instance of your application. In […]
Read more →If you’re trying to figure out whats draining your macbook, even when the lid is closed – then try the script below (call with “sudo ./battery_drain_analyzer.sh”): If you see windowServer as your top consumer then consider the following: Finer grained optimisations: To optimise the power when the lid is closed, below are some options:
Read more →Getting an application knocked out with a simple SYN flood is both embarrassing and avoidable. Its also very easy to create a SYN flood and so its something you should design against. Below is the hping3 command line that I use to test my services against SYN floods. I have used quite a few mods, […]
Read more →Every Java developer has seen it. The stack trace that ends conversations. The production incident that ruins a Friday afternoon. The crash that leads to the post-mortem nobody wants to write. NullPointerException. Three words that have probably cost the industry more money, time, and credibility than any other single class of bug in software history. […]
Read more →