Skip to content

Instantly share code, notes, and snippets.

View EranSch's full-sized avatar
🤠
Yeee-haw!

Eran Schoellhorn EranSch

🤠
Yeee-haw!
View GitHub Profile
try {
// Get hostname of client
String clientName = connection.getInetAddress().getHostName()
+ "[" + threadID + "]";
// Announce connection
BizTrackMEServer.logEvent("event", clientName + " connected.");
// This streams data FROM the client
@EranSch
EranSch / .bashrc
Created January 16, 2014 04:30
Handy Git aliases, for future reference :)
alias gs='git status '
alias gd='git diff '
alias ga='git add '
alias gc='git commit '
alias glog="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative"
public class Pangram{
public static void main( String [] args ){
Pangram p = new Pangram();
p.pangramer("The quick brown fox jumps over the lazy dog.");
p.pangramer("Pack my box with five dozen liquor jugs");
p.pangramer("Saxophones quickly blew over my jazzy hair");
@EranSch
EranSch / SalesTrackerTest
Created September 10, 2013 10:42
Simple logic to create test accounts
private void testIP3( int numOfAccounts ) {
// How does 10,000 test accounts sound?
Account [] accounts = new Account[numOfAccounts];
/*
* In order to create a mix of the different subclasses, we'll use some
* simple iteration logic to rotate what's instantiated for each position
* in the array.
*/