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
PASS_THROUGH = ('sudo password:', '[y/n]') | |
class CustomStringIO(StringIO): | |
def write(self, s, *args, **kwargs): | |
if any(pt in s.lower() for pt in PASS_THROUGH): | |
sys.__stdout__.write(s) | |
return super(CustomStringIO, self).write(s, *args, **kwargs) | |
_stored_out = CustomStringIO() |
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
calling function SlimvConnectServer() | |
line 1: let repl_buf = bufnr( g:slimv_repl_file ) | |
line 2: let repl_win = bufwinnr( repl_buf ) | |
line 3: if repl_buf == -1 || ( g:slimv_repl_split && repl_win == -1 ) | |
line 4: call SlimvOpenReplBuffer() | |
calling function SlimvConnectServer..SlimvOpenReplBuffer() |
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
(ns unit02.trees) | |
; Tree ------------------------------------------------------------------------ | |
; | |
; A tree is equivalent to a single node. | |
; A node is basically a map: | |
; | |
; {:label :foo :children [... nodes ...]} |
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
unisubs.streamer.StreamBox.prototype.transcriptScrolled_ = function(e) { | |
if (this.videoScrolling_) { | |
this.videoScrolling_ = false; | |
} else { | |
this.showResyncButton_(true); | |
this.ignoreVideoScrolling_ = true; | |
} | |
}; | |
unisubs.streamer.StreamBox.prototype.scrollIntoView_ = function(streamSub) { |
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
syn region javaScript start=+<script[^>]*type="text/javascript"[^>]*>+ keepend end=+</script>+me=s-1 contains=@htmlJavaScript,htmlCssStyleComment,htmlScriptTag,@htmlPreproc |
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/README.markdown b/README.markdown | |
index d34e76b..42029fb 100644 | |
--- a/README.markdown | |
+++ b/README.markdown | |
@@ -72,3 +72,12 @@ standard Django one, you just have to run (while the virtualenv is activated): | |
pip install werkzeug | |
And then use `./dev-runserver.sh plus` to run it. | |
+ | |
+### bpython shell |
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
>>> with time(): TeamMember.objects.count() | |
... | |
4886 | |
0.00641298294067 seconds |
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/deploy/fabfile.py b/deploy/fabfile.py | |
index 8efb13b..7f77d67 100644 | |
--- a/deploy/fabfile.py | |
+++ b/deploy/fabfile.py | |
@@ -259,6 +259,14 @@ def _git_checkout(commit): | |
run('chmod g+w -R .git 2> /dev/null; /bin/true') | |
_clear_permissions('.') | |
+def _git_checkout_branch_and_reset(commit, branch): | |
+ run('git fetch') |
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
(defn ^:export prependChild | |
[parent node] | |
(dom/insertChildAt parent node 0)) |