Blogs

Synchronizing Google contatcts' birthdays with Android

Google Contacts allow setting birthdays, which are then picked up by Google Calendar automatically and displayed as events on the relevant day. This is very convenient for keeping track of your relatives', friends' and other people's birthdays. Having a reminder saves you an embarrassment of forgetting your girlfriend's/boyfriend's/auntie's day of birth and prevents unnecessary bad feelings.

Tradegy in Oslo

We are all devastated by the terrible events in Oslo, Norway, where almost 100 people were killed in two closely linked incidents of terrorism. Browsing the news about these events, I couldn't help but notice facial similarity between the alleged executor of the terrible acts, a certain Anders Behring Breivik, and the notoriously famous manager of Wikileaks, Julian Assange.

Topic: 

Vim line wrapping and word boundary

Vim (vi) is a very powerful and customizable text editor. There are many parameters you can fine-tune to adjust the way your data is displayed. For example, vim can visually wrap lines, which are too long to fit the width of the screen. This is "virtual" wrapping - no new line characters are actually added to the text. By default, vim wraps the text at the last character, which fits in the visible area. However, especially when editing long runs of text, it is much more convenient to see lines wrap at word boundaries. To achieve this simply use the following command:

Event Importer for Google calendar

I have released a new product: Event Importer for Google calendar. It allows importing iCalendar files (.ics), downloaded via browser quickly and easily. Possible use cases: event export from Facebook, Meetup, other online services, e-mailed .ics files etc. Please give it a try and let me know what you think.

Editing Markdown or txt files in OpenOffice

I have been introduced to Markdown format some time ago and today I find it extremely convenient for most of the writing I need to do. Markdown is essentially "markup without markup" - it requires you to do very little in order to format your text and it can be easily converted in a number of other formats, such as PDF, Word, ODT, LaTeX, HTML, Docbook etc. From experience I found that the most convenient environment to edit Markdown files is OpenOffice (or LibreOffice). Not only is it free and open source, it is actually quite convenient.

Right-align help menu in a WPF application

If you want to right-align the "Help" (or any other) menu entry in your menu bar in a WPF application, you can use the following example:

  1. <Menu>
  2.     <Menu.ItemsPanel>
  3.         <ItemsPanelTemplate>
  4.             <DockPanel HorizontalAlignment="Stretch"/>
  5.         </ItemsPanelTemplate>
  6.     </Menu.ItemsPanel>
  7.     <MenuItem Header="File">
  8.         <MenuItem Header="Exit"/>
Topic: 

How to change shell prompt in Midnight Commander

Bash allows users to do very advanced things when defining shell prompt, including colours and propagation of information into xterm title. Unfortunately, when you want to use mc (Midnight Commander) in conjunction with bash prompts, you may find, that not all advanced escape sequences are handled by mc properly. To overcome this issue you can have a special prompt just for mc. To achieve that, consider the following shell snippet:

Sample .vimrc file for software developers

Vim is a very powerful and convenient text editor for Unix environments. I certainly don't wish to start any disputes along the lines of the old vim/emacs frontier, especially since I used both of them for long periods of time and find unique features in each. However in recent years I tend to use vim most of the time, mainly because it is quite lightweight. In order to benefit the most from the editor it needs to be configured to suit my specific requirements.