Skip to content

Instantly share code, notes, and snippets.

View vasuadari's full-sized avatar
🤔
Thinking

Vasu Adari vasuadari

🤔
Thinking
View GitHub Profile
@vasuadari
vasuadari / .vimrc
Created March 4, 2019 16:48
vimrc
set nocompatible " be iMproved, required
filetype off " required
" Leader
let mapleader = "-"
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
@vasuadari
vasuadari / shell_problems.md
Created June 24, 2019 08:23
Unix shell script problems
  1. Write a shell script to ping a URL every 10 seconds and return a status code.

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@vasuadari
vasuadari / handy_snippets.md
Created January 8, 2020 05:39
Handy Snippets

Export respective library to env vars.

export LDFLAGS=-L/usr/local/opt/openssl/lib
export CPPFLAGS=-I/usr/local/opt/openssl/include
export PKG_CONFIG_PATH=/usr/local/opt/openssl/lib/pkgconfig
@vasuadari
vasuadari / install_aws_ssm_for_ubuntu_14_04
Created March 7, 2020 10:56
Install amazon-ssm-agent for ubuntu 14.04
mkdir /tmp/ssm
cd /tmp/ssm
wget https://s3.amazonaws.com/ec2-downloads-windows/SSMAgent/latest/debian_amd64/amazon-ssm-agent.deb
sudo dpkg -i amazon-ssm-agent.deb
sudo start amazon-ssm-agent
sudo status amazon-ssm-agent
@vasuadari
vasuadari / mysql_5_7_keywords.txt
Created April 17, 2020 13:09
MySQL 5.7 Keywords
account
always
channel
compression
encryption
file_block_size
filter
follows
generated (r)
group_replication
@vasuadari
vasuadari / mysql_5_6_keywords.txt
Created April 17, 2020 13:20
MySQL 5.6 keywords
accessible
action
add
after
against
aggregate
algorithm
all
alter
analyse
@vasuadari
vasuadari / mysql_5_8_keywords.txt
Created April 20, 2020 09:20
MySQL 5.8 keywords
active
admin
array
attribute
buckets
clone
component
cume_dist
definition
dense_rank
@vasuadari
vasuadari / delete_branches_older_than.sh
Last active May 20, 2020 15:28 — forked from redthor/delete_branches_older_than.sh
Script to delete branches older than a certain date, modification of 4586456
# Copy of https://gist.github.com/antonio/4586456
# With a modification to collect all the branch names so we can make one git request
# Set DRY_RUN=1 to get an echo of the command
# Format that works with `git log --since`, e.g. 2018-01-01
date=$1
branches=
for branch in $(git branch -r | sed 's/^\s*//' | sed 's/^remotes\///' | grep -v 'master$'); do
@vasuadari
vasuadari / cheat_sheet.md
Last active June 3, 2025 03:35
My Cheat Sheet

MySQL

Dump a query result to a csv file

mysql -h [HOST] -P [PORT] -u [USER] DB_NAME -e '[QUERY]' -p > [FILE_NAME].csv

Networking