Skip to content

Instantly share code, notes, and snippets.

View pgherveou's full-sized avatar

PG Herveou pgherveou

View GitHub Profile
task 'kkprint', 'print jobs', (opts, cb = noop) ->
return if config.env is 'production'
queue = require './lib/services/queue'
queue.fetch 'job', (err, jobs) ->
jobs.each (job) -> logger.info "#{moment(job.get 'created').format('MMM Do hh:mm');} - job:#{job.id} - [#{job.get 'status'}][#{job.get 'task'}]", job.get('data')
queue._store.client.end()
task 'kkclean', 'flush kinetik jobs', (opts, cb = noop) ->
return if config.env is 'production'
queue = require './lib/services/queue'
@pgherveou
pgherveou / gist:3070261
Created July 8, 2012 09:55
node.js Forever makefile
# global environment variable
ENV = NODE_ENV=production
# log files
OUT_FILE = $(LOG_DIR)/forever-$(@)-out.log
LOG_FILE = $(LOG_DIR)/forever-$(@)-log.log
ERR_FILE = $(LOG_DIR)/forever-$(@)-err.log
# other forever constants
@pgherveou
pgherveou / gist:3070268
Created July 8, 2012 09:55
node.js Forever makefile
# global environment variable
ENV = NODE_ENV=production
# log files
OUT_FILE = $(LOG_DIR)/forever-$(@)-out.log
LOG_FILE = $(LOG_DIR)/forever-$(@)-log.log
ERR_FILE = $(LOG_DIR)/forever-$(@)-err.log
# other forever constants
MIN_UP_TIME = 5000
/**
* Switch
*/
body {
font-family: "Helvetica Neue",sans-serif;
}
.switch {
width: 74px ;
height: 35px;
/**
* Switch
*/
body {
font-family: "Helvetica Neue",sans-serif;
}
.switch {
width: 74px ;
height: 35px;
@pgherveou
pgherveou / dabblet.css
Created November 15, 2012 00:24
Untitled
.wrap {
width: 400px; height: 200px;
border: 1px solid black;
}
div {
display: box;
box-flex: 1;
}
@pgherveou
pgherveou / dabblet.html
Created December 13, 2012 17:24
Untitled
<input type="datetime" />
<input type="tel" />
@pgherveou
pgherveou / dabblet.css
Created December 17, 2012 17:34
Untitled
button {
font-size: 13px;
line-height: 36px;
font-family: sans-serif;
font-weight: bold;
color: #fff;
padding: 0 15px;
border: solid 1px;
border-color: #2978B0 #266FA5 #1C557D;
border-radius: 3px;
body {
margin: 0;
padding: 0;
border: 1px solid black;
height: 600px;
font: 13px/1.25 "Helvetica Neue", sans-serif
width: 100%;
overflow: hidden;
}
body {
margin: 0;
padding: 0;
border: 1px solid black;
height: 600px;
font: 13px/1.25 "Helvetica Neue", sans-serif
width: 100%;
overflow: hidden;
}