Remove ^M from file in unix file

May 10th, 2008

This note is dedicated to my chubby hubby that keep asking me how to remove ^M in a file.

UNIX treats the end of line differently than other operating systems. Normally CTRL-M character is visibly displayed at the end of each line as ^M if the file is not transfered in binary mode (this is why I always prefer SFTP instead of FTP).

  1. In vi, to remove the ^M do as following :
  2. :%s/^V^M//g

    ^V is a CONTROL-V character
    ^M is a CONTROL-M.

    So it will look like this:

    :%s/^M//g

    %s is a basic search and replace command in vi.
    The g is use for search and replace globally (all occurrences).

  3. with Solaris you can just do (heard HPUX has the command “dos2ux” instead of dos2unix):
  4. dos2unix <dos file> <unix file>

  5. You can also use the octal representatiion of ^M:
  6. tr -d ‘\015\032′ < file

Jakarta Day 3

May 9th, 2008

I was busy with training and normally by the time I reach hotel it would be 6:30 or sometime 8:00 pm (here at 6:30 it very dark). Don’t really snap any interesting stuff. Went to 2 shopping mall but the price is too expensive for me. I don’t wear jimm choo shoes … I wish I can have a pair but I know where I stand with my current salary I can’t afford to spend that amount of money on pair of shoes … Buy a pair of batik for mom .. hope she like it …

From KL to Jakarta

May 6th, 2008

I was bored while on the flight. Tried asking Lan to join me but he can’t it. Apparently he got work that need to be done ASAP. I got aisle seat so can’t snap the cloud. I snap a few pic while in plane and that about it. Stayed at Hotel Mulia Senayan. The room is huge :-D.

Malaysia Airlines (MAS) everyday low fares offer.

May 4th, 2008

I was watching Buletin tv3 and heard special announcement from MAS Managing Director and Chief Executive Office, Dato’ Sri Idris Jala. Starting from May 5, 2008 (tomorrow), MAS is going to offer low fares (up to RM0 fares). He also mention that MAS gonna put at least 30% of the seat to have these special low fares. What the catch? well basically you have to :

  1. Go to http://www.malaysiaairlines.com (the offer is only valid via online)
  2. Book a flight at least 30 days in advances
  3. The booked flight ticket cannot be changed or refundable.
  4. Booking period : May 5 - 19, 2008
  5. Traveling Date: 10 June - 14 Dec 08 but blackout dates apply.

Dato’ Sri Idris Jala also informed/announced that MAS gonna give this kind of offer to ASEAN country soon (Can’t wait for it). He stated that those that bought the special low fares seats still entitle to other MAS in flight services (food and etc).

NOTE: You may find our Everyday Low Fares listed under the Super Saver column within the
Online Booking page when performing your flight search.

Let’s login to MAS website tomorrow and grab these special offers. May be hubby can book a flight for us to Bali (hint.. hint …) as we plan to go end of June.

http://www.malaysiaairlines.com/ELFZERO/fares.htm

Dato’ Sri Idris Jala open letter read (form MAS website) :

Dear Malaysians,

I have an important announcement from Malaysia Airlines.

Everyday, and all around us, we are all feeling the pinch of how everything is getting expensive. We, at Malaysia Airlines, have decided that it is time we lowered our fares so that Malaysians can continue to travel.

We recently declared that Malaysia Airlines is transforming into a World’s Five Star Value Carrier and we promised that you will be able to enjoy 5 Star Service at a low price. Many people thought it would be impossible. Well, not anymore! Today we are ready to deliver on that promise.

LCCs operate by keeping their costs really low and passing some of these savings to passengers. But this means that passengers have to accept some sacrifices.

We believe there is a way for passengers to enjoy low fares and Malaysian Hospitality.

For the first time in our history, Malaysia Airlines is offering Everyday Low Fares. From the 5 th of May, we will offer zero fares on all our routes within Malaysia. Later we will offer very low fares on our regional routes within ASEAN. We have put aside up to 30 per cent of our seats for these special Everyday Low Fares.

To get these special fares, you only need to take 3 steps:

Step 1: Go to our website at malaysiaairlines.com as these fares are only available via the internet.

Step 2: You must buy the ticket at least 30 days before flight departure.

Step 3: Remember these ticket are non-refundable and the flight dates cannot be changed.

What we are now offering gives everyone a win-win situation. It helps us to meet our business objectives. And it provides our customers an excellent deal – you get to enjoy the best of both worlds – really low prices plus our 5 Star services – our food and beverages, entertainment, luggage allowances and other benefits that come with traveling on Malaysia Airlines.

I would like to personally invite you to click on malaysiaairlines.com

Yours sincerely,

Freedom with responsibility

April 30th, 2008

I have an option to work from home which allows ‘work’ office to be in my home. I got flexibility to manage my work hours and work places. I know I should be thankful for this benefit but for some reason whenever my manager called me, I felt guilty. It’s not like my manager don’t allow me to work from home but for some reason I don’t feel comfortable answering "where are you?" when he called me.

I love working from home. I can have lunch with my chubby hubby who work 15 min from home and wear what ever I want. Turn on the radio or even play mp3 loudly on laptop.

Some people might abuse work from home option by going out shopping and etc…Some of my colleagues don’t seem to have problem to be online only till 5:00pm and stop answering their mobile phone after 5:00. They don’t feel guilty as they claimed it’s their right. I tried to do the same but end up feeling guilty.

I feel that I work longer hours when I’m at home. I don’t know why but I seem to have problem switching off my office vpn and laptop even after 7:00 pm. If I’m working from most of the time you would see me online on my office network till 11:00pm.

I know I can also opt to go to office and do my stuff there (like my previous job) but I hate:

  1. drive to office
  2. stuck in jam a
  3. make a few round in car park (hard to find parking)
  4. eat fast food

Work from home = freedom with responsibility…