Cygwin, Dropbox and todotxt.sh

This short ‘howto’ describes:

  • putting the home directory of Cygwin on Dropbox
  • making the todotxt.cfg work on all Windows(*) machines, regardless of the directory where your Dropbox is located.

(*) This only works on Windows Vista and higher.

Background
Since a month or so, I use the open source task management script todotxt of Gina Trapani. I am enthousiastic about the uses of this system, so I have spent some time optimizing it. Below is a description of a few hacks that I use.

Because the computers that I use daily are Windows based, I decided to install Cygwin so that I can deploy the original todotxt.sh bash-script. Running the todo system from the command line has a lot of advantages, like easier search and selection, tab completion, easier adding of todo’s, etc.

If you want to know how to set up todotxt.sh under Cygwin, please read this short manual. Here, I asume that the reader is already familiar with using todotxt.sh in this way.

Screenshot of Cygwin terminal with todo-list

Putting the Cygwin home directory on Dropbox
When your Cygwin home directory is replicated to all your Windows machines, so are all your Unix terminal programs settings. When, for instance, you have created some aliases by editing your .bashrc file, it is very nice to be able to use these on all your Cygwin-machines. The same goes for your .vimrc or even your history!

The script todotxt.sh is also located in your home-directory and when the home directory is replicated by Dropbox, you only have to upgrade your todotxt.sh installation once to keep all your Windows Cygwin machines up-to-date.

  1. Stop Cygwin
  2. Make a backup copy of the directory C:\Cygwin\home\{yourname} to a safe location.
  3. Move (not copy) the directory C:\Cygwin\home\{yourname} to your Dropbox. I have moved the home directory to the location {Dropbox}\settings\cygwinhome.
  4. Create a symbolic link to the Dropbox location with the utility mklink.

Below is an example.

mklink /d c:\cygwin\home\ton c:\Users\ton\Dropbox\settings\cygwinhome

This command creates a directory link with the name ‘ton’ (my username) that points to the cygwinhome-directory on your Dropbox. Of course, you should substitute ‘ton’ with your own Windows user name.

This function to create links is not available on Windows versions older than Vista.

Making the todotxt.cfg file roaming
I also use the Android-app Todotxt Touch and therefore, I would like to keep the location of the todo.txt file to the default. Therefore, I do not place my todo.txt file in my Cygwin home directory.

If you edit the todotxt.cfg file, the first lines may look like this:

# === EDIT FILE LOCATIONS BELOW ===

# Your todo.txt directory
export TODO_DIR="/cygdrive/c/users/ton/Dropbox/todo"
#export TODO_DIR=`dirname "$0"`

There can easily be a problem with this. On the family laptop, for instance, my username is ‘papa’ and my Dropbox is located on the path:
C:\Users\papa\Dropbox

and the todotxt.cfg configuration line would have to read:

# Your todo.txt directory
export TODO_DIR="/cygdrive/c/users/papa/Dropbox/todo"

Do you see the problem? If you want to be able to put your todotxt script and config file on a central location, there should be one uniform todo.txt directory that is also on Dropbox.

The solution? Another mklink hack. On the family laptop, I have used the following command:

mklink /d C:\dbtb C:\Users\papa\Dropbox

Now the top of my todotxt.cfg reads something like this:

# === EDIT FILE LOCATIONS BELOW ===

# Your todo.txt directory
export TODO_DIR="/cygdrive/c/dbtb/todo"
#export TODO_DIR=`dirname "$0"`

The trick here is that if you create the equivalent directory link on all your Windows machines (pointing to your various Dropbox locations), you can use the same todotxt.cfg on all of them.

I hope this helps you enjoy a centralised Cygwin home directory and roaming use of the excellent todotxt.sh!

Comments

Reality and satire

A quote from the biography of Steve Jobs by Walter Isaacson. He writes about the parody that Guy Kawasaki had published about Apple buying Next and making Jobs its CEO, about 2 years before this really happened at Apple.

Isaacson first describes Kawasaki’s spoofed press release about the takeover. And then he writes:

But reality has an odd habit of catching up with satire

How true!

In the country I live in, the polical party the PVV is in fact the reality and the so called ‘Tegenpartij‘ was the satire.

Comments

Alain de Bottons Sermon on Religion for Atheists

Alain de Botton On Religion for Atheists from The School of Life on Vimeo.

Today, I watched this ‘sermon’ of Alain de Botton, where he teaches us to look at the good things we can learn from religions, even if we do not believe in God. This cermon was an initiative of The School Of Life which I find a very interesting discovery on the web.

Around the beginning of this school year, I attended to a presentation from the teacher of my 10 years old son about the subjects that will be a part of this years curriculum. When I asked them: “What are you going to teach the children about religion?” the teacher replied that this was a secular, public school and that for that reason, they did not teach them a lot about the different religions. I think that even if you are not a believer in all the dogmas of a religion, that does not mean that you cannot learn from the scriptures or teachings of that church. Even if you do not believe in God at all, there is still a lot to learn from religious thought, ceremonies, art and spirituality. We should teach our children that, of all the main religions, also on the so called secular schools.

Comments

Datacenters and NYC

Thanks to my Facebook friend Nico Veenkamp, I stumbled upon a video about the physical aspects of the Internet: datacenters and communication hubs. This video also features the city that inspires me: New York.

Bundled, Buried & Behind Closed Doors from Ben Mendelsohn on Vimeo.

Comments

What Level of Complexity is Real?

Last week at Tilburg University, I attended a lecture / masterclass of the MIT psychologist Sherry Turkle. (Organized by the Dutch Nexus Institute).

Fractal 1

The question that came to my mind, was not so much psychological as it was philosophical. Nature, the physical world, has many layers of detail and just as many realms of complexity. On the one hand, there are the microscopical and sub-microscopical levels. Little particles seem forever to be comprised of even smaller sub-particles. This level of complexity seems endless. On the other hand, there is the level of the stars, planets, milky way and universe. There is a countless number of stars and the universe is immense. So, at the macroscopic level, the complexity is endless to.

But even if you restrict you view to only the realm of humanity, there are different levels of complexity. On the one hand, you can have the social interactions within the family and on the other end the whole world with global trade, the Internet, global media. Life can be very simple, like the life you have in your street and the contact you have with your neighbors. Also, the contact with elderly people and children can be very simple and straightforward.

With all these different levels of complexity or simplicity in the human realm, the question for me is not which one of these levels are the reality, since they all seem to be real in their own vein. The question that I find interesting is: what is our natural level of complexity, what realm is the most relevant to the human condition, contributes most to our being?

Comments

TED talk about fighting viruses

I strongly recommend you to watch this 17″ video. It is about the enormous threat we are facing by putting all our processes online on the Internet. Cyber crime and ciber terrorism are growing and they have the funds to hire programmers and testers.

TED talk by Mikko Hypponen

Comments

Buddhist Joke

A Buddhist comes at a hot-dog stand and asks for a hot-dog. The salesman asks: “Do you want one with sauerkraut or with mustard?” The Buddhist replies: “Make me one with everything.”

Comments (1)

Mindfulness in Deer Park Monastery, California

Joyfully Together: A Day of Mindful Living from Kenley Neufeld on Vimeo.

This evening, I watched this video three times. It made me feel very happy and centered. Being a practitioner in the same tradition as the monks and nuns in Deer Park Monastery, the tradition of the Vietnamese born Thich Nhat Hanh, I recognized all the songs and rituals. I very much enjoyed a feeling of peace and wholeness.

The video is very well filmed, compliments to the maker, although in Vimeo, the maker remained anonymous.

Comments

My hero: Columbo

In the latest issue of the magazine Intelligent Life (a publication by The Economist, see the website here), Robert Butler writes that environmentalists are often irritating, because their arguments are most times one-sided communications.

Butler advises that ‘we’ (by this he means the environmentalists) should engage with others in a more humble way and try to open the conversation by inviting them to look at the issue from our standpoint. Columbo often does this by very modest way saying that ‘something’ has been puzzling him, keeping him up al night. The other person, usually a upper class murderer who thinks he can outwit this crumbly looking older man, in a kind of arrogant way complies with this invitation to look at the mystery through the vision of the detective. In this way, the millionaire killer often convicts himself, not seldom because he underestimates Columbo.

So the way that Robert Butler advizes the Greens to act more like this American-Italian police man amused me.

This week, I saw an episode of Columbo on cable. He was talking to a collegue, a forensic specialist who was working for more that 15 years on murder cases and he thought he had commited the perfect murder. Within the next 30 minutes of this episode, Columbo will get this man to admit he has killed the victim.

Columbo askes his collegue, who by then was not an official suspect yet, to visit the crime scene with him.

“I think I will go to the place again where the murder took place. Will you come with me? Three eyes will see more than one.”

Columbo

Comments

On My Reading List

James Gleick, the science journalist / author, has written and published an important book about the history of information, information theory and information flood, The Information (Amazon Link)

Picture of the book

I have read this excellent article by Freeman Dyson on the New York Times Review of Books. Dyson summarizes:

According to Gleick, the impact of information on human affairs came in three installments: first the history, the thousands of years during which people created and exchanged information without the concept of measuring it; second the theory, first formulated by Shannon; third the flood, in which we now live.

The New York Times itself has also featured a review by Janet Maslin, entitled Drumbeat to E-Mail: The Medium and the Message which added to my eagerness to get my hands on this book.

Comments