Skip to content

Instantly share code, notes, and snippets.

View aronj's full-sized avatar

Aron Janarv aronj

  • Stockholm, Sweden
View GitHub Profile
import glob
import os
import re
import time
import pandas as pd
from selenium import webdriver
from selenium.common import NoSuchElementException
from selenium.webdriver import ActionChains
from selenium.webdriver.chrome.options import Options
@aronj
aronj / update_curl.sh
Last active May 9, 2018 11:58 — forked from fideloper/update_curl.sh
Update curl on Ubuntu 14.04
#! /usr/bin/env bash
# Install any build dependencies needed for curl
sudo apt-get build-dep curl
# Get latest (as of Feb 25, 2016) libcurl
mkdir ~/curl
cd ~/curl
wget http://curl.haxx.se/download/curl-7.59.0.tar.bz2
tar -xvjf curl-7.59.0.tar.bz2
@aronj
aronj / selection-to-clipboard
Last active November 20, 2016 15:17
urxvt selection to clipboard
#!/usr/bin/env perl
# save as /usr/lib/urxvt/perl/clipboard
# in .Xdefaults: URxvt.perl-ext-common: default,matcher,selection-to-clipboard
sub on_sel_grab {
my $text = quotemeta $_[0]->selection;
$text =~ s/\n/\\n/g;
$text =~ s/\r/\\r/g;
system("echo $text|xclip -i -selection clipboard");
@aronj
aronj / run_xclip_in_terminal.py
Created September 13, 2013 22:19
This python script lets you start urxvt with the command you have in clipboard
#!/usr/bin/env python
from os import system
from subprocess import Popen, PIPE
p1 = Popen(["xclip", "-o"], stdout=PIPE)
command = p1.communicate()[0]
system("urxvt -e sh -c \"" + command + " && zsh\"")