Image Searching with Google Custom Search API

Oh man, the Google Custom Search API is pretty cool – you get to run searches using Google’s engine, but the free API tier is really low. A quota of 100 per day, which includes retrieving more results, actual queries, requeries… It’s barely enough for a handful of searches a day.

Screen Shot 2015-03-05 at 10.10.51 pmBut hey check out the very pretty API stats. Errors don’t count, thankfully, but they are nicely logged.

I’ve taken an open source Image Search app and changed the API a bit to enable higher limits. The awesome Android app helps to search, download and attach images into your chats/emails/apps. You can download my version which should hopefully work better. It should be live by tomorrow on the Google PlayStore. (It takes quite awhile for things to get through the PlayStore.)

It’s gonna need to have in-app billing to survive the API limits though. or some form of payment/revenue.

device-2015-03-06-014911

device-2015-03-06-012609

device-2015-03-06-012653

device-2015-03-06-012716

Image Searching with Google Custom Search API

sudo ssh

SSH (Secure Shell), is effectively a command-line tool to securely encryptedly access remote computers or servers. It is amazingly good.

I normally use Putty to create a SSH Tunnel on Windows. Because I am not so hardcore and do like a command-line interface to keep things simple. There are configuration steps available on Google. Not difficult to find.

I tried doing the same on my Macbook, but realised that Putty is not for Mac. Turns out just one darn command will do effectively the same trick.
ssh -D 8080 -f -C -q -N william@www.myserver.com
via macapper.com

So why SSH Tunneling? It creates a secure encrypted tunnel connection over which your network or internet traffic is sent. So if you are at a public internet service, and you wish to load higher risk websites or apps like banking sites, it might be good to do it via a secure tunnel, like a VPN, in this case the SSH tunnel. This prevents criminals from eavesdropping on your insecure free public wifi.

Additionally, your traffic also appears to be coming from the end server. Meaning, if you SSH tunnel to a US server, the website thinks you are in US. You can access content like Hulu, Netflix, etc.

Admittedly this is not for the faint hearted, but it might just come in useful someday. Like if you are stuck in China without Facebook or Twitter or Google. Or you are in some Middle East country. You never know.

sudo ssh

postgresql

javascript sux, let's do something else
*checks PivotalTracker*
okay let's migrate from sqlite to postgresql
check postgresql install
suspicious
jh$ brew uninstall postgresql (Terminal commands)
jh$ brew doctor
frown
cmd-c cmd-v (ctrl-c ctrl-v) some command
frown
jh$ brew list
frown
jh$ brew install postgresql
...
/some installation cmd
error
frown
restart
jh$ init something
error
restart
frown
jh$ some command
jh$ some command
jh$ some command
jh$ which psql  (hm Lion comes with another psql)
jh$ psql --version
frown
download new pgadmin3
install pgadmin3
modify database.yml
jh$ rails s
localhost:3000
it starts!
frown
add port:5432
jh$ cmd-c
jh$ rails s
error
localhost:3000
jh$ rake db:migrate
it starts!
blank database
:)

~2 hours.

postgresql

sunset

sunset

I can’t decide which is prettier, above or below

@itemhl = HalfLink.find_all_by_item_id(@itemfl, :include => :other_item, :order =>'other_category_id asc') 
@items_grouped_by_categories = @itemhl.group_by {|itemhl| itemhl.other_item.category.name}
sunset