Skip to content

Instantly share code, notes, and snippets.

View dhruvasagar's full-sized avatar

Dhruva Sagar dhruvasagar

View GitHub Profile
import Data.List (intercalate)
import Data.Maybe (fromJust, fromMaybe)
import Debug.Trace (trace)
data Point = Point Int Int
deriving (Show, Eq)
parsePoint :: String -> Point
parsePoint as = Point x y
where
name: Deploy Dev
on:
workflow_run:
workflows: ["CI"]
types:
- completed
branches:
- develop
job:
#!/usr/bin/env bash
# GistID: 6db76639d8874eb9ffd091021bedba8e
set -e
info () {
tput setaf 6; echo "$1"; tput sgr0
}
#!/bin/bash
# GistID: 87c59acf3b53cf1911bc6e3a8055afbf
_call_func () {
declare -f -F "$1" && $1
}
typeset -A _dirsh_cache
_dirsh_hook () {

Keybase proof

I hereby claim:

  • I am dhruvasagar on github.
  • I am dhruvasagar (https://keybase.io/dhruvasagar) on keybase.
  • I have a public key ASBD9lLidgpCJG8sfmBDLu6RRxz15Kn6koyCJspFa_jQWgo

To claim this, I am signing this object:

@dhruvasagar
dhruvasagar / zshrc
Last active April 14, 2019 03:48
Simple trick to profile ZSH
if [[ "$ZPROF" = true ]]; then
zmodload zsh/zprof
fi
# ... your ZSHRC with all your scripts
if [[ "$ZPROF" = true ]]; then
zprof
fi
if [ ! -x "$(command -v aws)" ]; then
echo 'Please install following dependencies: '
echo '* jq'
echo '* cfssl'
echo '* aws cli'
exit 1
fi
usage () {
echo "Usage: $0 [tag]"
if exists('g:loaded_pairify')
finish
endif
let g:loaded_pairify = 1
let g:pairs = {
\ "left": {
\ "[": "]",
\ "(": ")",
\ "{": "}",
alert('test');
@dhruvasagar
dhruvasagar / WebRTC Outline.md
Created October 13, 2016 04:28
WebRTC Outline
  • Introduction to WebRTC
  • Why WebRTC ?
  • WebRTC underpinnings : Signaling, STUN, TURN
  • Open Source Libraries & Tools available
  • Building your own Signaling Server
  • Demo