Skip to content

Git – revert or amend last commit

Since we moved from SVN to git in HeiaHeia I had to revert or amend changes I accidentally committed or committed and pushed to git repository. This is not the most common operation, so I have to browse the documentation every time I do that. This is more of a memo to myself, which hopefully will be useful to others too.

Committed some changes, didn’t push them, and need to amend the commit:

git commit --amend -a -m "Commit message"

Committed some changes, pushed them, and need to amend the commit, do the revert operation instead, since someone might’ve already used your changes.

Committed some changes, didn’t push them, and need to undo the commit:

git reset --hard HEAD^

This will just toss away the last commit completely.

Commited some changes, pushed them, and need to undo the commit:

git revert HEAD

This will automatically create a new commit, reverting the changes from the previous

Share

Web hosting for internet startups

A lot of companies launching their own internet services have faced the same question – where to host. Over the course of the last few months I was asked for opinion on this matter several times. While I have no definitive answer, here are some recommendations.

Don’t start with maximum capacity, start small, and think about scalability – how fast you can do it, and how you will do it. Then map the plans to what your selected hosting provider offers. Avoid temptation to use your own hardware, unless you really have resources for administering and maintaining it and a real need to have physical access to the servers. Even companies using their own hardware use virtualization to run virtual machines on top of physical ones.

Two years ago, when we were just experimenting with ideas of the social training log, a shared hosting option on Dreamhost gave us the best prices/features/quality combination. When we launched first closed version of the service named Moozement at the time, we switched to Dreamhost VPS, which allowed enough flexibility and had reasonable pricing. For HeiaHeia (Moozement beta version) we’ve chosen Linode, as it offers Xen virtualization (as opposed to Dreamhost’s VServer), servers with up to 14400Mb of RAM, easy resizing, wide selection of Linux distributions, and several data centres to choose from, including one in London. As HeiaHeia grows, we are preparing for the next step, but for now Linode proved to be excellent choice.

If your company is based in EU, you also need to remember about EU Data Protection Directive – your servers need to be physically located in one of the European Union countries or in the US with a provider following Safe Harbor Principles.

If you have no clue about how much CPU/RAM/traffic your application will need – check reference cases – there are plenty on the internet. Here are just a couple of examples: social network Ravelry and Facebook app Friends for Sale.

Want second opinion? Check these:

  • Eivind Uggedal has a very thorough comparison of Slicehost, Linode, Prgmr, Rackspace and Amazon EC2 pricing and performance and arrives at a conclusion that Linode gives you best bang for the buck.

In case you decide to use Linode, use this referral link to give us some reward :)

If you’re planning to host a low traffic service, and don’t want to spend much time on system administration – Dreamhost is a great starting point. And as I already wrote earlier, Dreamhost provides excellent value for money. If you are looking for a good hosting – use IVANKUZNETSOV promocode and get a $50 discount when setting up an account on Dreamhost.

Share

HeiaHeia – probably the most fun way to keep fit!

Wow, what an autumn it has been! It has come and gone so fast. By Christmas 2009 a major milestone was reached – Moozement moved from Alpha to Beta phase. Most of my time and efforts went into development of the service – and it was exciting time of super intensive work in a small, but very dedicated team.

Beta version brought with it new professional design, easier to use interface, new interaction concepts, new sports, new faster servers.  We decided to change the name of the service as well and were inspired by a hypnotic Heia! Heia! chant that Norwegians use to support their cross-country skiers and other athletes. We named our service HeiaHeia to give it a spell of positive cheering among friends.

Sports and wellbeing are hot markets both regarding hardware and web service innovation. HeiaHeia’s focus is on the social aspect of sports – mastering the ways in which friends can motivate each other in a positive spirit, without being overly competitive. The difference between us and most of the other players is that we want to provide a service which anybody can use. You don’t need any kind of technical gear to use the service, and the service itself is as easy to use as Facebook.

The HeiaHeia philosophy on sports is that everything counts. HeiaHeia already supports over 250 different types of sports, most of them requested by users of the service. Understanding user behaviour and user requests will remain a guiding principle in the development of HeiaHeia.

Work doesn’t stop here, and new functionalities will be introduced on a weekly basis going forward, in a true Web 2.0 mode of development.We are looking forward to a very exciting year ahead.

Share

Agile distributed team – using chat to run scrum meetings

The current development team that I’m working in is really small – just 2 software gurus, a product owner and me as a scum-master/system admninistrator/part-time developer/architect.

Our team is distributed to the extent that sometimes all four of us are located in different places during our meetings – but time zones difference is in most of the cases withing 1-2 hours. Up until recently some of us didn’t have a permanent office and had to participate in daily scrum meetings, and sprint planning/reviews from public open spaces. (Continued)

Share

Upgrading iPhone firmware using VMWare and Ubuntu 9.04

This was the second time I upgrade firmware on my iPhone, and second time I ran into the same problem.  In the middle of the update iTunes reports “Unknown error” and iPhone dies (well, goes into recovery mode, but it is not much help). If that happened to you, don’t panic! To make this geeky combination (Ubuntu 9.04, VMware, iTunes and iPhone software update) work, there’s a little trick you need to do. (Continued)

Share

Setting up Ruby, Rails, Git and Redmine on Dreamhost

Git, RedMine, Ruby, Rails on DreamhostThe task is to have:
- Redmine installation on redmine.mydomain.com
- Several Git repositories on git.mydomain.com with different access rights to each one

This proved to be a non-trivial task. There is a number of tutorials on the net, but none of them described the full solution. So after getting it all to work, I decided to share all the tips and tricks. Feel free to comment, if you will find problems with the following set of instructions.
(Continued)

Share

Migrating domain emails to Google Apps mail

logo While performing some administrative tasks on one of the domains I maintain, I decided that the time has come to switch to a modern and reliable solution – Google Mail.

If you have an IMAP mailbox hosted somewhere and you want to move it to Google, then do the following (example is set for migrating from Dreamhost, but can be used on any other IMAP mailbox):

1. Register at Google Apps for your domain

2. Re-create your email accounts

3. Log in to  shell on your hosting and execute the following command:

 mailutil transfer -verbose -merge append \
   '{a1.balanced.<your-dreamhost-mail-server>.mail.dreamhost.com\
   /imap/ssl/novalidate-cert/user=<your-dreamhost-username>}' \
   '{imap.gmail.com/ssl/user=<your-gmail-username>}'

<your-dreamhost-username> is the name you use for logging into your existing IMAP mailbox – e.g. info@mydomain.com
<your-dreamhost-username> is the name you use for logging into your Gmail account (just username if you’re migrating to @gmail account or username@domain.com if you’re migrating to Google Apps account

4. Enter first password to your existing IMAP account, then password to your Gmail account

5. Voilà – prepare that this can be a long running operation, especially if you have a lot of mails.

(Thanks to joyjit for advice)

Share

ArcticStartup on Moozement

moozementdevsVille Vesterinen from Arctic Startup published a nice and encouraging piece on Moozement. The observations on what Moozement is, what it’s most useful for, the current state of development (early stage, but we very much believe we’re onto something), and the direction of future development, very much resonate with our own thinking. There’s also a video interview with me ;)

Share

Adopting an Agile Mindset

postitsThere are a lot of books written about Agile. One can easily spend hundreds of euros on books and thousands on training courses. Sure, if your organisation has time and money, it makes sense to stockpile books and send entire development team for training courses. From my experience, what it really takes for a team to adopt agile mindset is an evangelist inside the team, and a good understanding of the basic concepts. Then it is just talking to the people who went through similar experience of adopting agile, sharing experiences and experimenting.

There are three very informative and inspirational sources of information that I recommend to all teams starting with agile or looking for some extra motivation:

1. Henrik Kniberg’s “Scrum and XP from the Trenches” (http://www.infoq.com/minibooks/scrum-xp-from-the-trenches). Available as free PDF after registration.

Extremely good source of information, tips and tricks, pitfalls and how to avoid them, planning ans estimation techniques. Henrik is speaking out of his own experience, which makes this book extremely valuable. You can read this book in just a few hours.

2.Ken Schwaber’s talk “Scrum et al.” at Google

Ken is is a founder of the Agile Alliance and Scrum Alliance, and signatory to the Agile Manifesto.

One hour of valuable information – and hopefully after watching this video you will not try to adopt agile and scrum where it is going to do more harm than good.

3. Agile Manifesto (http://agilemanifesto.org/)

Print it out and pin it to the wall, so you can see it every day. Doing Agile and Scrum “by the book” never works – there’s no book that can tell you what the process should be. Not only because each team has its unique qualities and each organisation has its own constraints, but most importantly because agile is all about changing the process with every iteration – improving it and adopting to the changing reality.

Share

Choosing Mobile Development Platform

mobileplatformThere’s been a lot of heated discussions in the blogosphere in the past month about mobile platforms from independent developer perspective. Which platform to choose, if you want to develop cool applications, reach a lot of users and maximize your revenues?

I previously wrote on this subject a year ago, when Android was announced, and three years ago, when I was really disappointed by a pretty much dead S60 applications market.

This time it started with a great presentation by Teemu Kurppa (a mastermind behind mobile Jaiku) at MobileDevCamp Helsinki – “Platform = Stage. How to choose a mobile development platform?“. It is a must see for every mobile developer.

(Continued)

Share