This is the haml version. If you want to use the same with erb just change haml
to erb
.
- Create you partial form example
_form.haml
(The underscore at the beginning is really important). - In you
.haml
file just write= partial("form")
.
// Usage: | |
// var buf = new Uint8Array(128); | |
// var bitstream = new BitStream(buf); | |
// bitstream.writeBits(12, 0xffff); | |
// bitstream.seekTo(0); | |
// bitstream.readBits(6); // 111111 | |
// bitstream.readBits(10); // 1111110000 | |
window.BitStream = function(uint8Array) { |
#!/bin/bash | |
# | |
# CloudyGamerLauncher by Larry Gadea | |
# Easily start/stop Paperspace and Parsec instances | |
# | |
# Make sure to fill out the variables below. For the machine id, use the | |
# 8-letter identifier for the machine on Paperspace (ex. PS8RGDUY) | |
# | |
# Note: Requires Paperspace API key (generate one in account settings) |
(ns scottdw.plot.demo | |
(:import [java.util Random] | |
[org.jzy3d.analysis AnalysisLauncher AbstractAnalysis] | |
[org.jzy3d.chart Chart] | |
[org.jzy3d.chart.factories AWTChartComponentFactory] | |
[org.jzy3d.colors Color ColorMapper] | |
[org.jzy3d.colors.colormaps ColorMapRainbow] | |
[org.jzy3d.maths Coord3d Range] | |
[org.jzy3d.plot3d.builder Builder Mapper] | |
[org.jzy3d.plot3d.builder.concrete OrthonormalGrid] |
# | |
# blob : Object from MongoDB | |
# | |
# blob.body: Buffer | |
# blob.size: length of buffer, substitute for blob.body.length | |
# blob.type: MIME (Eg. audio/x-wav) | |
# | |
# req : Object from http | |
# res : Object from http | |
# _ : Object from underscore |
Go here for the latest + some code.
An alerting engine for a metrics & monitoring system.
This is the same approach I wanted in my initial spike, only instead of writing a custom collector & using an existing alerting engine (riemann), I'm proposing using an existing collector (hekad) and writing the alerting engine.
#include <io.h> | |
#include <sys/types.h> | |
#include <sys/stat.h> | |
#include <fcntl.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
#include <windows.h> | |
#include <Share.h> | |
#include <math.h> |
#include <sys/stat.h> | |
#include <sys/mman.h> | |
#include <fcntl.h> | |
#include <unistd.h> | |
#include <stdlib.h> | |
#include <stdio.h> | |
struct xyz | |
{ | |
float x, y, z; |
@implementation NSString (HexStuff) | |
- (NSUInteger)hexValue | |
{ | |
NSUInteger i = 0; | |
// -- strip leading # | |
if( [self hasPrefix:@"#"] ) | |
i++; | |
rack-contrib | |
rack-rewrite |