Thursday, November 13, 2014

Cool Tools: Vim Tricks

This post will help me remember cool tricks I learn in VIM.  It's mostly for me to find things I've forgotten how to do ...



Select an XML/HTML tag block





Tag blocks      *tag-blocks*

For the "it" and "at" text objects an attempt is done to select blocks between
matching tags for HTML and XML. But since these are not completely compatible
there are a few restrictions.

The normal method is to select a until the matching . For "at"
the tags are included, for "it" they are excluded. But when "it" is repeated
the tags will be included (otherwise nothing would change). Also, "it" used
on a tag block with no contents will select the leading tag.



Sunday, November 9, 2014

Cool Tools: CPU Analysis (CPU-Z)

The other day my windows machine became really slow. I rebooted, which had no effect.  Looking in procexp, most processes were taking much more CPU then I'd expect, and I had a feeling the problem was the machine was getting stuck with a low clock multiplier.



To test the theory, I ran a tool called CPU-Z and sure enough it showed my CPU was getting the lowest possible bus multiplier.



(To fix the problem I pulled and re installed the battery, and then the CPU stopped being throttled).


Friday, November 7, 2014

Depression reading list

I've had multiple people ask for my book recommendations on depression on bipolar disorder.  Here's my reading list:






An extremely well written book about depression. It helps a reader understand the experience of depression from a superb story teller. The author also has a gripping TED talk.






A psychiatrist's story of bi-polar disorder, a very well written personal memoir.  It gives a good feeling of the highs of Mania as well as the lows of depression. 






An engineering manual for laymen on bi-polar disorder.  This is a great book if you'd like to understand the current medical knowledge around bi-polar disorder, as well as what you can do to for yourself and your loved ones. 







Wednesday, October 29, 2014

Don't under estimate e-mail. It's the new drag and drop and notification system.

This will likely roll up into another blog post, but writing it down so  I don't lose it.



In the 2000's using a computer meant using the windows desktop. Two common capabilities from those days were the ability to do a user initiated share of data between applications, and the ability to asynchronously notify the user.



User initiated data sharing on the windows desktop was accomplished with drag and drop. Today there are no apps so there is no notion of sharing between them, except - e-mail. For example, if you want to share a video via youtube, you can send a mail to a special youtube address.



Asyncronous user notification used to be done with notification windows in the bottom user of your screen.  Today there is no notion of an on your latest device alerting platform - except e-mail. For example if youtube wants to tell you your video is ready to be shared, you get an email.



Cool how the world evolves eh?

Sunday, October 26, 2014

Cool Tools: Vim Keybindings

This post will enumerate the vim emulators I use, I expect it to refresh as I learn of more. 



The VIM community is very passionate and frequently adds plugins to support VI keybindings in random tools. Here are the tools I use with their vim key bindings. 



Chrome/Firefox -  Vimium 


Chrome/Firefox Textboxes -  Wasavi 





Windows Command Line - Clink (instructions)

Unix Command Line - set -o vi






OneNote - Vim For OneNote




Visual Studio - VsVim (my customization here)

Visual Studio Code - VsCodeVim













IntelliJ - IdeaVim (my customization here)





XCode - XVim (my customization here)





Jupyter Notebooks - jupyter-vim-binding




Happy VIMing. 

Soft Skills: Job Hunt Stress

This post targets currently employed developers who want to switch jobs.  



Job hunts are stressful, and my goal for my job hunts is getting the job I want without getting too stressed.  My job hunting stresses come from: lack of confidence, being rushed, not having options, disappointing others and the pressure from my current job responsibilities. By expecting and mitigating each of these stressors I greatly reduce the stress during my job hunt.



Below are my stressors and mitigations:



Lack of confidence

Study for technical interviews - Study Cracking the Coding Interview and system design questions. Expect to spend 4-8 hours a week for 4 to 8 weeks.  The longer it's been since you've interviewed last, the longer this will take.

○ Prepare for behavioral questions - Think through your previous projects for situations that demonstrate leadership, confidence, team building and be prepared to discuss them.


Do mock interviews - ask your friends and colleagues to interview you.  You should fail the first few mock interviews it's normal.

Being rushed

Know your "must be done by" date -  don't get stressed over  your own fake deadlines.

Lack of options for next jobs

Figure out what you want to accomplish - I use the Business model You approach to figuring it out.

Look around for who is hiring

Start and maintain a list of candidate jobs

Have a worst case scenario job

Disappointing others

Be honest with yourself about what you can control and share.

Think about what you can do to reduce the impact to your  customers, partners,  subordinates and bosses

Pressure from current job

Negotiate with your current boss for time to work on job hunt.

Recall your highest priority is the next job, but you have existing commitments.



Even when you know about the common stressors a job hunt is still an emotional roller coaster. Expect to have "ups" and "downs". Have a support network with whom you can vent, share disappointments and gloat.



Good luck on your next adventure and checkout HBR's Setting the record strait on switching jobs.

Thursday, October 23, 2014

Cool Tools: Git Helpers

This post will enumerate the helpers and commands I use with git, I expect it to refresh as I learn of more. 



Tools:

git-credential-winstore - Cache your git credentials for windows

Source Tree - a superb gui for git. I use it for all but the simplest commits.

gitk - Built into the git distro, gitk allows you to visualize the tree







Uncommon, but useful operations



Move recent commit from master to a branch.



git branch newbranch
git reset --hard HEAD~3 # Go back 3 commits. You *will* lose uncommitted work.*1
git checkout newbranch



Get a local copy of a server branch (tracking branch)  

 git checkout  







See which branches contain which commit



 git branch -r --contains



See pretty view of history (all after tag 1.2.38.0)



git log --decorate --oneline --no-merges  1.2.38.0..



Even prettier




git log --pretty=format:"%C(yellow)%h%Cred%d\ %Creset%s%Cblue\ [%cn]" --decorate



Revert a file on a branch back to the copy in master



git diff ..master -- scorch.bat  > patch

git apply patch



Git touch



 git commit --allow-empty -m "Trigger notification"


Saturday, May 17, 2014

Cool Tools: VIM for Onenote

If you use OneNote and VIM, checkout VIM keybindings for Onenote. If you're having trouble getting this working, leave a comment and I'll give you a hand.

Wednesday, April 30, 2014

Cool Tools: Color Laser Printer

My whole life, I've either not had a printer, or had a crappy inkjet printer. Two weeks ago I bought a color laser printer (at semi-random) for 200$, and every time I print I get a perfect, dry, color print.  I have no complaints what so ever, it's just awesome.


Sunday, April 20, 2014

Cool Tools: Kindle

If you don't have a kindle, go buy a kindle paper white right now.  If you own a kindle, skim this post to make sure you know about these features.



Things I love about the Kindle:


  • All my books, all the time -  no shelf space required. 

  • No need for a nightlight - The back light lets me read at night, without the hassle of lights.

  • Indestructible Media - I can stop worrying about spilling coffee on my books.

  • Light weight - doesn't matter if it's a 2 lb mega book, or a few page poem, it's just weight of the kindle.

  • Fungible - All kindles are same, get a new kindle, it downloads all your books, bookmarks and highlights. 


Features I use:


  • Sync between kindles - if you use multiple kindles the kindle sends your latest page location to all kindles.

  • Look up word - Press and hold a word to see the definition. A great way to build your vocabulary.

  • Highlight Passages - Run your finger over a paragraph to highlight. You can see your highlights on other kindles, or export them using the cool tools below. 

  • Re-size fonts - Having a big font is wonderful for low strain reading. 


Cool Tools:


  • Send To Kindle - Send content (like web pages or word documents to the kindle)

  • Bookcision - Export your kindle highlights as text




Soft Skills: Read the best book you can.

When I have time to read, I want to read the best book I can.



When I hear about a book I want to read, I either add it to the list of books I want to read, or I start reading the book immediately.   If I add the book to my  "to read" list, I'm almost certain I'll never read the book.  On the other hand, If I start reading the book right away, I'm almost certain the book is worse than books I've already added to my "to read" list.



So, I'm going to try to build the discipline to only read the best book on my "to read" list, instead of reading the last good book mentioned to me.  



I suspect this technique will be hard,  but reading the best books might be worth it.  If this works, I'll try to apply the same technique to other aspects of my life like movies, toys I want to watch, and people I want to have lunch with.

Monday, April 7, 2014

Soft Skills: Instilling stewardship delegation.

Stewardship delegation is a form of delegation where the responsibility for the delegated task is transferred to the delegatee.  Stewardship delegation requires upfront effort, but the long term effectiveness it creates is second to none, so I recommend learning and applying it.



To establish stewardship delegation you must convey five concepts to your delegatee.  The desired results, the operating parameters, the available resources, the measurement system and the consequences of their stewardship.



 I strongly recommend the delegator spend significant time ensuring the delegatee  understands these five concepts. Most of my failures to delegate are caused by the delegatee not understanding the concepts.  Having the delegatee involved in defining the concepts, especially the accountability model and the consequences helps build their buy in and tests the delegatee's understanding.



The desired results is the outcome the delegator wishes to achieve.  Desired results should be conveyed in terms of what is desired, not in terms of how results should be achieved. By specifying what, not how,  the delegatee has the maximum freedom to achieve the desired results.



The operating parameters are the guard rails within which the desired results should be achieved.  While the delegator should give as few as possible, they tend to have experience and prevent the delegatee from making obvious mistakes.



The resources available are what the delegatee may use to get the desired results accomplished.  Because the delegator tends to have experience they can often suggest useful resources, however the delegatee should have the freedom to ignore the unneeded resources.



The accountably model defines how the delegatee will be measured. This includes the measurement function, the measurement frequency and the way the measurement will be reported.



The rewards and consequences defines how the delegatee will be rewarded for their efforts. This includes the both rewards for success, and consequences for failure.



By using these delegation guidelines you should be able to kick off steward ship delegation. Even though it takes more time upfront, the overall return on investment is excellent.



By the way, I'm trying to leverage the stewardship delegation method with myself, by taking a desire I wish to achieve and going through the five delegation concepts. I expect I'll find this method very effective.


Sunday, March 9, 2014

Soft Skills: Effective Delegation

delegate_pivotA key scale out skill is delegation. Effective delegation refers to a small negative impact to the delegator resulting in a large positive impact via the effort of the delegatee.   Maximum delegation efficiency occurs in stewardship delegation. Stewardship delegation empowers the delegatee to be responsible for the delegated task, and takes an initially large investment from the delegator. However, once the stewardship delegation relationship has been established, minimal effort is required by the delegator to maintain the impact of the delegatee.



A delegation relationship can be modelled as a teeter totter with the delegator on the left and the delegatee on the right.   The effectiveness of the delegation can be thought of as the pivot location. To increase the effectiveness of the delegation, the pivot must be moved to the left which allows small effort by the delegator to enable large impact via the delegatee.



The pivot location and its movement is a function of delegation style.   At the extreme of delegation styles is gopher delegation and stewardship delegation. Gopher delegation keeps the responsibility for the task with the delegator and involves telling the delegatee extremely prescriptive tasks e.g.  go for this, go for that.   Stewardship delegation transfers the responsibility for the delegated task  to the delegatee and requires the delegator explaining the end result and the operating principles of the delegated task to the delegatee.



At the start of gopher delegation  the teeter totter pivot starts at the left of center with the delegator's cost less than the gains achieved through the work of the delegatee.  This makes the delegator effective from the start, and seems great.   However, over time as the delegatee does tasks wrong,  as the delegated tasks start having complications, and ultimately as the delegatee gets bored and disengaged, the pivot begins to move the to the right.   After a while, gopher delegation results in a pivot right of center, and the delegation ends up being ineffective.  Eventually, more time is required from the delegator then is gained from the actions of the delegatee and thus gopher delegation is best used for short lived scoped tasks.



At the start of stewardship delegation, the teeter totter pivot starts very far to the right. Significant time needs to be spent to engage the delegatee. The delegatee needs to understand the desired result, the operating parameters, and ultimately needs to be feel empowered and responsible.   Over time, as the delegatee understands her role and its responsibilities the pivot begins to move to the left, but the delegator still requires large investment as she must provide feedback and encouragement.  Eventually the pivot will cross the center, and continue moving left until the delegator is only required to give the briefest task, and know with confidence the delegatee can complete the delegated tasks.



Large scale effective delegation requires stewardship delegation.  Because stewardship delegation requires passing the responsibility for the delegated task from the delegator to the delegatee it requires a large upfront investment. However over time, as the delegatee is empowered, minimal delegator effort will result in large impact from the delegatee.



A future posts will discuss how to establish stewardship delegation.

Sunday, March 2, 2014

Soft Skills: Scaling out vs scaling up

Scaling UP vs Scaling OUT
Scaling up refers to becoming a more effective person by increasing your personal efficiency. Scaling out refers to being a more effective person by engaging others to help solve your problems.    While scaling out is initially more difficult than scaling up, it has the potential for significantly more effectiveness than scaling up, so you should spend time investing in both types of scaling.




To understand the entomology of these terms lets look at the computer domain.  In the domain of computers there are two common ways to achieve more computing power or scale. Scaling up and scaling out.



Scaling up refers to getting more computing hardware for a single machine.  For example,  getting more RAM, faster CPUs or even bigger disks for the same computer.     On the other hand, scaling out refers to getting more computers. Instead of making your single computer faster you break up the problem so it can be processed by multiple computers and use the multiple computers to get the job done.



Scaling out requires changing the way the problem is solved, forcing co-ordination and making the problem more complex. As a result scaling up sounds like the way to scale.



At first, scaling up is  the easy way to scale. You throw some new hardware in the computer, and without much work you have more computing power.   As you upgrade your computer you start getting diminishing returns. Consecutive upgrades get more and more expensive, until eventually you can no longer upgrade your computer as it will be at its maximum power.  At this point you have no choice but to scale out.



Scaling out is hard. It requires you to think about how the problem can be broken up, how the computers can be coordinated and  how to keep the computers synchronized.  However, once you've made your problem solvable through scale-out solutions you can often add lots of computers. By scaling out, you can have significantly more computing power then you could ever have via a scale up solution.



As with computers and computing power, people often require more effectiveness to solve their problems. They have two ways to solve their problems, either they scale up, by becoming more efficient, or they scale out by engaging others to help solve their problems.



Humans scaling up reach diminishing returns - an easy to understand limit is the hours in a day.  Regardless of how efficient you are, you still only get 24 hours in a day.



As an alternative to scaling up, humans can scale out.  Scaling out requires figuring out how to break up problems so more than one person can work on them, and figuring out how the people will co-ordinate.



While scaling out is initially more difficult than scaling up, it has the potential for significantly more effectiveness than scaling up, so you should spend time investing in both types of scaling.



If you've read the 7 habits of highly effective people, you may notice that scaling up refers to the 3 habits of independence, while scaling out refers to 3 habits of interdependence.  I'll spend many more posts discussing these two types of scaling.

Saturday, February 15, 2014

Soft Skills: Concise, or is it?


I love being concise
-
  the efficiency warms my heart.  Russian, with its single  verb question, and matching single verb
response gives me a visceral pleasure. Two Russians, Sergey and Slava, wanting to grab lunch could have the  following exchange:





Sergey: Eat?


Slava: Eat!





My love of
conciseness often  has me sending short
emails.  Frequently, my mails are so
concise that my reader has no idea what I'm talking about. This confusion means  I need to send another mail explaining the
meaning of my initial concise mail.




To conclude the lengthy explanation of my concise mail, I hear the words of my wise
friend -  a message isn't concise if the
reader can't understand it.

Friday, January 3, 2014

Forget your weak passwords

Like everyone else on the internet, I hate passwords. I wish everyone would let me login with my existing accounts like this:

identity provider login

But they don’t, so I have two passwords. My strong password which I use for my email and banking, and my weak password which I use on the rest of internet sites. Today I realized I don’t need to use a weak password. Most sites have a password reset feature that sends you a mail, and if you click the mail you can change your password whenever you want so: Use a random password for sites that do their own authentication and forget th password!


  • Whenever you want to login, request a password reset.

  • Click on the link on your email, which will take you to a reset screen.

  • Make a random password and copy it to your clipboard

  • Use the password on your clipboard to set a new site password and login.


Because of password reset feature, access to your email account is really access to all of your accounts so: Guard your email password


  • Make your email password is random and complex.

  • Use two factor authentication (sms/authentication app)

  • Never re-use your email password.


Enjoy forgetting your weak passwords!