Skip to content

Instantly share code, notes, and snippets.

View itsbalamurali's full-sized avatar
🎯
Focusing

Balamurali Pandranki itsbalamurali

🎯
Focusing
View GitHub Profile
@itsbalamurali
itsbalamurali / index.php
Last active August 29, 2015 13:57
Replace index.php
<?php
$_SERVER['SERVER_PORT'] = 80;
/**
* Step 1: Require the Slim Framework
*
* If you are not using Composer, you need to require the
* Slim Framework and register its PSR-0 autoloader.
*
* If you are using Composer, you can skip this step.
*/

MacOS

Download from here:

http://d.pr/f/QE3d

MD5: 59bab8f71f8c096cd3f72cd73851515d

Rename it to: Sublime Text

Make it executable with: chmod u+x Sublime\ Text

@itsbalamurali
itsbalamurali / linux commands
Created March 16, 2014 19:09
All LINUX commands and their description.
All LINUX commands and their description.
Command Description
alias Create an alias
apropos Search manual for keyword
at Schedule a job to run in the future.
awk Find and Replace text within file(s)
break Exit from a loop
builtin Run a shell builtin
bunzip2 Decompress file from bzip2 format
/*
* Copyright (c) 2011 The Chromium Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
/**
* Performs an XMLHttpRequest to Twitter's API to get trending topics.
*
* @param callback Function If the response from fetching url has a
* HTTP status of 200, this function is called with a JSON decoded
{
"trends": {
"2011-01-14 21:20:00": [
{
"name": "#sidechick",
"events": null,
"query": "#sidechick",
"promoted_content": null
},
{
@itsbalamurali
itsbalamurali / HOWTO.md
Created February 28, 2014 05:50 — forked from nyarla/HOWTO.md

How to make a CoreOS's ISO file from pxe boot image

  1. SYNOPSIS

This documentation is written about how to make a CoreOS's ISO file from pxe boot image.

  1. REQUIREMENTS

[{"regex": ["http://*youtube.com/watch*", "http://*.youtube.com/v/*", "https://*youtube.com/watch*", "https://*.youtube.com/v/*", "http://youtu.be/*", "http://*.youtube.com/user/*", "http://*.youtube.com/*#*/*", "http://m.youtube.com/watch*", "http://m.youtube.com/index*", "http://*.youtube.com/profile*", "http://*.youtube.com/view_play_list*", "http://*.youtube.com/playlist*"], "about": "YouTube is the world's most popular online video community, allowing millions of people to discover, watch and share originally-created videos. YouTube provides a forum for people to connect, inform, and inspire others across the globe and acts as a distribution platform for original content creators and advertisers large and small.", "displayname": "YouTube", "name": "youtube", "domain": "youtube.com", "subdomains": ["m.youtube.com"], "favicon": "http://c2548752.cdn.cloudfiles.rackspacecloud.com/youtube.ico", "type": "video"}, {"regex": ["http://*twitch.tv/*", "http://*justin.tv/*/b/*", "http://*justin.tv/*/w/*"], "about":
@itsbalamurali
itsbalamurali / app.js
Created February 12, 2014 18:11 — forked from clarle/app.js
// Module dependencies
var express = require('express'),
mysql = require('mysql');
// Application initialization
var connection = mysql.createConnection({
host : 'localhost',
user : 'root',

#function i have like this

$display_output = '<table width="100%" border="0" cellspacing="2" cellpadding="3" class="paymenttable"> '.
  			'<tr>'.
			'	<td width="160" class="paytable1"><img src="img/google_wallet_logo.png"></td> '.
			'	<td class="paytable2" width="100%">' . GMSG_GC_DESCRIPTION . '</td> '.
			'	<br><input id="runDemoButton"  type="image" src="themes/' . $this->setts['default_theme'] . '/img/system/but_pay.gif" onclick="DemoButton("'.$jwtToken.'");" border="0">'.
		  	'</tr></table>';
mkdir ~/git/website.git && ~/git/cd website.git
git init --bare
mkdir ~/webapps/website
git config core.bare false
git config core.worktree /home/rafi/webapps/website ; NO TRAILING SLASH!!! Will screw up things real bad.
git config receive.denycurrentbranch ignore
; create a hook
cat > hooks/post-receive
#!/bin/sh