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 os | |
from webob.dec import wsgify | |
from webob.exc import HTTPMovedPermanently | |
from paste.deploy import loadapp | |
from waitress import serve | |
@wsgify.middleware | |
def ForceSSLMiddleware(req, app): |
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
apply plugin: 'java' | |
repositories { | |
mavenCentral() | |
maven { | |
url 'http://clojars.org/repo/' | |
} | |
} | |
dependencies { |
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 pandas.core.api import Timestamp, Period | |
time_in_seconds = Timestamp('2013-03-31 22:11:19') | |
one_year_period = Period('2013') | |
time_in_seconds.to_period(one_year_period.freq) == one_year_period | |
# True |
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
Invoked with : | |
--ncalls: 5 | |
--repeats: 5 | |
------------------------------------------------------------------------------- | |
Test name | head[ms] | base[ms] | ratio | | |
------------------------------------------------------------------------------- | |
timeseries_with_format_no_exact | 447.1206 | 467.2980 | 0.9568 | |
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
Invoked with : | |
--ncalls: 5 | |
--repeats: 5 | |
------------------------------------------------------------------------------- | |
Test name | head[ms] | base[ms] | ratio | | |
------------------------------------------------------------------------------- | |
period_setitem | 8.4562 | 9.3834 | 0.9012 | |
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
====================================================================== | |
FAIL: test_greaterEqual_Raises_Value (pandas.tseries.tests.test_period.TestComparisons) | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/home/brandon/src/coins/pandas/pandas/tseries/tests/test_period.py", line 2825, in test_greaterEqual_Raises_Value | |
print(self.january1 >= 1) | |
File "/home/brandon/src/coins/pandas/pandas/util/testing.py", line 1644, in __exit__ | |
raise AssertionError("{0} not raised.".format(name)) | |
AssertionError: TypeError not raised. | |
-------------------- >> begin captured stdout << --------------------- |
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
#Print a list of URLs from sitemap.xml to stdout | |
xpath -q -e '/*/*/*/text()' sitemap.xml |
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/sh | |
read oldrev newrev refname | |
REPO="/my/repo.git" | |
BRANCH=`echo $refname | sed -n 's/^refs\/heads\///p'` | |
BRANCH_DIR="/etc/puppet/environments" | |
#Unset GIT_DIR and GIT_WORK_DIR so git chooses them by current directory | |
#Based on behaviour of git post-receive hook, undocumented | |
unset GIT_DIR |
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/sh | |
# Run in the project's root | |
git ls-files | sed 's:[^/]*$::'| sed '/^$/d' | sort -u |
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/sh | |
# Requirements: | |
# Install expect and make sure it's on your path | |
# sftp with working '-r' option | |
GIT_DIR=$1 | |
HOST=$2 | |
PASSWORD=$3 |
OlderNewer