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
record = @{ field ~ ("," ~ field)* } | |
field = @{ "\"" ~ (!("\"" | "\\") ~ any)* ~ "\"" | (!( "," | "\n"))* } |
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
#![feature(test)] | |
extern crate test; | |
use test::Bencher; | |
const LORUM: &'static str = r#"Lorem ipsum dolor sit amet, consectetur adipiscing | |
elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, | |
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure | |
dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur | |
sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est |
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
easyblock = 'CMakeMake' | |
name = 'Salmon' | |
version = '0.4.2' | |
homepage = 'https://github.com/COMBINE-lab/salmon' | |
description = """Salmon is a wicked-fast program to produce a highly-accurate, | |
transcript-level quantification estimates from RNA-seq 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
# Create own window instead of using desktop (required in nautilus) | |
own_window yes | |
own_window_type override | |
own_window_transparent yes | |
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager | |
# Use double buffering (reduces flicker, may not work for everyone) | |
double_buffer yes | |
# fiddle with window |
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
static int prepare_to_commit(const char *index_file, const char *prefix, | |
struct wt_status *s) | |
{ | |
struct stat statbuf; | |
int commitable, saved_color_setting; | |
struct strbuf sb = STRBUF_INIT; | |
char *buffer; | |
FILE *fp; | |
const char *hook_arg1 = NULL; | |
const char *hook_arg2 = NULL; |
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 _get_editor(): | |
"""Return a sequence of possible editor binaries for the current platform""" | |
try: | |
yield os.environ["BZR_EDITOR"], '$BZR_EDITOR' | |
except KeyError: | |
pass | |
e = config.GlobalConfig().get_editor() | |
if e is not None: | |
yield e, config.config_filename() |
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
#file: util.py | |
def system(cmd, environ={}, cwd=None, onerr=None, errprefix=None): | |
'''enhanced shell command execution. | |
run with environment maybe modified, maybe in different dir. | |
if command fails and onerr is None, return status. if ui object, | |
print error message and return status, else raise onerr object as | |
exception.''' | |
def py2shell(val): | |
'convert python object into string that is useful to shell' |