Skip to content

Instantly share code, notes, and snippets.

View hemanth's full-sized avatar
🐜
🧘‍♂️

Hemanth HM hemanth

🐜
🧘‍♂️
View GitHub Profile
@hemanth
hemanth / browser_better.rb
Last active December 11, 2015 20:09
Better watir-webdriver?
require 'watir-webdriver'
module Browser
def get(obj,how,what,value=nil)
self.browser.send(obj,how,what)
end
def set(obj,how,what,value=nil)
if value
self.browser.send(obj,how,what).set(value)
@hemanth
hemanth / update.md
Created January 27, 2013 06:46
Update Samsung S advance to Jelly Bean (4.1.2)

Step-By-Step Instructions:

Step 1 - Download Android 4.1.2 XXLPY Jelly Bean for Galaxy S Advance to your computer and extract the RAR file anywhere.

Step 2 - Turn OFF your phone and connect the Galaxy S Advance to your computer using the USB cable.

Step 3 - Now to get in the Recovery Mode. Switch ON the phone while pressing and holding Volume Up + Home + Power buttons together.

Step 4 - In recovery mode, leave the phone as it is. Now on your computer, run deodex_recovery.bat from the files you extracted in Step 1.

// various buzzy descriptors
var envs = ['Responsive','Server-side','Client-side','Command-line','Mobile','High-throughput','RESTful','High-availability','Low-latency','Normalized','Cross-domain','Cross-platform','Agile','P2P','Secure'];
// things that sound cool to do
var cool = ['audio','events','subscriptions','rendering','ray-tracing','filtering','physics','websockets','games','compression','IO','encryption','grids'];
// connector words
var conn = ['with','using'];
// technologies that are hot
@hemanth
hemanth / browser.json
Created December 14, 2012 10:59
From @substack browserling
[
{
"name" : "explorer",
"versions" : ["6.0","7.0","8.0","9.0"]
},
{
"name" : "firefox",
"versions" : ["3.0", "3.5", "3.6", "4.0", "5.0", "6.0", "7.0", "8.0", "9.0", "10.0", "11.0", "12.0", "13.0", "14.0", "15.0", "nightly"]
},
{
@hemanth
hemanth / sandboxes.txt
Created December 9, 2012 08:54
In-browser html sandboxes
Some in-browser html sandboxes:
http://jsfiddle.net/
http://jsbin.com/
http://cssdesk.com/
http://dabblet.com/
http://code.google.com/apis/ajax/playground/
http://www.webdevout.net/test
http://tinkerbin.com/
http://sandbox.coreyworrell.com/
@hemanth
hemanth / gist:4160185
Created November 28, 2012 09:46 — forked from paulirish/gist:4158604
Learn JavaScript concepts with recent DevTools features

Learn JavaScript concepts with the Chrome DevTools

Authored by Peter Rybin , Chrome DevTools team

In this short guide we'll review some new Chrome DevTools features for "function scope" and "internal properties" by exploring some base JavaScript language concepts.

Closures

Let's start with closures – one of the most famous things in JS. A closure is a function, that uses variables from outside. See an example:

@hemanth
hemanth / vs.js
Created November 23, 2012 10:20
arrayfrom vs [].foreach
var divs = document.querySelectorAll('div');
Array.from(divs).forEach(function (node) {
console.log(node);
});
var divs = document.querySelectorAll('div');
[].forEach.call(divs, function (node) {
console.log(node);
});
@hemanth
hemanth / promises.md
Created October 29, 2012 16:35 — forked from domenic/promises.md
You're Missing the Point of Promises

You're Missing the Point of Promises

Promises are a software abstraction that makes working with asynchronous operations much more pleasant. In the most basic definition, your code will move from continuation-passing style:

getTweetsFor("domenic", function (err, results) {
    // the rest of your code goes here.
});
# These are my notes from the PragProg book on CoffeeScript of things that either
# aren't in the main CS language reference or I didn't pick them up there. I wrote
# them down before I forgot, and put it here for others but mainly as a reference for
# myself.
# assign arguments in constructor to properties of the same name:
class Thingie
constructor: (@name, @url) ->
# is the same as:
@hemanth
hemanth / app.js
Created October 10, 2012 10:40 — forked from pixelhandler/app.js
Develop a RESTful API Using Node.js With Express and Mongoose - See: http://pixelhandler.com/blog/2012/02/09/develop-a-restful-api-using-node-js-with-express-and-mongoose/
var application_root = __dirname,
express = require("express"),
path = require("path"),
mongoose = require('mongoose');
var app = express.createServer();
// database
mongoose.connect('mongodb://localhost/ecomm_database');