Today I would like to share one of the simplest developer lifehacks I came up with, yet the one that saved me a ton of time since I started using it. In fact, it's been used without me having to do anything more than just set it up.
Managing multiple Kubernetes environments can be a bit tricky to juggle, especially if you want to make sure you don't deploy anything to production by mistake, or that you're looking on stage env logs to debug a problem that does not exist in prod (yet). It would be better to have some kind of notification what configuration is currently used by kubectl command. This is when I decided to create a flag in my terminal prompt.