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
cd ~/Library/Application\ Support | |
mkdir -p Avian/"Pristine Copy"/Bundles | |
cd Avian/Pristine\ Copy/Bundles | |
#clone groovy bundle | |
git clone https://github.com/textmate/groovy.tmbundle.git | |
#clone grails bundle | |
git clone https://github.com/textmate/groovy-grails.tmbundle.git |
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
################################################################# | |
# | |
# File: lib/api.rb | |
# | |
################################################################# | |
require 'user' # ActiveRecord model | |
# Connect to the db | |
ActiveRecord::Base.establish_connection(ENV['DATABASE_URL']) |
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
/* | |
* How to implement a session timeout in Play Framework 2 | |
* http://www.poornerd.com/2014/04/01/how-to-implement-a-session-timeout-in-play-framework-2/ | |
* | |
*/ | |
public class Secured extends Security.Authenticator { | |
public static final String UNAUTHENTICATED = "unauthenticated"; | |
public static User getLoggedInUser() { |
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
apply plugin: 'java' | |
apply plugin: 'scala' | |
// For those using Eclipse or IntelliJ IDEA | |
apply plugin: 'eclipse' | |
apply plugin: 'idea' | |
def findPlay20(){ | |
def pathEnvName = ['PATH', 'Path'].find{ System.getenv()[it] != null } | |
for(path in System.getenv()[pathEnvName].split(File.pathSeparator)){ | |
for(playExec in ['play.bat', 'play.sh', 'play']){ |
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
-- Logback: the reliable, generic, fast and flexible logging framework. | |
-- Copyright (C) 1999-2010, QOS.ch. All rights reserved. | |
-- | |
-- See http://logback.qos.ch/license.html for the applicable licensing | |
-- conditions. | |
-- This SQL script creates the required tables by ch.qos.logback.classic.db.DBAppender | |
-- | |
-- It is intended for Oracle 9i, 10g and 11g databases. Tested on version 9.2, |
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 models; | |
import java.util.ArrayList; | |
import java.util.Date; | |
import java.util.List; | |
import java.util.Random; | |
/** | |
* Sample Employee bean to demostrate simple export features | |
*/ |
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 models; | |
import java.util.ArrayList; | |
import java.util.List; | |
/** | |
* Sample Department bean to demostrate main excel export features | |
*/ | |
public class Department { | |
private String name; |
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
HAI 1.3 | |
IM IN YR fizz UPPIN YR i TIL BOTH SAEM i AN 100 | |
I HAS A i ITZ SUM OF i AN 1 BTW, ALL LUPZ START AT 0 :/ | |
I HAS A mod3 ITZ NOT MOD OF i AN 3 | |
I HAS A mod5 ITZ NOT MOD OF i AN 5 | |
mod3, O RLY?, YA RLY, VISIBLE "Fizz"!, OIC | |
mod5, O RLY?, YA RLY, VISIBLE "Buzz"!, OIC | |
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
HAI 1.2 | |
HOW DUZ I FIBONACCEH YR NUMBEH | |
I HAS A NUMBE | |
I HAS A NUMB | |
I HAS A NUMNUM | |
NUMBE R DIFF OF NUMBEH AN 1 | |
NUMB R DIFF OF NUMBE AN 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
package examples.database; | |
import com.google.common.collect.Lists; | |
import examples.database.dao.PeopleDAO; | |
import examples.database.model.PeopleInfo; | |
import org.apache.commons.lang.time.StopWatch; | |
import org.apache.commons.logging.Log; | |
import org.apache.commons.logging.LogFactory; | |
import org.junit.Test; | |
import org.junit.runner.RunWith; |