This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Basic usage: | |
<sitemesh srcdir="src" | |
config="myconfig.xml" | |
destdir="dest" | |
includes="*.html"/> | |
2. Includes/excludes: | |
<sitemesh srcdir="src" | |
config="myconfig.xml" | |
destdir="dest" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<sitemesh> | |
<!-- There can be multiple <mapping> elements --> | |
<!-- Apply decorator to all paths by default, unless another matches --> | |
<mapping decorator="/default-decorator.html"/> | |
<!-- More mappings, with paths. --> | |
<mapping path="/path1/*" decorator="/another-decorator.html"/> | |
<mapping path="/path1/*" decorator="/another-decorator.html"/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
testing |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
== In earlier versions of Node, HTTPS with Connect was easy == | |
var server = connect.createServer(middleware1, middleware2,...); | |
server.setSecure(crypto.createCredentials({ | |
key: myHttpsKey, | |
cert: myHttpsCert | |
})); | |
server.listen(port); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This my hilarious conversation, attempting to get a good cable price with Comcast. | |
Jessica: Hello, I'm a live product specialist. I specialize in setting up new digital services. How may I help you today? | |
You: hello, I'm trying to figure out which package i should go for to get the best internet speeds | |
Jessica: I would be happy to go over the details of our packages with you. | |
Jessica: Let's move this chat and make it a window of its own. That way, you'll still see this web page while we chat. Please click 'Move My Chat' to move it now. | |
Jessica: Thank you for moving the chat. | |
Jessica: Before we continue, may I ask if you're an existing Comcast customer? | |
You: no i'm not.. i'm just about to move into a new house | |
Jessica: The internet speed is the same in our packages, what varies is the TV options. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To find NPM dependencies, use http://search.npmjs.org/ | |
NPM_DEPS += http://registry.npmjs.org/connect/-/connect-1.5.2.tgz | |
NPM_DEPS += http://registry.npmjs.org/mime/-/mime-1.2.2.tgz | |
NPM_DEPS += http://registry.npmjs.org/qs/-/qs-0.2.0.tgz | |
NPM_DEPS += http://registry.npmjs.org/websocket-server/-/websocket-server-1.4.04.tgz | |
node_modules: Makefile | |
@rm -rf $@ | |
@mkdir -p $@ | |
@set -e; for DEP in $(NPM_DEPS); do \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "Wire.h" | |
#define DS1307_ADDRESS 0x68 | |
struct DateTime { | |
int second; | |
int minute; | |
int hour; | |
int weekDay; | |
int monthDay; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// resolution of arcs. | |
$fs = 0.2; | |
module brick(units_long, units_wide) { | |
// dimensions (adjust for different brick systems) | |
piece_length = 5; | |
piece_height = 6; | |
wall_thickness = 1; | |
blob_height = 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// A 3D printable shower door safety device. | |
// See: http://www.thingiverse.com/thing:20805 | |
// See: http://todayimade.co/items/joe-walnes-made-shower-door-safety-clip | |
// 2012, Joe Walnes, Creative Commons Attribution Share Alike, blah de blah. | |
// Render in http://openscad.org/ | |
//$fn = 24; // Smooth, but very slow rendering | |
$fn = 12; // Faster! | |
// All dimensions in mm. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from telnetlib import Telnet | |
class RedisLiteClient: | |
""" | |
Super lightweight no-frills blocking Redis client that doesn't require any additional dependencies. | |
This is a microlibrary, designed for easy copy'n'paste into a project, where you don't want to | |
rely on pip/easy_install/etc. | |
Usage: |
OlderNewer