Saturday, January 2, 2016

Hiking to Champadevi




TL;DR

Link to all the pics

If you have a day or two to spare then this is definitely not where you want to go, I would rather suggest Chisapani but if you have some 7 8 hrs and  looking for adventure then you can choose to hike here. While the route has some awesome views to offer , there is nothing interesting once you reach the Champadevi destination. At the top, it is just filled with garbages. I rate it 2 stars out of 5, 2 because of the trail and view from the trail. If you have decide to travel alone then try to take the trail from hattiban resort, the one I hiked is very dangerous as local people hurl huge rocks from the slope, I still do not know why.


Just as I woke up in the lazy saturday morning I decided not to sleep anymore and go on a hike. It had been a while since my last hike to chisapani, so yeah I wanted to travel again. I filled my bag with two bottles of drinking water, two apples and two bananas. On the way I bought some cakes from the bakery and stuffed it into my bag and I was ready , get set, go for my hike.


I boarded a bus to kritipur from old buspark at around 9am. I reached kritipur and started my hike from there, later I found out that there were other ways to get to champadevi too. Since I had no idea about the direction I kept asking fellow shopkeepers about the route in every turn I made.


 I met this good ol` fellow who took me up to the point where I should have actually started my hike, his house was on the way too. It was so great to know this ol` man`s story which I would have never known if I had not left the bus at kritipur. I would say that the best thing about traveling on foot and alone is getting the chance of socializing with peoples around you.


I climbed the first hill and to avoid the main path I decided to find my own shortcut and I did. I was looking for shortcuts so much that I nearly took the wrong trail and it happened two times.


After an hour walk I finally reached the picnic spot where I smoked a medicinal herb. I was high most of my travel from then. There is this endless staircase up to champadevi from the picnic spot which seems as if it stretches to heaven.

Other thing I would highly suggest is that carry some salt if you have decided to travel in summer or in monsoon. Most of the trail through the jungle is so moist and damp that it is the perfect place for leeches.



Once you reach the second phase of trail you will find it really amazing. There is another stone paved trail extending from Hattiban resort which looks just amazing and the view of mountains too.








While the view of mountains is not as clear as from chisapani, it is still exciting to see them. I love the himalayas :). I was hoping for something awesome to see at the top but there was nothing impressive. The place is filled with tons of garbages and again garbages. I was very disappointed. This will be my first and hopefully the last hike to champadevi.

Due to the blockade and the price hike in EVERYTHING, I am not able to travel on a budget. I will be surely  trekking to Annapurna Base Camp at the end of falgun so I hope until then the crisis would be resolved.

Tuesday, December 1, 2015

Automate creating vhost and installing new rails project



A programmer must learn to automate mundane and iterative tasks to save time. Many technical and non technical people have understood the true power that can be achieved by automation.

I create personal vhosts for each different project, so I had certain tasks to follow every time when I would encounter something like this. Some months ago I wrote a ruby script that does all this. It reads the content of your vhost file in /etc/vhosts and creates a vhost and new rails project for each of those domain.

Link to Alchi_vhost

Friday, November 27, 2015

My super power of forgetting password let to "Reveal Password" chrome extension


People are different because each of them possess certain unique capabilities and I am no different. I have this unique ability of quickly forgetting my passwords. Oh heck, who has the time to remember passwords, right? You can save your passwords and this feature is already provided by most of the browser and what I meant by "most of the" is chrome and firefox. They are the only two browsers I use and I have no idea for the rest, I am sorry.

It may be very weird to hear that I can not remember my password and I call myself a programmer. haha, common guys it is weird right?

So ya that is my super power and I do not want to show my super power. Just as batman wears a cape and mask and changes his voice I too had to do something to hide my power. Out of all the things in the world all I am capable of doing is coding. So instead of sewing cape and a mask and putting on a hoarse voice I decided to write a chrome extension that would reveal my password. Hey do not get excited, it is nothing fancy because I chose not to wear my underpants outside my costume.

Ok like I have already said, browsers already have a built in function to save the password if you let it to and it will remember that very specific password for that specific site. But the catch is the password field is unfathomable.

What if you had saved all your passwords in your chrome and you browsed firefox? If you are like me, we should be friends, no lets be best friends, you are screwed. But as I know some tricks like opening a inspector and then blabla that is very tedious to do every time plus if you do not have knowledge of inspector tool then you are really screwed.So ya at this situation, you can use my extension and then just like the batman coming out of nowhere,  baam, boom, kapow, no more dots in your password field. You can now know what was you password and live happily ever after.

Well I am still looking for a princess so my story does not end there. I use VC`s a lot and stupidly and indolently I avoided adding ssh keys. So yo know I had to go to the main site , then logout and then check through my inspector and then log in again.Well, now no more.

Here is a link to the codebase .
Download the extension here

Thursday, November 26, 2015

Why I moved from capistrano to mina to deploy my app?


To be honest, I have just started to use deployment tools because doing the same thing over and over again was getting very tedious for me. I first started with capistrano and it was good I guess.

Why I prefer Mina over Capistrano?

While Capistrano is a really really great tool , it is terribly slow. Since time is money for every one of us, I wanted a tool that would not be so painfully slow and easy to use, you know , that get shits done. Then I met Mina and instantly fell in love with it when I browsed its homepage and read its slogan "Really fast deployer  and server automation tool" .

Before I was using any deployment tools I was manually ssh`ing into my server and then cloning the repo from the git then running bundle install , rake db:migrate and a lot of stuffs that is not very interesting to do repeatedly. If I had pushed any new updates to the repo I would have to ssh into the server and do the same thing which is time consuming as well as not very productive. So I highly reckon anyone who is not using deployment tools to use it and feel its power. But remember Great power comes with Great responsibility. :)

It is dead simple to get started with Mina. All you have to do is add a gem run the bundler, create a deploy.rb file , fill the right info in it and running mina deploy. The best part is you can write rake tasks in deploy.rb.

Either run gem install mina or add mina gem in your gemfile.
Run bundle install if you chose the later option.
run mina init in your working directory
Here is my deploy.rb file
require 'mina/bundler'
require 'mina/rails'
require 'mina/git'

# Basic settings:
#   domain       - The hostname to SSH to.
#   deploy_to    - Path to deploy into.
#   repository   - Git repo to clone from. (needed by mina/git)
#   branch       - Branch name to deploy. (needed by mina/git)

set :user, 'ubuntu'
set :domain, 'www.fuitter.com'
set :deploy_to, '/usr/share/nginx/html/fuitter'
set :repository, 'git@bitbucket.org:mc_cannibal/fuitter2.git'
set :branch, 'master'
set :forward_agent, true

# Manually create these paths in shared/ (eg: shared/config/database.yml) in your server.
# They will be linked in the 'deploy:link_shared_paths' step.
set :shared_paths, ['config/database.yml', 'config/secrets.yml', 'log']

# Optional settings:
#   set :user, 'foobar'    # Username in the server to SSH to.
#   set :port, '30000'     # SSH port number.
#   set :forward_agent, true     # SSH forward_agent.

# This task is the environment that is loaded for most commands, such as
# `mina deploy` or `mina rake`.
task :environment do
  ruby_version = File.read('.ruby-version').strip
  raise "Couldn't determine Ruby version: Do you have a file .ruby-version in your project root?" if ruby_version.empty?
 queue %{
   source /home/ubuntu/.rvm/bin/rvm
   rvm use #{ruby_version} || exit 1
 }
end

task :setup => :environment do
  queue! %[mkdir -p "#{deploy_to}/#{shared_path}/log"]
  queue! %[chmod g+rx,u+rwx "#{deploy_to}/#{shared_path}/log"]

  queue! %[mkdir -p "#{deploy_to}/#{shared_path}/config"]

  # Add the repository server to .ssh/known_hosts
  if repository
    repo_host = repository.split(%r{@|://}).last.split(%r{:|\/}).first
    repo_port = /:([0-9]+)/.match(repository) && /:([0-9]+)/.match(repository)[1] || '22'

    queue! %[
      if ! ssh-keygen -H  -F #{repo_host} &>/dev/null; then
        ssh-keyscan -t rsa -p #{repo_port} -H #{repo_host} >> ~/.ssh/known_hosts
      fi
    ]
  end

  # Create database.yml for Postgres if it doesn't exist
  path_database_yml = "#{deploy_to}/#{shared_path}/config/database.yml"
  database_yml = %[production:
  database: fuitter
  adapter: postgresql
  pool: 5
  timeout: 5000]
  queue! %[ test -e #{path_database_yml} || echo "#{database_yml}" > #{path_database_yml} ]

  # Create secrets.yml if it doesn't exist
  path_secrets_yml = "#{deploy_to}/#{shared_path}/config/secrets.yml"
  secret =
  secrets_yml = %[production:
  secret_key_base:
    #{`rake secret`.strip}]
  queue! %[ test -e #{path_secrets_yml} || echo "#{secrets_yml}" > #{path_secrets_yml} ]

  queue! %[chmod g+rx,u+rwx,o-rwx "#{deploy_to}/#{shared_path}/config"]

end

desc "Deploys the current version to the server."
task :deploy => :environment do
  to :before_hook do
    # Put things to run locally before ssh
  end
  deploy do
    # Put things that will set up an empty directory into a fully set-up
    # instance of your project.
    invoke :'git:clone'
    invoke :'deploy:link_shared_paths'
    invoke :'bundle:install'
    invoke :'rails:db_migrate'
    invoke :'rails:assets_precompile'
    invoke :'deploy:cleanup'

    to :launch do
      # queue "mkdir -p #{deploy_to}/#{current_path}/tmp/"
      # queue "service #{user} restart"
    end
  end
end

# For help in making your deploy script, see the Mina documentation:
#
#  - http://nadarei.co/mina
#  - http://nadarei.co/mina/tasks
#  - http://nadarei.co/mina/settings
#  - http://nadarei.co/mina/helpers

then run mina setup and finally mina deploy.
That is all there is to it.

Saturday, November 21, 2015

Hiking to chisapani (A must do hike)


TL;DR
Chisapani is very expensive but it is even more expensive for foreign tourist. I would highly recommend to take some dry foods from home.
It took us 7hrs to reach chisapani from sundarijal, and 5 hrs to get back to sundarijal from chisapani.
Warm clothes is a must because it gets frigid at night and in morning.
Great view of mountain (Langtang, annapurna range, MT everest, ganesh himal)
Ever wondered how a sky full of stars looks like?  Get out of the lodge or hotel in somewhere between 11pm - 3am and look up at the sky.
Safe for solo hike too.

price list(this does not apply to foreign tourist)
plain tea Rs 20
hard boiled eggs Rs 30
plain pankcakes Rs 60
plain dinner Rs 200
room Rs 800 - 500
marijuana Rs 250
coconut biscuit Rs 25
jumbo wai wai noodles Rs 150
local alcohol Rs 100

Link to all the pics

About 8 months ago, I heard about this place via my colleague, then I did some research but could not find much resources on the internet however the ones I found were enough for me to add this place in my wish list. I was planning to go alone but a friend of mine showed interest in going there too so I formed a group of 6 peeps and we left for sundarijal at 7 am from old bus park.

Selfie from the roof of the bus
To make our ride up to sundarijaal adventurous we traveled on the roof of the bus. Since, I had the responsibility of taking care of expenses I had to pay Rs 250 for the fare.

View from the hotel we had our breakfast at

After reaching sundarijal we took a light breakfast (6 eggs, 6 doughnuts, 2 plate fried chickpea, 1 plate fried aloo, 3 bowl of tarkari ) spending a total of Rs 300 and resumed our hike afterwards.



It felt really great to see these huge metal pipes in reality than read about them in the blogs I found.

Rainbow
Entering Shivapuri National Park



To start our chispani hike, I had to pay Rs 50 just to enter the hiking trail.



We swam in this river

First visual of the mountain
We stopped for chyang in one of the hotel along the way and the owner was very gregarious. He shared how devastating the earthquake was to him as he had loose his house. Up to this point, foods are very cheap compared to chisapani. We paid a total of Rs 135 and they also filled the remaining chyang in their own bottles and did not charged us for it and they also filled our water bottle with drinking water. He then showed us the way to chisapani and we left. We got so excited when we had our first visual of the mountain.
The only river to accompany in the whole hiking trail






First visual of Chisapani
Walking for almost 6 hrs we were so exhausted and hungry. All the way we talked about how tasty the fried chicken in the dinner was yesterday. When we saw hotels at Chisapani, we all got excited.


Mountains as seen from Chisapani

Destruction caused by earthquake
After reaching there, we sat down for tea and 2 packets of biscuits for each of us as there was nothing much to eat at the hotel. A packet of biscuit cost Rs 15 and plain tea cost Rs 25. We then found a cheap lodge. I paid Rs 500 for a room, Rs 60/pancake, Rs 30 for an egg and Rs 200/person for dinner. We had brought 6 cans of tuna with us so dinner was really like a feast.
Sun rise in morning

Again, mountains
It was a very fun hike up to chisapani but there is a lot of pollution along the trail. Well the good thing is we completed this whole hike in just Rs 6000 and staying in budget.

Thursday, October 29, 2015

Places I travelled in a year

Has it been a year this quick? oh yes it has. I remember the first time I watched FRIENDS, 2 years ago. Any way, traveling was not always my favorite thing to do until a year ago when I traveled to Pokhara. Since my childhood I have always been afraid of adventures and the jungles and the things that live in the jungle. But my first tour to Pokhara changed everything.

Since that day, I have been traveling awfully a lot, and my parents complain about it. To be fair, I have also trekked solo up to an altitude of 3800m.

Places I have traveled to

Pokhara on Oct 2014
MT flight on Jan 2014
Jhor on May 2015
Dolalghat on June 2015
Kulekhani - Chitlang on Jul 2015
Kalinchowk on Sep 2015

On my wishlist

ABC trek  (2016 april 9 -14) trek completed
Langtang trek (covering Gosainkunda)
Chisapani  (this hike is completed)
Chamadevi (this hike is completed)
Rara (far cry)

Pokhara
MT Flight
Jhor
Dolalghat
Kulekhani

Chitlang
Kalinchowk