Skip to content

Instantly share code, notes, and snippets.

Looking for collaborators.

Richard Eriksson sillygwailo

Looking for collaborators.
Block or report user

Report or block sillygwailo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View break-out-of-sniply-frames.user.js
// ==UserScript==
// @name Break out of frames
// @version 0.1
// @include*
// @author Richard Eriksson
// ==/UserScript==
var current_hash = window.location.hash;
var destination_url = current_hash.slice(1);
// Thank you, Stack Overflow.
View ConfigFormExampleConfigForm.php
* @file
* Contains \Drupal\configform_example\Form\ConfigFormExampleConfigForm.
namespace Drupal\configform_example\Form;
use Drupal\Core\Form\ConfigFormBase;
sillygwailo / renew-le-ssl.yml
Last active Mar 14, 2016
Ansible playblook to renew Let's Encrypt SSL
View renew-le-ssl.yml
- name: Stop Apache
service: name=httpd state=stopped
become: yes
become_user: root
- name: Renew Let's Encrypt certificate
command: ./letsencrypt-auto --agree-dev-preview --renew-by-default -t -d YOUR_DOMAIN_HERE -d YOUR_WWW_SUBDOMAIN_AND_DOMAIN_HERE --server auth
sillygwailo / demobilizer-vancouver-sun-cbc-links.patch
Created Apr 8, 2015
Add CBC and Vancouver Sun links to the Demobilizer Safari Extension
View demobilizer-vancouver-sun-cbc-links.patch

Custom Twitter Stylesheet

Craig Mod does a bigger overhaul with Twitter for Minimalists, but this will only do the following:

  • Hides promoted tweets and trends
  • Hides the useless “Expand” link that appears under every tweet
  • Tones down the blue conversation line to a barely-visible gray
  • Hides all numbers

You can add this CSS in Safari with this extension. The URL to target is*.

sillygwailo / Gruntfile.js
Created Mar 3, 2015 Grunt deployment and notification
View Gruntfile.js
module.exports = function(grunt) {
notify: {
surge: {
options: {
title: '',
message: 'Deployment complete.',
sillygwailo / gist:20c18e877f1d0569e954
Last active Aug 29, 2015
Compiling a forked Node.js module written in CoffeeScript
View gist:20c18e877f1d0569e954
  1. I have a fork of a Node.js module on GitHub that is a depenency of an app.
  2. That module is written in CoffeeScript. When 'npm install' downloads it, it doesn't compile the module. This is a problem when deploying the app to Heroku, because I can't compile it when deploying to Heroku.
  3. Furthermore, compiling the module has its own depenencies. The dependencies need to be installed before it can be installed.
  4. If I manually run 'npm install' in the forked module's directory inside node_modules, then 'grunt prepublish', everything will work.
  5. I need to automate step #4 when installing the app. How do I do that?

The app in question is If you run npm install in that directory, the slack-client module will not get compiled.

A Solution?

sillygwailo / daringfireball-no-caps.css
Last active Aug 29, 2015
Sentence case in Linked List titles and Fireball sub-headings on Daring Fireball
View daringfireball-no-caps.css
/* If you know how to edit User CSS using a browser plugin, use* as the URLs for this CSS. */
dt {
text-transform: none !important;
font-family: Verdana, "Bitstream Vera Sans", sans-serif !important;
h2 {
font-size: 1.25em !important;
text-transform: none !important;
View slack-client-minimal-example.js
1. npm install slack-client
2. Add a bot to Slack.
3. Replace the YOUR_TOKEN_HERE with the token from the bot.
4. Invite the bot to a channel to monitor.
var Slack = require('slack-client');
var options = {
sillygwailo / known-centos-7.txt
Last active Aug 29, 2015
Installing Known on Centos 7
View known-centos-7.txt
yum install httpd mariadb mariadb-server mod_php php-xmlrpc unzip php-pdo php-mysql php-xml php-gd php-mbstring
systemctl start mariadb.service
systemctl enable mariadb.service
systemctl start httpd.service
systemctl enable httpd.service
You can’t perform that action at this time.