gap, my most loved git command

gap the alias I created, mapping to git add -p has been one of my most typed commands ever since I changed my workflow.

What this does :

It breaks up your diff into smaller chunks that help you avoid committing things you really don’t want to and helps you know exactly what code is going into the next command. For each chunk, you can choose to stage it or not. All staged changes are those that will be included in your next commit.

To add this command it opens your .bashrc in any editor and add this to it: alias gap="git add -p

It doesn’t matter if you use Git CLI or the app as you get the same things done, but if you really want to get comfortable with it, start using the terminal. It will be painful in the beginning, but you’ll learn more about Git this way.

One liner for importing multiple SQL files using WP CLI DB command

In some cases, SQL backups break exports into multiple files, usualy by table name.

I wanted to import all the files in one go and figured googled my way to this “one liner”:

Continue reading “One liner for importing multiple SQL files using WP CLI DB command”

What does 6 months paternity leave feel like with 2 babys?

I didn’t want to say much about this as it is not that common, especially here in South Africa. The norm here is three days and some annual leave. When I share that I’m on family responsibility leave and for how long, people usually either respond with excellent or a mild form of disgusted jealousy. I’m am truly blessed to have the privilege of paid leave for such a long time.

Continue reading “What does 6 months paternity leave feel like with 2 babys?”

It doesn’t have to be crazy at work – quick book review

I usually stick to one book and finish it before moving on, but this book grabbed my attention instantly. Firstly because I love the way the authors run their company. They are so unconventional and so intentional at the same time. So I dropped my current book (The Undoing Project) and jumped into this book.

More Info

WP Docker Curl Error

If you are using Docker for WordPress development you may have discovered an issue while trying to connect to your installation from the CLI.

Trying to do any internal API calls normally result in a curl call. In my case I had this annoying error:

cURL error 7: Failed to connect to local.test port 80 Connection refused

Continue reading “WP Docker Curl Error”

Giving Advice Doesn’t Work, I found a better way

I was recently chatting to a friend. He mentioned some area where he was not succeeding . I had the perfect answer. If he’d only follow my advice.

I make this mistake all too often. I can see it in people’s response. They fell insulted or just irritated that I would try to give advice. I do it sincerely but it always backfires.

I realized that Giving People Advice Rarely Works.

I found this helpful, maybe you will too
— Read on www.google.co.za/amp/s/www.psychologytoday.com/us/blog/do-the-right-thing/201407/giving-people-advice-rarely-works-does?amp

The most gifted books from the tribe of mentors

I read Tribe of Mentors, a year ago, and wrote down all the recommended books. I made notes on these books as I wanted to see if there are commonalities between the things highly successful people read. To no surprise, I found that many of the mentors recommended the same books.

I thought it would be helpful to create a list of the top ten recommended books. This list is in order of most occurrences and according to my naive method for counting and making notes.

Continue reading “The most gifted books from the tribe of mentors”