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.util.LinkedList; | |
/** | |
* This class allows the calculation of a mathematical formula | |
*/ | |
public class Formula { | |
private String formula; | |
private double result; | |
/** |
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.util.*; | |
/** | |
* B+ Tree generic type | |
* | |
* @author Sofian Benaissa | |
*/ | |
public class BplusTree<K extends Comparable<K>,V> | |
{ |
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
/** | |
* @file | |
* This file is an example of ways to modify etherpad-lite behaviour from the | |
* static/custom/pad.js file generated by etherpad-lite on first run. | |
*/ | |
var edBod = []; | |
var lastLine = 0; | |
/** |
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
// ==UserScript== | |
// @name Koumbit LedgerSMB billing workflow | |
// @match https://ledger.koumbit.net/* | |
// ==/UserScript== | |
/** | |
* @file | |
* Email templates and interface tweaks for ledger SMB emails | |
* | |
* Licensed under GPLv2. |
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
# WARNING: This should be used in private, dev environments ONLY | |
# Not for production environments | |
# | |
# This files adjusts the aegir users bash environment to make certain | |
# common development tasks a little easier | |
# Make sure aegir files are group=-writable | |
umask 0002 | |
# Aliases to make development a little easier |
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 45eaed831098fe253b0089517b3bdc8ac51f8d66 Mon Sep 17 00:00:00 2001 | |
From: Sofian Benaissa <[email protected]> | |
Date: Wed, 26 Oct 2011 13:48:54 -0400 | |
Subject: [PATCH] ereg to preg in file.inc | |
--- | |
includes/file.inc | 2 +- | |
1 files changed, 1 insertions(+), 1 deletions(-) | |
diff --git a/includes/file.inc b/includes/file.inc |
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
/** | |
* Paste this code into your greasemonkey or browser console to enable | |
* deep defense against redmine's stealth mode | |
*/ | |
stealthButton = document.getElementById('stealth_toggle'); | |
blonk = 0 | |
if (stealthButton.innerHTML == 'Disable stealth mode') | |
{ | |
setInterval ('blink(stealthButton)', 500); |
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
<?php | |
/** | |
* Node preprocess function | |
*/ | |
function mytheme_preprocess_node(&$vars, $hook) { | |
if ($vars['node']->field_image && !empty($vars['node']->field_image)) { | |
$vars['image_carousel'] = _mytheme_generate_carousel($vars['node']->field_image); | |
} | |
} |
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
// Initialize some variables - we will use GMT times | |
var checkDate = new Date(); | |
var offTheHourStarts = 21; | |
var offTheHourEnds = 22; | |
// Adjust for Daylight savings | |
if ((checkDate.getMonth() < 2 && checkDate.getMonth() > 10) || (checkDate.getMonth() == 2 && checkDate.getDate()-checkDate.getDay() > 7 ) || (checkDate.getMonth() == 10 && checkDate.getDate()-checkDate.getDay() > 1)) { | |
offTheHourStarts--; | |
offTheHourEnds--; | |
} |