gitflow | git |
---|---|
git flow init |
git init |
git commit --allow-empty -m "Initial commit" |
|
git checkout -b develop master |
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. Backup image tags to text file. | |
# $ docker images --format "{{.Repository}}:{{.Tag}} {{.ID}}" > img_id.txt | |
# | |
# 2. Execute clean-docker-for-mac script | |
# $ bash clean-docker-for-mac.sh $(docker images --format "{{.ID}}" | xargs) | |
# | |
# source: https://gist.github.com/MrTrustor/e690ba75cefe844086f5e7da909b35ce#file-clean-docker-for-mac-sh | |
# | |
# 3. Execute this script to restore tags from text file. |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<groupId>com.example</groupId> | |
<artifactId>my-project</artifactId> | |
<version>0.0.1-SNAPSHOT</version> | |
<dependencies> | |
<!-- none yet --> |
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
(ns topoged.model.type | |
(:import | |
(javax.persistence Entity Id Column Table GeneratedValue) | |
)) | |
(definterface IType (getId [])) | |
(deftype | |
^{Entity {} Table {:name="TYPE"} org.hibernate.annotations.Entity {:mutable false}} | |
TypeX [^Long id] |
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
SC.mixin(SC.TemplateView.prototype, | |
/** @scope SC.TemplateView.prototype */{ | |
templateNameDidChange: function() { | |
SC.Logger.debug("Template name was set to " + this.get('templateName')); | |
this.rerender(); | |
}.observes('template'), | |
/** | |
Called when the template property associated with this view changes. |
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
SC.TemplateChangingView = SC.TemplateView.extend( | |
/** @scope SC.TemplateChangingView.prototype */{ | |
templateNameDidChange: function() { | |
SC.Logger.debug("Template name was set to " + this.get('templateName')); | |
this.rerender(); | |
}.observes('template'), | |
/** | |
Called when the template property associated with this view changes. |
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
import com.google.protobuf.DescriptorProtos; | |
import com.google.protobuf.Descriptors; | |
import com.google.protobuf.DynamicMessage; | |
import com.google.protobuf.Message; | |
import java.util.HashMap; | |
/** | |
* ProtobufEnvelope - allows creating a protobuf message without the .proto file dynamically. | |
* |
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 django.contrib.sessions.backends.base import SessionBase, CreateError | |
from django.conf import settings | |
from django.utils.encoding import force_unicode | |
import redis | |
class SessionStore(SessionBase): | |
""" Redis store for sessions""" | |
def __init__(self, session_key=None): | |
self.redis = redis.Redis( |
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
;; | |
;; NS CHEATSHEET | |
;; | |
;; * :require makes functions available with a namespace prefix | |
;; and optionally can refer functions to the current ns. | |
;; | |
;; * :import refers Java classes to the current namespace. | |
;; | |
;; * :refer-clojure affects availability of built-in (clojure.core) | |
;; functions. |