Skip to content

Instantly share code, notes, and snippets.

View sagarjauhari's full-sized avatar
💭
building interesting things!

Sagar Jauhari sagarjauhari

💭
building interesting things!
View GitHub Profile
@sagarjauhari
sagarjauhari / blogger2jekyll.py
Last active August 29, 2015 13:59 — forked from larsks/blogger2scriptogram.py
Export blogger/blogspot posts to jekyll
#!/usr/bin/python
import os
import sys
import argparse
import iso8601
import re
import subprocess
import logging
import json
@sagarjauhari
sagarjauhari / mogrivy_blog.sh
Created April 19, 2014 02:23
Resize images to 'feature image' size for jekyll blog.
mogrify -resize 2048x2048 -gravity Center -crop 2048x512+0+0 guitar.jpg
@sagarjauhari
sagarjauhari / LICENSE
Last active August 29, 2015 14:04 — forked from dgehrett/LICENSE
CodeClimate Widget for Dashing
The MIT License (MIT)
Copyright (c) 2013 HomeFinder.com
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

Add the following to your Gemfile:

gem 'heroku-api'

Put heroku.rb in your jobs folder and add the contents of heroku.html into your layout.

@sagarjauhari
sagarjauhari / keybase.md
Created February 26, 2015 23:15
keybase.md

Keybase proof

I hereby claim:

  • I am sagarjauhari on github.
  • I am sagj (https://keybase.io/sagj) on keybase.
  • I have a public key whose fingerprint is 77DB 9DD0 4DDA 3BF1 EA65 A3DB D5A9 2EB1 D655 A47A

To claim this, I am signing this object:

@sagarjauhari
sagarjauhari / bash_aliases
Created October 18, 2013 18:20
Bash Aliases
export EDITOR=~/bin/edit
export VISUAL=~/bin/edit
export ALTERNATE_EDITOR=emacs
alias t='terminator 2> /dev/null &'
alias g='gedit > /dev/null &'
alias em='emacsclient -c > /dev/null&'
alias ec='/home/sagar/eclipse/eclipse > /dev/null&'
alias ci='google-chrome --incognito > /dev/null&'
alias p='ps -e| grep '
alias wifi='/home/sagar/Dropbox/scripts/wifi_rtl_cisco.sh'
@sagarjauhari
sagarjauhari / kernelized_kmeans
Created October 20, 2013 21:19
Trying to use k-means with non-euclidean distance metric
# Source : http://stackoverflow.com/a/5551499/283572
#!/usr/bin/env python
# kmeans.py using any of the 20-odd metrics in scipy.spatial.distance
# kmeanssample 2 pass, first sample sqrt(N)
from __future__ import division
import random
import numpy as np
from scipy.spatial.distance import cdist # $scipy/spatial/distance.py
@sagarjauhari
sagarjauhari / hello.py
Last active July 19, 2018 20:48
Diff Test
class Animal:
def name(self):
return "Simba"
@sagarjauhari
sagarjauhari / docker-compose.yml
Created May 18, 2019 23:36
Initial docker-compose.yml
version: '3'
services:
dev:
build: .
@sagarjauhari
sagarjauhari / docker-compose.yml
Created May 18, 2019 23:42
docker-compose with database
version: '3'
services:
db:
image: postgres
environment:
POSTGRES_PASSWORD: password
ports:
- "5432:5432"
dev:
build: .