Skip to content

Instantly share code, notes, and snippets.

@TravelingTechGuy
TravelingTechGuy / get_history.sh
Created May 9, 2016 14:10
Get your Chrome history as a CSV file
#!/bin/bash
# Locate the history file in your profile, and copy it to the same folder as this script.
# On Mac: ~/Library/Application\ Support/Google/Chrome/Default/History
# On Windows: C:\Users\YOUR USER NAME\AppData\Local\Google\Chrome\User Data\Default\History
sqlite3 History <<!
.headers on
.mode csv
.output out.csv
ok so adf.ly encodes url and javascript to keep away people/scripts from looking at html source and getting the link, instead of waiting for the link to become available while watching ads.
I googled around for any script that works round this but nothing that was working came up.
So I digged a bit yesterday night, and now, I'm ready to give the solution
<script>
var adflyLink, lnk;
var g_cnt = 0;
var scriptContent = document.getElementsByTagName('head')[0].innerHTML;
@andreyvit
andreyvit / tmux.md
Created June 13, 2012 03:41
tmux cheatsheet

tmux cheat sheet

(C-x means ctrl+x, M-x means alt+x)

Prefix key

The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf:

remap prefix to Control + a

@nrk
nrk / command.txt
Created April 2, 2012 19:19
Using ffprobe to get info from a file in a nice JSON format
ffprobe -v quiet -print_format json -show_format -show_streams "lolwut.mp4" > "lolwut.mp4.json"
@alanbriolat
alanbriolat / default.conf
Created September 28, 2011 14:01
nginx userdir + PHP-FPM
server {
listen 80;
server_name localhost;
# ... other default site stuff, document root, etc. ...
location ~ ^/~(?<userdir_user>.+?)(?<userdir_uri>/.*)?$ {
alias /home/$userdir_user/public_html$userdir_uri;
index index.html index.htm index.php;
autoindex on;