Skip to content

Instantly share code, notes, and snippets.

Bharadwaj Raju bharadwaj-raju

Block or report user

Report or block bharadwaj-raju

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@bharadwaj-raju
bharadwaj-raju / DoubleMouse.sh
Created Jan 30, 2016
Multi-mouse config for X11
View DoubleMouse.sh
#!/bin/bash
# DoubleMouse.sh - Multi-mouse config + button swap for X
$mousename = $1
if [[ $1 == '--help' || $1 == '' || $1 == '-h' ]]
then
# Show help
View printLoop.py
# Program to print string n times
# Usage: printLoop.py [string to print] [number of times to print]
import sys
scriptName, string, count = sys.argv
for i in range(0, count):
print string
@bharadwaj-raju
bharadwaj-raju / blankRevealJS.html
Last active Mar 12, 2016
A blank template for reveal.js
View blankRevealJS.html
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title></title> <!-- Your presentation's title -->
<meta name="description" content=""> <!-- Describe your presentation -->
<meta name="author" content=""> <!-- Your name -->
View .conkyrc
alignment top_left
# Set to yes/no to enable/diable background forking of conky process
background yes
# Set xy position
gap_x 0
gap_y 0
# Set size
@bharadwaj-raju
bharadwaj-raju / BashOrgQuoteScraper.py
Last active Mar 21, 2016
Get quotes from the bash.org QDB
View BashOrgQuoteScraper.py
import urllib2
from bs4 import BeautifulSoup
import re
from random import randint
# Get quotes from bash.org
# Constants
TOP_100_URL = 'http://bash.org/?top'
@bharadwaj-raju
bharadwaj-raju / .conkyrc
Last active Apr 25, 2016
Idle time countdown in conky
View .conkyrc
alignment top_left
background no
gap_x 0
gap_y 0
minimum_size 1024 1000
maximum_width 50000
update_interval 2
total_run_times 0
double_buffer yes
View GravityCalculator.py
class GravityCalculator():
def __init__(self):
print('Do that yourself.')
GravityCalculator()
View compile.sh
function extract {
if [ -z "$1" ]; then
# display usage if no parameters given
echo "Usage: extract <path/file_name>.<zip|rar|bz2|gz|tar|tbz2|tgz|Z|7z|xz|ex|tar.bz2|tar.gz|tar.xz>"
else
if [ -f "$1" ] ; then
NAME=${1%.*}
#mkdir $NAME && cd $NAME
case "$1" in
*.tar.bz2) tar xvjf ./"$1" ;;
@bharadwaj-raju
bharadwaj-raju / zsh.zsh
Last active May 1, 2016
My ultra-custom zshrc
View zsh.zsh
# Path to your oh-my-zsh installation.
export ZSH=/home/bharadwaj/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
ZSH_THEME="bullet-train"
# Uncomment the following line to use case-sensitive completion.
View RandomCopier.py
#!/usr/bin/env python3
# Script to copy n random folders to a location
# Usage: RandomCopier.py [source folder] [destination folder] [number to copy]
import os
import sys
import shutil
import random
You can’t perform that action at this time.