Skip to content

Instantly share code, notes, and snippets.

View kevthanewversi's full-sized avatar
🦍

Kevin Murimi kevthanewversi

🦍
View GitHub Profile
import requests
from lxml import etree
from lxml.etree import fromstring
import csv
username =""
password =""
count = 0
column = 0
list = []
@kevthanewversi
kevthanewversi / database dump
Last active August 30, 2018 12:26
database dump
#!/bin/bash
mysqldump -u username -pxxxxx titandb1 --single-transaction --quick --lock-tables=false > titandb1-backup-$(date +%F).sql
@kevthanewversi
kevthanewversi / sort_dict.js
Last active March 19, 2018 12:15
Some nifty JS script that can be used to sort a dictionary <python> or rather Object <javascript> by one of the values in the Object
//init a dict with key value pairs. The values in my case are arrays. That can be changed
var dict = {
"x": [1, 3],
"y": [6, 90],
"z": [9, 16],
"a": [5, 3],
"b": [7, 9],
"c": [11, 3],
"d": [17, 3],
"t": [3, 10]
server {
listen 443;
server_name goto.kla.xxx.com go; # <== 2 domains
root /var/www/html/docs/sslbeispieldata;
ssl on;
ssl_certificate /var/www/ssl/xx.crt;
ssl_certificate_key /var/www/ssl/xx.key;
return 301 goto.xxxxxxxx.com;
@kevthanewversi
kevthanewversi / delete_all_tweets.py
Created June 23, 2016 08:40 — forked from vik-y/delete_all_tweets.py
This script will delete all of the tweets in a specified account.
# -*- coding: utf-8 -*-
"""
This script is forked originally from Dave Jeffery. The original implementation
was very slow and deleted around 2 tweets per second. Making it multithreaded I
am able to delete 30-50 tweets per second.
@author: vik-y
----------------------------------------------------------------------------
This script will delete all of the tweets in the specified account.