Skip to content

Instantly share code, notes, and snippets.

View nlochschmidt's full-sized avatar

Niklas Lochschmidt nlochschmidt

View GitHub Profile
Verifying that +niklas_lochschmidt is my blockchain ID. https://onename.com/niklas_lochschmidt

Keybase proof

I hereby claim:

  • I am nlochschmidt on github.
  • I am niklas_l (https://keybase.io/niklas_l) on keybase.
  • I have a public key ASC-norIgDRUysSY7k8Yn8u77uYwDPmygpzkm4nr3Yt_ggo

To claim this, I am signing this object:

@nlochschmidt
nlochschmidt / bootstrapFieldConstructor.scala.html
Last active December 23, 2015 20:09
hack to use Play 2.2 form helper with Bootstrap 3
@(elements: views.html.helper.FieldElements)
@**************************************************
* Generate input according twitter bootsrap rules *
**************************************************@
<div class="input-group @elements.args.get('_class) @if(elements.hasErrors) {has-error}" id="@elements.args.get('_id).getOrElse(elements.id + "_field")">
<label class="sr-only" for="@elements.id">@elements.label(elements.lang)</label>
@elements.input
<div class="control-label" for="@elements.id">@elements.errors(elements.lang).mkString(", ")</div>
@nlochschmidt
nlochschmidt / travis-run-tests.sh
Last active August 29, 2015 14:05
Filter output from sbt to reduce length of CI build log
#!/usr/bin/env bash
# Licensed under the Apache License, Version 2.0
# Adapted from https://github.com/paulp/psp-std/blob/master/bin/test
runTests () {
sbt test || exit 1
echo "[info] $(date) - finished sbt test"
}
stripTerminalEscapeCodes () {