Skip to content

Instantly share code, notes, and snippets.

extern mod std;
use std::base64::ToBase64;
use core::str::Clone;
fn hex_to_base64(source: &str) -> ~str {
let bytes = str::to_bytes(source);
let mut nums: ~[u8] = ~[];
for uint::range_step(0, bytes.len(), 2) |i| {
let num = u8::parse_bytes(bytes.slice(i, i+2), 16);
View gist:2927486
git diff --quiet HEAD
if [[ "$?" != "0" ]]; then
echo "Cannot push to try with uncommitted changes."
exit 1
git push -f mozilla HEAD:try
You can’t perform that action at this time.