How to make gitk show only local branches?

git, git-branch, gitk

Solution

After some experimenting I have found a solution. The following command works:

echo $(git branch) | gitk

It shows only those remote branches that have corresponding local branches. It is important to use `echo $(git branch)` since it forces `branch` to return raw list of branches instead of formatted output such as the following:

$ git branch
  develop
  release-M4.1
  vendor
* xflow

Problem

How to make gitk show only local branches? Or even better - can I hide remote branches that do not have corresponding local branches?

Original source