Skip to content

Instantly share code, notes, and snippets.

View hoffmanc's full-sized avatar

Chris Hoffman hoffmanc

View GitHub Profile
ralfw / Dockerfile
Created August 18, 2016 06:31
Roll your own Elm Docker container
# Build image with Node.js, Elm and Nginx
FROM debian:latest
# prepare
RUN apt-get -y update
RUN apt-get -y install apt-utils
# install curl,
RUN apt-get -y install curl
jameshfisher /
Created April 12, 2014 17:44
Restore a file from the package that provides it.
# Usage:
# sudo ./ <filepath>
# Restore a file from the package that provides it.
# Source:
servel333 / wget.rb
Last active July 30, 2022 14:26
Basic Ruby implementation of wget to fetch a file from the internet.
def wget(url,file)
require 'net/http'
require 'uri'
if (!file)
file = File.basename(url)
url = URI.parse(url)
Net::HTTP.start( do |http|
mudge / en.rb
Last active September 5, 2023 09:32
Using date ordinals in Rails through an I18n time format.
# This goes in config/locales/en.rb (*not* en.yml)
:en => {
:time => {
:formats => {
:full => lambda { |time, _| "%H:%M | %A, #{} %B %Y" }
Tarrasch /
Last active September 12, 2016 18:14
Unity plus xmonad configuration (Ubuntu 12.04)


This is my xmonad+unity panel config. With this config, you'll have a well integrated panel from unity but still have xmonad as your window manager with your gnome apps, including the pretty gnome-terminal (for those too lazy to learn xmoobar).

This config doesn't have the unity launcher, mainly becuse it causes windows to be unfloatable, besides I'm not fond of it anymore.


Copy and paste these lines (or understand what it does and do it manually).