Skip to content

Instantly share code, notes, and snippets.

View hippietrail's full-sized avatar

Andrew Dunbar hippietrail

  • Phong Nha
  • 17:07 (UTC +07:00)
View GitHub Profile
@hippietrail
hippietrail / ht-search-related-tags.user.js
Last active October 11, 2015 04:57
Add a "Related Tags" module to the sidebar for Search results
@hippietrail
hippietrail / ht-travel-stackexchange.user.js
Created September 10, 2012 09:32
On travel.stackexchange.com put pale red backgrounds on all tags which lack wiki excerpt
// ==UserScript==
// @name Hippietrail's travel.SE enhancements
// @description highlight tags without tag wiki excerpts
// @version 0.6
// @namespace hippietrail
// @match http://travel.stackexchange.com/*
// @match http://meta.travel.stackexchange.com/*
// ==/UserScript==
//
@hippietrail
hippietrail / currency exchange.html
Created August 6, 2012 09:26
Browser app for currency conversion supporting online and offline use, geolocation, multiple currencies, favourite currencies, etc
<html>
<head>
<meta charset="utf-8">
<!-- styles that came with the shell code -->
<style type="text/css">
body {
font-family: monospace;
font-size: 10pt;
}
@hippietrail
hippietrail / georgian reqs.html
Created February 18, 2012 11:26
Sort and normalize Georgian requested entries page of English Wiktionary
<html>
<head>
<!--Load the AJAX API-->
<style type="text/css">
</style>
<script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
// initialize stuff
// ...
@hippietrail
hippietrail / travel-se-stats.html
Created January 13, 2012 21:18
Tool to visualize stats of travel.stackexchange.com over time
<html>
<head>
<!--Load the AJAX API-->
<style type="text/css">
#input {
width:100%;
height:95%;
}
#text {
width:100%;
@hippietrail
hippietrail / travel-se-1-or-2-answers.html
Created January 4, 2012 17:16
Tool to list all questions with only 1 or 2 answers on travel.stackexchange.com
<html>
<head>
<title>Travel StackExchange / jQuery / Stack Exchange API / YQL / CORS</title>
<script id="jqs" type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script>
<style type="text/css">
.container {
width:100%;
}
.left {
width:75%;
@hippietrail
hippietrail / travel-se-airport-tags.html
Created December 23, 2011 10:27
Tool to analyse IATA airport code tags on travel.stackexchange.com
<html>
<head>
<title>Travel StackExchange / jQuery / Stack Exchange API / YQL / CORS</title>
<script id="jqs" type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"></script>
<style type="text/css">
.container {
width:100%;
}
.left {
width:75%;
@hippietrail
hippietrail / stripgutenberg.pl
Created December 22, 2010 18:59
Strip headers/footers from Project Gutenberg texts
#!/usr/bin/perl
# stripgutenberg.pl < in.txt > out.txt
#
# designed for piping
# Written by Andrew Dunbar (hippietrail), released into the public domain, Dec 2010
use strict;
my $debug = 0;
@hippietrail
hippietrail / html2txt.pl
Created December 22, 2010 18:52
Strip HTML but retain block/inline structure
#!/usr/bin/perl
# TODO img alt text?
# TODO turn into a module so randomwikipage.pl can use it
use strict;
use Encode 'decode_utf8';
use File::DosGlob;
use HTML::Parser;