Skip to content

Instantly share code, notes, and snippets.

View angeloh's full-sized avatar
🎯
Focusing

Angelo Huang angeloh

🎯
Focusing
View GitHub Profile
@angeloh
angeloh / my model
Created August 24, 2012 04:43
ImageInfo.java
package models;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
@angeloh
angeloh / brew-sbt
Created July 6, 2012 21:56
brew install sbt
$ brew versions sbt
$ git checkout 785f6f8 /usr/local/Library/Formula/sbt.rb
$ brew unlink sbt (if you have old verion, you might need this)
$ brew install sbt
@angeloh
angeloh / .sbtconfig
Created July 6, 2012 20:49
Pass JVM options to sbt
$ cat ~/.sbtconfig
SBT_OPTS="-XX:+CMSClassUnloadingEnabled -XX:PermSize=128M -XX:MaxPermSize=256M"
@angeloh
angeloh / signcheck.sh
Created June 1, 2012 21:31
Signature checking
#!/bin/sh
# This routine was written by "Amerefelie"
# https://www.linuxquestions.org/quest...nature-137111/
#Last updated 090507 by Andy Lavarre alavarre@gmail.com to insert comment analysis documentation
#Last edited 081231 by Amerefelieat 07:58 AM.. Reason: updated script for hash test fail.
#Usage:
# tar_verify $1
# where $1 is the name of the xxx.tar.gz file
# Name the key ring
VENDOR_KEYRING=vendors.gpg
#!/bin/bash
#
# git-svn-diff originally by (http://mojodna.net/2009/02/24/my-work-git-workflow.html)
# modified by mike@mikepearce.net
# modified by aconway@[redacted] - handle diffs that introduce new files
# modified by t.broyer@ltgt.net - fixes diffs that introduce new files
# modified by m@rkj.me - fix sed syntax issue in OS X
# modified by angeloh@apache.org - fix whitespaces
#
# Generate an SVN-compatible diff against the tip of the tracking branch
@angeloh
angeloh / CameoPatterns.scala
Last active August 29, 2015 14:21
Cameo Patterns
/*
https://www.chrisstucchio.com/blog/2013/actors_vs_futures.html
First, I'd argue that you've excluded Akka's most important use case: Distribution. I would say
"Futures for Concurrency, Actors for State or Distribution." Location transparency is one of
Akka's most important use cases - if you use Actors infront of services, then you can deploy
your application in many discrete micro-services with ease, only changing configuration. For this,
you use actorSelection and pass the path so you can work on the app as one big piece and then
deploy it as 7.
sina.com
sina.cn
126.com
163.com
yeah.net
vip.sina.com
vip.126.com
vip.21cn.com
qq.com
foxmail.com
1033edge.com
11mail.com
123.com
123box.net
123india.com
123mail.cl
123qwe.co.uk
150ml.com
15meg4free.com
163.com
#!/usr/bin/env bash
rm -rf "${HOME}/Library/Caches/CocoaPods"
rm -rf "`pwd`/Pods/"
pod update
@angeloh
angeloh / variable-property-attributes-or.html
Last active August 29, 2015 14:02
variable property attributes for ios
Credit @http://rdcworld-iphone.blogspot.in/2012/12/variable-property-attributes-or.html
Variable property attributes or Modifiers in iOS
Variable property attributes or Modifiers
Property Attributes Indicate Data Accessibility and Storage Considerations
Use Accessor Methods to Get or Set Property Values