Skip to content

Instantly share code, notes, and snippets.

@yarwelp
yarwelp / encrypted-git-repo.md
Created September 27, 2012 21:53
Transparent Git Encryption

Transparent Git Encryption

This document has been modified from its [original format][m1], which was written by Ning Shang (geek@cerias.net). It has been updated and reformatted into a [Markdown][m2] document by [Woody Gilk][m3] and [republished][m4].

Description

When working with a remote git repository which is hosted on a third-party storage server, data confidentiality sometimes becomes

@yarwelp
yarwelp / upload.sh
Created March 15, 2012 04:47
Upload eBooks as attachments to CouchDB
#!/usr/bin/env bash
# usage: ./upload.sh http[s]://user:pass@host:port/database directories...
# This script creates a new document for each directory and then uploads the
# contents of each directory as attachments to said document.
# The script was made for uploading eBooks to my CouchDB so that I can retrieve
# them no matter where I am or what device I am on, but it can easily be
# adapted to other content as well.
@yarwelp
yarwelp / permutations.py
Created December 4, 2011 10:37
Permutations (Python)
#!/usr/bin/env python
# file: permutations.py
# Copyright (c) 2011, Erik Nordstroem <contact@erikano.net>
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
@yarwelp
yarwelp / truth_table.js
Created November 29, 2011 07:17
Truth table (JavaScript)
/* js-truth_table
*
* file: truth_table.js
*
* Copyright (c) 2011, Erik Nordstroem <contact@erikano.net>
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
@yarwelp
yarwelp / polyglot.c
Created September 29, 2011 06:38
A polyglot written in C and bash
#include <stdio.h>
#include <stdlib.h> /*
# Copyright (c) 2011, Erik Nordstroem <contact[at]erikano[dot]net>
#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES