Edit with Notepad++ without Admin access

I got a new machine at work and promptly installed Notepad++ through the software management tool that the office provided.
Notepad++ installed fine but the right click context menu option “Edit with Notepad++” was missing. I raised a ticket with desktop support team, they tried but were unsuccessful.
Quick google search provided some options like running NppShell.dll or adding registry to HKEY_CLASSES_ROOT. However these require Administrator access that I didn’t have.
I looked around, couldn’t find any solution so crafted my own to add the “Edit with Notepad++” option to all files without admin access.

Step 1. Go to Start and type regedit.exe

Step 2. HKEY_CURRENT_USER\Software\Classes\

Step 3. Right Click on Classes and create a new Key valued *

Step 4. Right Click on Classes and create a new Key valued shell
Step 5. Right Click on shell and create a new Key valued ‘Edit with Notepad++’
Step 6. Right Click on ‘Edit with Notepad++’ and create a new Key valued command

Step 7. Change the value of Default to the path to notepad++.exe file (‘C:\Program Files\Notepad++\notepad++.exe’ in this case)

You can download the registry file here. Edit file, correct the notepad++ path, save, close. Double click, say yes. and you are all set.

Why it works?
1. Most solutions out there ask you to change the HKEY_CLASSES_ROOT which requires admin access however we are changing HKEY_CURRENT_USER. It is the current user’s profile thus admin access isn’t required
2. The keys in HKEY_CURRENT_USER\Software\Classes\ are actually extensions, we created key * meaning any extension.

Hope this helps.

Simple Snake game in Jquery

There are several tutorials on the internet to create simple snake game in query. I readh through https://www.sourcecodester.com/tutorials/javascript/11260/creating-very-simple-snake-game-using-jquery.html and decided to enhance it.

The new code has following advantages over the original one:

  1. Added pause and play option
  2. Once the game ends, stops play. Original code just restarted the game
  3. Changed the position of game name and score
  4. Replaced absolute font size with relative sizes.

I created a github and uploaded the code for this simple game. You can also play it here

Tragedy in the bathroom

There are so many crazy people around the world. They keep crocodiles and snakes as pets. Have you heard of the cases where these animals escape and enter neighbour’s houses through plumbing? That is through bathroom pipes.

In this story, my character suffers from Ophidiophobia i.e. he fears snakes. He fears it so much that even the thought of snakes freeze him.

It was as if google knew he feared snakes and if any news of snakes in apartments, flats, houses or cars happened in any part of the world, it would be present in his google news feed. And as you guessed, he froze every time this happened.

Here are some articles he had read over the time but remembered vividly.

  1. Toilet snake caught link
  2. Crocodile falls 12 floors in escape bid link
  3. Woman finds snake in apartment bathroom link
  4. Tenant Sleeps in Car After Spotting Snake in Apartment link
  5. Woman finds large snake in apartment link

Then there were news of snake catchers leaving snakes at politicians because they were being politicians i.e. were not heeding to their demands.

Well the story starts with the bathroom as you may have understood from the title.

The bathroom in the question was second bathroom in the apartment so was small. It was 6 ft by 4 ft which amounts to 24 sq. ft., considerably smaller than the 40 sq. ft. bathroom that were created in North America back in the 1980s. Well this wasn’t North America and it definitely wasn’t 1980. With more tree cut down and more space to live, somehow the space was shrinking.

Yeah, yeah, I am off topic again. I tend to ramble. If you don’t like the way I tell my stories, you can go somewhere else.

OK. OK. I am sorry, please don’t go anywhere, my website’s traffic is already negligible. I can’t afford you leaving too.

So back to the small bathroom. The door faced West, there was a window 1.5 ft by 2 ft, on the East wall. Bathroom door, 2.5 ft. in was the commode, white, simple, nothing fancy. 1.5 feet in was a divider, 4 inches high marble piece put in place to stop water from bath area to flow to rest of the bathroom. And lastly, 2 feet of bath area. A simple shower and a geyser.

The geyser worked pretty well, by the way. Not that it matters in this story. Just telling.

If you are wondering if where the wash basin was, it was outside the bathroom, next to the door. (Nice one catching that miss and just like the geyser it doesn’t play into the story)

Normal day, this guy wakes up, uses the toilet facilities. Goes back outside, brings his clean inner wears and a white towel with blue lining around the edges. Quite cheap but it did the job.

The yellow tiles of the bathroom made it really difficult to give this bathroom a clean look. “I should find a new house”, thought the character. There was no way he would find any other place to live in, he was too lazy to look for a place. He found this place because someone he knew was leaving.

So he takes all his clothes off, puts them aside. Turns the shower on. He closed the windows, didn’t want anyone peeping. Not that it was any use, no one in their right mind would want to peep at him and the window faced a solid wall, nowhere to peep from.

Getting there, be patient.

After a couple of minutes of fidgeting with the hot and cold knobs, the temperature was right. “The taps should remember the temperature setting”, thought he. Shampoo on head, soap on body. Water was wasting away, not that it mattered. Room was steaming up.

He turned around for no apparent reason. His worst fears were to come true. Something was crawling up the commode. It couldn’t be true, he squeezed his eyes. The thing was sliding off the commode and coiling on the floor of the bathroom. It was a snake.


It landed next to the commode, just 2 feet away from my (ahem) naked character covered in foam and shampoo. First it looked towards the door. Seeing no opening, it turned around, looked at the window then turned towards him.

He had frozen long ago or so he thought, in reality he was shaking furiously. These were enough to attract it and its cold eyes fixed onto him. His heart is throbbing, pumping really hard, as if it had to complete all its life’s remaining pumping action in the next 2 minutes. He would surely die of heart attack.

One second passed, neither moved, two seconds, three seconds, four seconds. His frozen brain was starting to reboot.

“What could I do?”

“Can I run out of the room? But I am naked. Don’t worry about that, there’s no one else here. But wouldn’t it bite me if I move towards it?”

“What snake is it? Is it poisonous?” – Yes, our character isn’t that smart, snakes are venomous not poisonous.

By the way, the snake was a 4 feet long beautiful creature with a triangular flat head and bright chain like patterns on its back in packs of threes. Smaller on sides and large ones in middle. It was brown, had a distinguished neck and a white underbelly. In other words, it was a Russell’s viper. It kills more people in several countries than its more famous cousin, the black cobra/king cobra. But somehow, it never became too famous. Don’t worry, the character would never know what snake it was. Neither would he know that it was supposed to be stored at a facility that milks its venom for diagnosis of lupus anticoagulant, a disease he suffered.

It was miraculous how it had escaped though. A rodent had unwittingly made a hole in the ground. The milker had stepped and cracked the tile above the hole. Another had forgotten to lock the cage properly because his wife was nagging him on the phone to get a new snake skin bag. The snake on its part was no smarter, it had by mistake slid out of its box, crawled towards the broken tile, ate the rodent and reached a broken sewage pipe. Crawl and crawl it did, reaching finally a break in the pipe which connected it to septic tank pipe. They were both broken when a over weight truck had driven over this road. What no one knew was the gas pipeline next to these pipes had also developed a small crack, thus giving a gassy smell to all bathrooms nearby.

Meanwhile, the snake found a vertical pipe, it slid up and up; reaching not the first, nor the second, nor the third but the fourth floor. Finally, seeing a bright light up a commode. The commode was difficult to manage, it was slippery but it managed.

“Open the window and jump, but I am naked and 4 floors up. Also, by the time I open the window and climb onto it, the snake would have bitten me”.  – He was correct here though, Russell’s viper can bite from up to five feet away within seconds. Unlike most snakes that sometimes bite dry i.e. bite without releasing venom, Russell’s vipers on the other hand mostly bite with maximum doses.

“May be its a python and wouldn’t be venomous, but it would still take a bite, coil and strangle me.”

“Is it how they will find me? Naked, covered in sweat and soap, bitten by a snake, dead in the bathroom”

All his life flashed by him. His thoughts to do good for the poor, start a new company, become the next Steve Jobs. No not Steve Jobs, he wanted to become Steve Wozniak but with lots of money. As if these two things were different. Were all his dreams gonna come to a sudden end?

P.S.: I couldn’t find if a Russell’s viper can stay long under water, however most snakes can swim.

The ice cream parlour

Several years had passed since the last time he had paced these paths. It brought back sweet and sour memories. Felt as if something was missing, the anguish was taking over.

Walk past it. It’s just nostalgia of this place, it will pass away.”, he lied to himself.

Nostalgia, a painful but beautiful word. Originating from Greek nostos (return home) and algos (pain). He was in pain that he had to return.

Treading the path, he saw that ice-cream parlour on the left. The place it had started all those years ago. A place full of cheerful people in groups of two or three. A place for budding friendships and love.

Love another awful word. Would you believe me if I said the word love shares root with Sanskrit lubhyati meaning desire? It could be lubhati in Hindi. So is love just desire, the need to have someone or something. Is the concept that love is above desires just another lie, just like her promises?

The beautiful vinyl wallpapers of orange had faded away. The place was empty, a staff hopeful on seeing him looking at the parlour. But he walked on.

So the place, where it had begun, had begun to wither away just like his love, the hopeful eyes of the staff reminded him of the hope he had that they would be together. They knew every moment they were together was just like stealing moments from someone else’s life. It was doomed to end this way, no amount of hope could keep them together. The world was acting against them.

He moved on towards the new place he had rented. If only I could have lived somewhere else, somewhere far from memories that were too painful to keep in the heart. The souvenirs of old aches and wounds were coming back.

He had to move on, walk past this place so often, he could learn to live with it.

Next time he walked past the ice-cream parlour, he kept his eyes straight. I am not going to look at it, pretend it doesn’t exist, pretend nothing happened.

And he walked past that place several times. One day he observed the place was under construction. So the place had died out just like his love.

Something new was to open up, something that will bring others closer and no one would remember that old ice cream place. No one would miss it.

Wonder what is going to open up.

A few days later, a donut place opened up. He got a coupon, buy one get one free. He had to go, he wasn’t going to miss this chance. Will he meet someone to share the free donut with? Is that what this new place brings?

Time Travel, should I?

After years of dedicated work and being labelled a loon, I have invented the machine that will displace my body through time. Historically we have been taught to think of time as something passing. To quote the movie “The Man From Earth”, moving from what you were a nanosecond to what you will be a nanosecond later.

I have a great dilemma, should I now use this machine to travel through time or not. What are the implications of using it and what losses if I don’t use this invention.

On one hand, I have no idea where I will end up or when. My calculations make sense but will they be accurate enough?

What if I do travel to the past and somehow I contaminate not just the time line but also the environment. I have faced so many diseases and have been vaccinated several others, what if I carry the pathogen to the past and the people there are not immune and all die. Remember the Columbian exchange that wiped out large percentage of native Americans? How badly would that contaminate the time line.

Same thing could happen if I travelled to the future. I may travel to a place where all diseases that I carry were eradicated long ago and no one is immunized against them anymore. Like no one gets smallpox vaccine anymore. Lot of people would perish.

And what if I don’t use the machine and I was supposed to. What if I was to carry and leave behind strange cells of diseases roaming in my body and affect the way earth’s ecosystem grows. But what if I was the one who introduced life on earth or pass on the disease that will kill a small percentage of people and immunize the rest of the world against it.

What is the price of my using the machine?

I am not acting nervous for no reason. Remember the earth is running around the sun. The sun is on the journey around the center of the galaxy and the galaxy is going god knows where. What if there are things I don’t know and I end up in a time where earth is at a different location in space. My blood would boil away in the vacuum, there is no return from that.

What should I do?

Got cheated at CCD – True story

#CCD #incorrectBill order at #InorbitMall, Link Road, Malad, Mumbai. We ordered 2 Cafe Latte (small), 1 Irish Coffee without cream and a chocolate fantasy. CCD charged Rs. 615. We requested a bill on payment and we were assured the bill would be sent with the order.
We discussed among ourselves that the bill amount sounded higher than expected.
Order arrived, two small Cafe Lattes, one Irish Coffee and chocolate fantasy. We asked for the bill again. Both lattes and the chocolate fantasy were served cold. We requested they be heated and asked for the bill again.
A moment later the items were brought to our table. We reminded for the bill again.
We had requested for the bill four times so far. After two to three more requests, the staff said they had misplaced the bill.
We asked how they could have misplaced the bill. We were adamant about the bill, we said we didn’t care how they brought the bill but we needed the bill.

After two more follow-ups, someone from the staff brought two order slips containing our order but no bill. On closer examination, we saw the staff was trying to mislead us. The slips had different order numbers and had time difference of an hour between them. I have attached the pic of both these slips.

If you look closely, first slip has two cappuccinos and an Irish coffee at 19:30, order number 30, table number 0501 while the second slip had 1 Choco fantasy new at 20:51, order number 100, table number 0101. We had arrived at around 20:00. This was a blatant case of lie and cheating. This couldn’t be a case of human error, when the staff wasn’t providing the bill and the slips had different timing.

We asked the manager again for the bill. He said the system didn’t have an option to print duplicate bill. Being software engineers ourselves, we thought that was stupid. After this, two of us went to order counter again and asked the manager to recreate the order and cancel the order before payment, so they could check the amount. He punched in something and they saw the number 615, however they couldn’t read the order properly as the monitor was at an awkward angle. “The staff wouldn’t cheat us and dare to show the wrong order”, they thought. They came back saying they had seen 615, but not the order. It still looked fishy, even with the tax the amount couldn’t be so high, we had checked Zomato for the rates and we had calculated tax at around 21%.

So we went and asked for the bill again, the manager said, “sir, the system doesn’t lie”. But we didn’t budge, we want our bill.

He asked us to be seated and he would find the bill. Then he saw him leave silently. A few moments later, we could see the staff shuffling through a pile of bills and pulling our bill from among them. And it was brought neatly to our desk.

Here comes end to the mystery on how the amount was so high. We had been charged for two Vanilla Lattes – large instead of two cafe Lattes – small. The extra Rs. 90 and tax put things together.

We asked for the manager, the other staff said he had gone out for a moment and would be back. We waited and inquired again. Waited some more.

Then another staff came with a note of Rs. 50 and some change coins and asked us to take the extra amount we had been charged.

We refused. It wasn’t about the Rs. 100 more that we had been charged, it was about the principle, it was about the malafide intention of the staff. It was about reducing the cool bunch of us out to enjoy an evening into a quarrelling bunch at a mall. It was about the faces other customers made at us when they saw us sternly speaking at the counter. It wasn’t about the money.

We went to the counter and requested for the manager again, “he is coming”, was the response we got, again and again and again. 20 minutes passed, with no sign of the manager.

The other staff claimed they didn’t know the name of the manager. One staff however said the name was Makdum.
We called the CCD customer care and got a complaint number 88484 in SMS, a phone call sometime later. A request to got to the nearest CCD for refund of the extra amount charged and a promise for a follow up call on written apology. It has been two days and no response from CCD so far.

What reason would a manager have to make a bill with higher amount? The extra money wouldn’t go in his pocket, he probably cannot sell the other item anywhere. At first, I thought may be the franchise owner asked the manager to charge extra but the CCD at Inorbit mall is a direct shop and not a franchise. So next question is whether CCD has this policy at the company level.


Setting up xdebug on scotch box/vagrant on Arch linux

Install Vagrant

sudo pacman -S vagrant

To install virtualbox

mkdir works

git clone https://github.com/scotch-io/scotch-box.git works

cd works

vagrant up

install sublime 3

install package control on sublime 3


install openssh

vagrant ssh
sudo apt-get update
sudo apt-get -y install php5-dev php-pear build-essential
sudo pecl install xdebug

copy the xdebug.so location
you can also find it with find / -name ‘xdebug.so’


in /etc/php5/apache2/php.ini

; Added to enable Xdebug ;
zend_extension="[enter path here]"
xdebug.remote_host= ; IDE-Environments IP, from vagrant box.

sudo service php5-fpm restart
sudo service apache2 restart

refresh phpinfo to check xdebug

in sublime -> tools -> command pallete

install package

xdebug client

Project -> Save project as

"path": "/home/username/works/public"
"settings": {
"xdebug": {
"url": "",
"port": 9000,
"path_mapping": {"/var/www/public/" : "/home/username/works/public/"},
"super_globals": true,
"close_on_stop": true

Fixing Sony MDR-XB400

Recently I sat on a Sony MDR XB400 Stereo Headphone. One side of the headphone popped out of the socket.


Below are the steps to fix the issue.

Wedge a screw driver below the silver cap and push to remove the silver cap.


A screw will be visible. Remove the screw.


Put the pieces apart


Wedge the screwdriver at the base of the holder to remove the cap.


Here is the cap is removed.


Once the cover is removed, slide the holder onto the headband.


Stick things back and screw it tightly.


Replace the silver cap back.

One thing to keep in mind is to keep the wires straight, you don’t want them looping.