View ErrorCase.java
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
package com.technofovea.packbsp; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.IOException; | |
import java.nio.channels.FileChannel; | |
/** | |
* This quick test shows a bug in the SUN/Oracle FileChannel class. | |
* |
View Preon46.java
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 org.codehaus.preon.Codec; | |
import org.codehaus.preon.Codecs; | |
import org.codehaus.preon.annotation.Bound; | |
import org.codehaus.preon.annotation.BoundNumber; | |
import org.codehaus.preon.annotation.If; | |
import org.junit.Assert; | |
import org.junit.Test; | |
public class Preon46 { |
View unmolder.html
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
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8"> | |
<style> | |
textarea{ | |
width:500px; | |
height:150px; | |
clear:both; | |
} | |
</style> |
View StringArrayTest.java
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 java.nio.charset.Charset; | |
import java.util.LinkedList; | |
import java.util.List; | |
import org.codehaus.preon.Codec; | |
import org.codehaus.preon.Codecs; | |
import org.codehaus.preon.DecodingException; | |
import org.codehaus.preon.annotation.BoundList; | |
import org.codehaus.preon.annotation.BoundNumber; | |
import org.codehaus.preon.annotation.BoundString; | |
import org.junit.AfterClass; |
View OverridablePropertiesConfiguration.java
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
package com.technofovea.springtest; | |
import java.io.File; | |
import java.lang.reflect.Array; | |
import java.net.URL; | |
import java.util.Collection; | |
import java.util.Iterator; | |
import org.apache.commons.configuration.Configuration; | |
import org.apache.commons.configuration.ConfigurationException; | |
import org.apache.commons.configuration.PropertiesConfiguration; |
View prepare-commit-msg
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
#!/bin/bash | |
branchPath=$(git symbolic-ref -q HEAD) #Somthing like refs/heads/myBranchName | |
branchName=${branchPath##*/} #Get text behind the last / of the branch path | |
if [[ $branchName =~ tickety([[:digit:]]+) ]]; then | |
bnum=${BASH_REMATCH[1]}; | |
heading="TICKETY-$bnum \/\/"; | |
else | |
heading="($branchName) "; |
View transcribed_html5_video.html
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
<html> | |
<head> | |
<script type="text/javascript" src="jquery-1.11.0.js"></script> | |
<style> | |
#transcript{ | |
background-color:#F0F0F0; | |
min-height:50px; | |
padding:5px; | |
} | |
#transcript span.active { |
View lockfile_check.php
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
#!/usr/bin/env php | |
<?php | |
/** | |
* If composer.json references a project that has a git directory in the vendor | |
* folder, and that depdencency is set to track the "latest" of a branch, then | |
* try to validate that the lockfile-version hasn't been outpaced. | |
*/ | |
class GitUtils{ |
View day2.py
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
#http://adventofcode.com/day/2 | |
from itertools import combinations | |
import operator | |
def wrapNeeded(dims): | |
sides = combinations(dims,2) | |
halfAreas = map(lambda (a,b): a*b, sides) | |
return sum(halfAreas)*2 + min(halfAreas) |
OlderNewer