Skip to content

Instantly share code, notes, and snippets.

Adrian Iain Lam adrianiainlam

View GitHub Profile
@adrianiainlam
adrianiainlam / gov-pr-tr.sh
Created Aug 27, 2019
HK/PRC government press release translator - fixes the gov's English mistakes
View gov-pr-tr.sh
#!/bin/bash
sed -E 's/(R|r)ule of law/\1ule by law/g' "$@"
View indicator-keyboard-led.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View zh-content-farms-list.txt
! Title: zh Content Farms List
! Redirect: https://gist.github.com/adrianiainlam/3a1d6376e2481a641b78f257d9d8f866/raw/zh-content-farms-list.txt
! Version: 20200623
! Expires: 3 days
!
! Bug reports, additions, questions, comments: Please leave a comment at
! <https://gist.github.com/adrianiainlam/3a1d6376e2481a641b78f257d9d8f866>
! or email "spam@adrianiainlam.tk".replace("spam","me").
!
! zh Content Farms List - A uBlock Origin filter consisting of
@adrianiainlam
adrianiainlam / xkcd_keyboard_nav.user.js
Last active Mar 6, 2019
xkcd keyboard nav - Navigate xkcd with your keyboard
View xkcd_keyboard_nav.user.js
/* xkcd keyboard nav - Navigate xkcd with your keyboard
*
* Copyright (c) 2015-2019 Adrian Iain Lam
* <spam@adrianiainlam.tk> s/spam/me/
*
* This program is free software. It comes without any warranty, to
* the extent permitted by applicable law. You can redistribute it
* and/or modify it under the terms of the Do What The Fuck You Want
* To Public License, Version 2, as published by Sam Hocevar. See
* http://www.wtfpl.net/txt/copying/ for more details.
@adrianiainlam
adrianiainlam / gtk.py
Last active Nov 10, 2015
Pygments lexer for C code with GTK+ types
View gtk.py
# -*- coding: utf-8 -*-
"""
pygments.lexers.gtk
~~~~~~~~~~~~~~~~~~~~~~~~
Lexers for GTK+ in C.
:copyright: Copyright 2006-2013 by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
View 9gag_NSFW_loader.user.js
/* 9gag NSFW loader - Loads 9gag NSFW posts without login
*
* Copyright (c) 2015 Adrian Iain Lam <adrianiainlam@gmail.com>
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
You can’t perform that action at this time.