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
| $ git checkout master | |
| $ git merge feature_branch | |
| $ git checkout synth | |
| $ git merge master | |
| $ git checkout master | |
| $ git push origin master synth |
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
| import java.awt.Graphics2D; | |
| import java.awt.Rectangle; | |
| import java.awt.RenderingHints; | |
| import java.awt.image.BufferedImage; | |
| import java.io.File; | |
| import java.io.Serializable; | |
| import java.net.URL; | |
| import java.util.HashMap; | |
| import javax.imageio.ImageIO; |
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
| trait MySelf[A <: MySelf[_]] { | |
| def me: A | |
| } | |
| class Me extends MySelf[Me] { | |
| def me: Me = this | |
| } | |
| class I extends MySelf[I] { | |
| def me: I = this |
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
| class Foo { | |
| var bar: String = "" | |
| } | |
| val instance = new Foo | |
| locally { | |
| import instance._ | |
| bar = "Special value" | |
| } |
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
| public class Sample { | |
| static class A { | |
| private String foo; | |
| private Integer bar | |
| public A(String foo, Integer bar) { | |
| this.foo = foo; | |
| this.bar = bar; | |
| } | |
| } |
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
| def rle[A](as: Seq[A]): Seq[(Int, A)] = as match { | |
| case Seq() => Seq() | |
| case Seq(a, as @ _*) => (1 + as.takeWhile(a ==).length, a) +: rle(as.dropWhile(a ==)) | |
| } | |
| rle("AAABBCCCDDDDE") map { case (i, c) => i.toString + c } mkString |
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
| * { | |
| stroke: black, symbol(circle); | |
| stroke-width: 15px; | |
| stroke-linejoin: round; | |
| stroke-linecap: round; | |
| stroke-dasharray: 1 0, 5 35; | |
| stroke-dashoffset: 0; | |
| z-index: 0, 10; | |
| } |
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
| * { | |
| label: [strtouppercase(TITLE)]; | |
| } |
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
| [type='store'] { | |
| mark: url("http://example.com/storefront.jpeg"); | |
| } | |
| [type='restaurant'] { | |
| mark: url("http://example.com/restaurant.jpeg"); | |
| } |
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
| from django.contrib.gis.geos import GEOSGeometry | |
| import json | |
| import sys | |
| bluemarble = r"""{ | |
| "fields": { | |
| "fixed": true, | |
| "format": null, | |
| "group": "background", | |
| "layer_params": "{\"args\": [\"bluemarble\", \"http://maps.opengeo.org/geowebcache/service/wms\", {\"layers\": [\"bluemarble\"], \"tiled\": true, \"tilesOrigin\": [-20037508.34, -20037508.34], \"format\": \"image/png\"}, {\"buffer\": 0}], \"type\": \"OpenLayers.Layer.WMS\"}", |