This file contains hidden or 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
package org.corespring.platform.json.transformers | |
object ItemTransformer extends JsonTransformer( | |
"taskInfo.title" -> "title", | |
"taskInfo.subjects.primary" -> "primarySubject", | |
"taskInfo.subjects.related" -> "relatedSubject", | |
"taskInfo.itemType" -> "itemType", | |
"taskInfo.gradeLevel" -> "gradeLevel", | |
"otherAlignments.keySkills" -> "keySkills", |
This file contains hidden or 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
val xml = <item name="ed" test="true" | |
xmlns="http://www.somenamespace.com" | |
xmlns:xsi="http://www.somenamespace.com/XMLSchema-instance"> | |
<blah> | |
<node>value</node> | |
</blah> | |
</item> | |
import scala.xml._ |
This file contains hidden or 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
ps aux | grep play | grep -v -E 'grep play' | awk '{ print $2 }' | xargs kill -9 |
This file contains hidden or 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
if (!Function.prototype.bind) { | |
Function.prototype.bind = function (oThis) { | |
if (typeof this !== "function") { | |
// closest thing possible to the ECMAScript 5 internal IsCallable function | |
throw new TypeError("Function.prototype.bind - what is trying to be bound is not callable"); | |
} | |
var aArgs = Array.prototype.slice.call(arguments, 1), | |
fToBind = this, | |
fNOP = function () {}, |
This file contains hidden or 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
{ | |
"name": "drag-and-drop", | |
"organization": "corespring", | |
"corespring-container-version": "0.0.1", | |
"version": "0.0.1", | |
"dependencies": { | |
"client": { | |
"angular-dragdrop": { | |
"bower_target": "latest", | |
"file" : "src/angular-dragdrop.js" |
This file contains hidden or 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
"session": { | |
"_id": { | |
"$oid": "526e5f4d30045f27468d9ad1" | |
}, | |
"components": { | |
"2": { | |
"answers": { | |
"choice": "1", | |
"landingPlace": "1" | |
} |
This file contains hidden or 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
var http = require("http"), | |
url = require("url"), | |
path = require("path"), | |
fs = require("fs") | |
port = process.argv[2] || 8888; | |
http.createServer(function(request, response) { | |
var uri = url.parse(request.url).pathname | |
, filename = path.join(process.cwd(), uri); |
This file contains hidden or 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
#!/usr/bin/env ruby | |
# Deletes buckets that match a given regex. | |
# Params: | |
# s3-key | |
# s3-secret | |
# regex | |
# | |
# Dependencies: aws-sdk ~> '1.11.3' |
This file contains hidden or 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
object partialFunctions { | |
case class Request(mode: String, item: Option[String] = None, session: Option[String] = None) | |
def someItem(m:String) : PartialFunction[Request, String] = { | |
case Request(_, Some(item), None) => m + "its some item: " + item | |
} //> someItem: (m: String)PartialFunction[partialFunctions.Request,String] | |
def someSession : PartialFunction[Request, String] = { | |
case Request(_, None, Some(session)) => "its some session: " + session |
This file contains hidden or 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
module Jekyll | |
# Compiled LESS CSS into CSS. You must specify an empty YAML front matter | |
# at the beginning of the file. | |
# .less -> .css | |
class LessConverter < Converter | |
safe true | |
priority :low | |
pygments_prefix "\n" | |
pygments_suffix "\n" |