Skip to content

Instantly share code, notes, and snippets.

[package]
name = "rocket-contrib-test"
version = "0.1.0"
authors = ["bstpierre"]
edition = "2018"
[dependencies]
rocket_contrib = "0.4"
@bstpierre
bstpierre / keybase.md
Created May 17, 2014 00:45
Keybase proof

Keybase proof

I hereby claim:

  • I am bstpierre on github.
  • I am bstpierre (https://keybase.io/bstpierre) on keybase.
  • I have a public key whose fingerprint is F1EB B4E6 0522 43FA 7F04 C21E 82A7 B45C 435F C06B

To claim this, I am signing this object:

@bstpierre
bstpierre / hexecho
Created August 25, 2011 14:51
Dump a (binary) file as a series of hex escape sequences
#!/bin/bash
#
#
# Dump a (binary) file as a series of hex escape sequences suitable
# for bash's builtin "echo -n -e".
#
# `od -tx1` outputs each byte as two hex digits, on multiple lines,
# with each line beginning with the offset.
@bstpierre
bstpierre / cleanup_and_reraise.py
Created July 16, 2009 03:04
Python Exception Handling: Cleanup and Reraise
#!/usr/bin/python
#
# This code sample shows (what I hope to be) the right way to reraise an exception in the
# situation where you have to perform some cleanup before reraising.
#
cleaned_up = False
def raiser():
raise RuntimeError("this should be reported at line 10")