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
diff --git a/Gentoo/www-apps/mythweb/mythweb-0.25_rc20120329.ebuild b/Gentoo/www-apps/mythweb/mythweb-0.25_rc20120329.ebuild | |
index ec2fd17..8e9edef 100644 | |
--- a/Gentoo/www-apps/mythweb/mythweb-0.25_rc20120329.ebuild | |
+++ b/Gentoo/www-apps/mythweb/mythweb-0.25_rc20120329.ebuild | |
@@ -15,8 +15,7 @@ DESCRIPTION="PHP scripts intended to manage MythTV from a web browser." | |
IUSE="" | |
KEYWORDS="~amd64 ~x86 ~ppc" | |
-RDEPEND="<dev-lang/php-5.4[curl,json,mysql,session,posix] | |
- || ( <dev-lang/php-5.3[spl,pcre] =dev-lang/php-5.3 ) |
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
diff --git a/classes/kohana/view.php b/classes/kohana/view.php | |
index 5427ad9..dbd5261 100644 | |
--- a/classes/kohana/view.php | |
+++ b/classes/kohana/view.php | |
@@ -41,7 +41,7 @@ class Kohana_View { | |
* @param array $kohana_view_data variables | |
* @return string | |
*/ | |
- protected static function capture($kohana_view_filename, array $kohana_view_data) | |
+ protected function capture($kohana_view_filename, array $kohana_view_data) |
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
def triangle(a, b, c) | |
raise TriangleError unless valid_triangle?(a,b,c) | |
[:equilateral, :isosceles, :scalene][[a,b,c].uniq.size - 1] | |
end | |
def valid_triangle?(a,b,c) | |
ax,bx,cx = [a,b,c].sort | |
ax + bx > cx | |
end |
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
[user] | |
name = Jeremy Bush | |
email = [email protected] | |
[color] | |
diff = auto | |
status = auto | |
branch = auto | |
[core] | |
autocrlf = input | |
[mergetool "diffmerge"] |
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
#!/bin/bash | |
git diff --cached --name-status | awk '$1 != "D" && $1 != "R" { print $2 }' | xargs /usr/bin/env phpcs --tab-width=4 --extensions=php --report-width=140 --ignore=target/*,www/docroot/*,test/behat/ |
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
<?php | |
/** | |
* Extension to Controller_Website that enforces authentication | |
* | |
* @package | |
* @author Jeremy Bush | |
* @copyright (c) 2011 Jeremy Bush | |
*/ | |
class Controller_Website_Authenticated extends Controller_Website | |
{ |
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
set :stages, %w(production staging) | |
set :default_stage, "staging" | |
require 'capistrano/ext/multistage' | |
# -------------------------------------------- | |
# Repository | |
# -------------------------------------------- | |
set :scm, :git # I am using git, so I specify it here | |
set :repository, "<repo>" # This is the path to the repository on the server, we pushed the code here earlier. |
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
#!/bin/sh | |
VIDEODIR=$1 | |
FILENAME=$2 | |
CHANID=$3 | |
STARTTIME=$4 | |
# Sanity checking, to make sure everything is in order. | |
if [ -z "$VIDEODIR" -o -z "$FILENAME" -o -z "$CHANID" -o -z "$STARTTIME" ]; then | |
echo "Usage: $0 <VideoDirectory> <FileName> <CHANID> <STARTTIME>" | |
fi | |
if [ ! -f "$VIDEODIR/$FILENAME" ]; then |
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
#!/bin/bash | |
MAJOR_VERSION=$1 | |
MINOR_VERSION=$2 | |
if [ $# -lt 2 ] | |
then | |
echo "Usage: $0 <MAJOR-VERSION> <MINOR-VERSION>" | |
exit | |
fi |
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
Picombo::Router.add('_default', 'home/index') | |
Picombo::Router.add('index', 'home/index') | |
Picombo::Router.add('friends', 'user/friends') | |
Picombo::Router.add('saved', 'user/saved') | |
Picombo::Router.add(Regexp.new(/photo-comments\/([0-9]+).json/), "image/comments/\\1") | |
Picombo::Router.add('html route', lambda{ |path| | |
if Regexp.new('(.+).html').match(path) | |
parts = Regexp.last_match[1].split('/') | |
{:controller => parts[0], :method => parts[1], :params => parts[2..-1]} | |
end |