sudo aptitude update && sudo aptitude safe-upgrade
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
Traceback (most recent call last): | |
File "/usr/local/bin/../Cellar/python3/3.2.2/lib/python3.2/functools.py", line 176, in wrapper | |
result = cache[key] | |
KeyError: (<class 'str'>, '(^.*def\\W*)(\\w+)\\W*\\((.*)?\\):', 0) | |
During handling of the above exception, another exception occurred: | |
Traceback (most recent call last): | |
File "./pickout_fn_defs.py", line 25, in <module> | |
FnDefRe = re.compile(r'(^.*def\W*)(\w+)\W*\((.*)?\):') |
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
#!/usr/bin/env python | |
# This is a simple Twitter bot which listens to a track stream for a comma delimited | |
# list of terms/tags (PRIMARY_TRACK_LIST). From this stream, it will retweet any | |
# tweet that matches the secondary regex (SECONDARY_REGEX_FILTER). | |
# | |
# This example is a #Haiti & #Chile Twitter stream listener for TweakTheTweet syntax. | |
# | |
# Requires Python 2.6 | |
# Requires Tweepy http://github.com/joshthecoder/tweepy | |
# |
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
#!/usr/bin/python2 | |
# Quick and dirty web scraper for extracting html files of | |
# Organism information, Genome Project Information, | |
# Sequencing Information, Environmental Metadata | |
# and organism metadata | |
# from GOLD databases based on treebase taxa lists, via ncbi | |
# Saves pages in the current directory | |
from urllib2 import urlopen |
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
%s/\C\<g:NeoComplCache_EnableAtStartup\>/g:neocomplcache_enable_at_startup/ge | |
%s/\C\<g:NeoComplCache_MaxList\>/g:neocomplcache_max_list/ge | |
%s/\C\<g:NeoComplCache_MaxKeywordWidth\>/g:neocomplcache_max_keyword_width/ge | |
%s/\C\<g:NeoComplCache_MaxFilenameWidth\>/g:neocomplcache_max_filename_width/ge | |
%s/\C\<g:NeoComplCache_KeywordCompletionStartLength\>/g:neocomplcache_auto_completion_start_length/ge | |
%s/\C\<g:NeoComplCache_ManualCompletionStartLength\>/g:neocomplcache_manual_completion_start_length/ge | |
%s/\C\<g:NeoComplCache_MinKeywordLength\>/g:neocomplcache_min_keyword_length/ge | |
%s/\C\<g:NeoComplCache_MinSyntaxLength\>/g:neocomplcache_min_syntax_length/ge | |
%s/\C\<g:NeoComplCache_IgnoreCase\>/g:neocomplcache_enable_ignore_case/ge | |
%s/\C\<g:NeoComplCache_SmartCase\>/g:neocomplcache_enable_smart_case/ge |
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
%s/\C\<g:NeoComplCache_EnableAtStartup\>/g:neocomplcache_enable_at_startup/ge | |
%s/\C\<g:NeoComplCache_MaxList\>/g:neocomplcache_max_list/ge | |
%s/\C\<g:NeoComplCache_MaxKeywordWidth\>/g:neocomplcache_max_keyword_width/ge | |
%s/\C\<g:NeoComplCache_MaxFilenameWidth\>/g:neocomplcache_max_filename_width/ge | |
%s/\C\<g:NeoComplCache_KeywordCompletionStartLength\>/g:neocomplcache_auto_completion_start_length/ge | |
%s/\C\<g:NeoComplCache_ManualCompletionStartLength\>/g:neocomplcache_manual_completion_start_length/ge | |
%s/\C\<g:NeoComplCache_MinKeywordLength\>/g:neocomplcache_min_keyword_length/ge | |
%s/\C\<g:NeoComplCache_MinSyntaxLength\>/g:neocomplcache_min_syntax_length/ge | |
%s/\C\<g:NeoComplCache_IgnoreCase\>/g:neocomplcache_enable_ignore_case/ge | |
%s/\C\<g:NeoComplCache_SmartCase\>/g:neocomplcache_enable_smart_case/ge |
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
function! MarkdownFolds() | |
let thisline = getline(v:lnum) | |
if match(thisline, '^##') >= 0 | |
return ">2" | |
elseif match(thisline, '^#') >= 0 | |
return ">1" | |
else | |
return "=" | |
endif | |
endfunction |
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
" folding for Markdown headers, both styles (atx- and setex-) | |
" http://daringfireball.net/projects/markdown/syntax#header | |
" | |
" this code can be placed in file | |
" $HOME/.vim/after/ftplugin/markdown.vim | |
func! Foldexpr_markdown(lnum) | |
let l1 = getline(a:lnum) | |
if l1 =~ '^\s*$' |
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
# Shows little symbol '±' if you're currently at a git repo and '○' all other times | |
function prompt_char { | |
git branch >/dev/null 2>/dev/null && echo '±' && return | |
echo '○' | |
} | |
PROMPT=' | |
%{$fg[blue]%}%n%{$reset_color%} on %{$fg[yellow]%}%m%{$reset_color%} in %{$fg[green]%}%~%b%{$reset_color%} $(git_time_since_commit)$(check_git_prompt_info) | |
${vcs_info_msg_0_}$(prompt_char) ' |
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
# Shows little symbol '±' if you're currently at a git repo and '○' all other times | |
function prompt_char { | |
git branch >/dev/null 2>/dev/null && echo '±' && return | |
echo '○' | |
} | |
PROMPT=' | |
%{$fg[blue]%}%n%{$reset_color%} on %{$fg[yellow]%}%m%{$reset_color%} in %{$fg[green]%}%~%b%{$reset_color%} $(git_time_since_commit)$(check_git_prompt_info) | |
${vcs_info_msg_0_}$(prompt_char) ' |