Skip to content

Instantly share code, notes, and snippets.

Dhruv Kar dhruvkar

Block or report user

Report or block dhruvkar

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

Keybase proof

I hereby claim:

  • I am dhruvkar on github.
  • I am dhruvkar ( on keybase.
  • I have a public key whose fingerprint is 4567 DD8B 3255 4C43 0B2F 6A0F 4FDC 3E91 57A4 50A2

To claim this, I am signing this object:

dhruvkar /
Last active Mar 22, 2019
Run Browser in a Virtual Display using Selenium and transfer session to Python Requests
If you use Chrome, get Chromedriver and put in your PATH:
If you use Firefox, get Geckodriver and put in your PATH:
Also install:
pip install requests
dhruvkar /
Last active Mar 22, 2019
Get Yelp and Google ratings of a business, given the business name, address, & phone number.
#!/usr/bin/env python
from __future__ import print_function
import json
import re
import requests # pip install requests
from yelpapi import YelpAPI # pip install yelpapi. Not a very mature library, use at your own risk.
from requests.compat import urljoin, quote_plus
dhruvkar /
Last active Aug 23, 2017
best way to make a directory in python
def mkdir(dir_path)
except OSError as e:
if e.errno != errno.EEXIST:
dhruvkar / config.js
Last active Dec 20, 2017
Config file for Ghost
View config.js
// # Ghost Configuration
// Setup your Ghost install for various environments
var path = require('path'),
config = {
// ### Development **(default)**
development: {
// The url to use when providing links to the site, E.g. in RSS and email.
You can’t perform that action at this time.