Random Stuffs

Random Stuffs

Hello, I will be using this page for different random stuff that interests me and if I have enough time I will be putting in-depth post on it.

-[ Custom notification {Growl} for battery low message (quick & dirty )]-

Goto terminal and

mkdir ~/Library/Application\ Scripts/myScript
nano ~/Library/Application\ Scripts/myScript/batteryLow.scpt

tell application “GrowlHelperApp”
set the allNotificationsList to ¬
{“Battery Low”}
set the enabledNotificationsList to ¬
{“Battery Low”}

register as application ¬
“Battery Low!” all notifications allNotificationsList ¬
default notifications enabledNotificationsList icon of application “Battery Health”
end tell

set Cap to (do shell script “system_profiler SPPowerDataType|grep ‘Charging'”)
tell Cap to set {wallpower} to {last word of paragraph 1}
if wallpower = “Yes” then
set Cap to (do shell script “system_profiler SPPowerDataType|grep ‘Charge Remaining'”)
tell Cap to set {Available} to {last word of paragraph 1}
set Recap to (do shell script “system_profiler SPPowerDataType|grep ‘Full Charge Capacity'”)
tell Recap to set {Max} to {last word of paragraph 1}
set Pct to round (100 * Available / Max)

if Pct ≤ 20 then

tell application “GrowlHelperApp”
notify with name “Battery Low” title “Battery Low” description ” You only have ” & Pct & “% ” & “left.” application name “Battery Low!”
end tell

end if
end if

The script will notify you when battery is at 20%.

Now create plist which will check battery stats in every 10 min, if you want to increase or decrease time, change 600 (600 is second)

nano ~/Library/LaunchAgents/com.batterylow.plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<string>/Library/Application\ Scripts/myScript/batteryLow.scpt</string>


Log out and log-in back again. [Reference: I can’t remember sorry.. I only did few tweaking  in scpt and plist]

-[ Connect to VNC through SSH ]-
ssh -l user -p 22 -L5901:localhost:5901 serverIp

In VNC Client, put localhost:5901 to run vnc

Start of Fast Browser (Google Chrome) Based Free VPN – ZenMate


As we all know many useful site are blocked in many countries. In addition most of the good VPN service are pay only too. I found this browser (Google Chrome) based free VPN “ZenMate” which is awesome. It is faster than any other browser based VPN that I have used till now and no setup required.  While I can’t say if its secure or not but it can unblock almost all websites and can be used as day to day browser without any speed limit (not that I am aware of). (Download)

End of Fast Browser (Google Chrome) Based Free VPN
Start of Access Your Computer From Anywhere (Remote VNC + Audio)
Chrome Remote

Chrome Remote

I recently found the easiest way to access your personal computer which is better than normal vnc as you can not only interact with server but also hear audio 😀 .

In addition, you don’t need to worry about any complex steps to do that. All you need is Google chrome and Chrome Remote Extension. 🙂 in both server and client computer.

1. First download and install Google Chrome (Download) then download Chrome Remote Desktop (Download).

2. In Server, Click on Chrome Remote Desktop and Authorise it and click on Get Started button and finish the process. At end of the day, you will have code.

3. In Client, download extension and login in with gmail. You should see your server name click on it and enter the code. taadaa its done.. 😀 have fun.

End of Access Your Computer From Anywhere (Remote VNC + Audio)
Intro Go Wireless – Plex Client

I use my old laptop as plex client and is connected by HDMI to TV. The problem with this setup is UI interfaction. You have to use keyboard to select menu as well as to search contain as I don’t have wireless keyboard I use few apps to interact. The two common apps that I use (for Android OS)

1. WIFI Mouse (Link)

Image 1.1 – WiFI Mouse

I use this apps to control my mouse. I usually use it to launch plex or use it as keyboard as it has keyboard function too.

2. Plex Remote (Link)

plex remote
Image 1.1 – Plex Remote

Plex Remote is very handy apps to interact with plex client. It can find Plex Client automatically and can be use do most of the thing in plex. It does lack some key function like keyboard option that is why I use wifi mouse.

End of Go Wireless – Plex Client
Start of Quick Review of music player app – COG (for audiophile)


Link to Homepage: http://cogx.org/

COG is an open sources music player for Mac OS. I was looking for alternative for iTunes player for a while now, although iTunes is good enough for everyday  use I always had this feeling that just to play a music why do I have to give 1-2GB memory. It seems to be very heavy to my system with all extra features like iTune Store, apps, iphone / ipod sync, etc.


In quest of finding good and light weight player I have tried many player. I think COG for me was the simple and easy to use music player which plays music superb and it supports

  • Ogg Vorbis
  • Mp3
  • Flac
  • Musepack
  • Monkeys Audio
  • Shorten
  • Wavpack
  • AAC
  • Apple Lossless and more.

The player looks itself primitive / out dated but it works fine in Mac OS Lion. COG that I am using right now is nightly build so I think someone is working on it. (http://cogx.org/development.php). Anyway despite its look you will be surprise how well it can play music. And Stable and nightly has different UI now. I suggest you guys to try Nightly build.

End of Quick Review of music player app – COG (for audiophile)
Start of Bootable Pen Drive for MAC OS

First thing you need to do is format pen drive in MS-DOS [FAT] format. (Yes in MS-DOS format !! 😦 but it will work don’t worry in Mac but in NOT in Windows.. 😀 )

Go to

Application> Utility > Disk Utility


cmd ⌘ + space (type disk utility)

Select your pendrive at left handside bar > eg. 15.8 GB JetFlash

Then click on

Partition> select partition layout – 1 partition > Click Option > GUID Partition Table> OK > Apply

Download  Unetbootin app from here http://unetbootin.sourceforge.net/

Now select desire Distribution / download ISO and apply

When you boot your computer press and hold on option key ⌥ it will then give you option to boot from HD, Recovery , EFI select efi and it will boot from usb.

End of Bootable Pen Drive for MAC OS
Start of Site review

Now this might seems to you guys like an advertisement about stereodose.com website but then I am not posting this in my front page any way.. 😛 its a random review of this site that I found recently.

The  most interesting thing about this website is it creates the playlist according to the dugs (weed, LSD) rather than the existing genre (rock, pop etc).  Its quiet interesting idea and you might like the music according to drugs rather genre.

Just a side note, all the music in this website are remix songs.

NOTE: I am in noway encouraging anyone to do drugs. Its not good to your health.

End of Site review
Bluetooth Problem with Mac os

If you are like me who have stereo bluetooth headphone and has this strange problem with sound (static noise)when you listen to higher bit rate song then the solution for that problem is

Run Terminal app and enter following code

defaults write com.apple.BluetoothAudioAgent “Apple Bitpool Min (editable)” 50

This will solve that problem..

End of Bluetooth Problem with Mac os
Helpful Application
Image 1.1 – F.lux logo

If you are like me who work all night in computer then I would recommand you use f.lux application. It change you screen color to suits your eye. It’s free and will help your eye to see screen longer 😉

Download here

End of Helpful Application
LXDE Desktop + VNC For Remote Server Access – Debian
apt-get update & apt-get upgrade

Now installing few LXDE Core files and TightVNC Server

apt-get install xorg lxde-core tightvncserver

Run TightVNC Server to create its config file

tightvncserver :1

Now Kill TightVNC process

tightvncserver -kill :1

Run this command to add few extra line in xstartup files

echo “lxterminal & /usr/bin/lxsession -s LXDE &” >> ~/.vnc/xstartup

Now to run TightVNC Server just run

tightvncserver :1

After you run this it might ask you to give a password. Enter the new password here. If it didn’t ask any password use your user login password.

For Mac client : option key + k will give you option to connect to server, For Windows client, download TightVNC Java Viewer (here)

[server ip]:5901

Now it should ask you password. Enter the password that you have give while running TightVNC

End of LXDE Desktop + VNC For Remote Server Access – Debian
Some Useful command

Delete Folder in Linux

rm -r [folder name]

Move folder

mv -v [path/of/source folder] [path/of/destination folder]
End of Useful command
End Random Stuffs

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s