General:
Tools | Description |
---|---|
flank | Create new intervals from the flanks of existing intervals. |
slop | Adjust the size of intervals. |
shift | Adjust the position of intervals. |
subtract | Remove intervals based on overlaps b/w two files. |
http://stackoverflow.com/questions/22667401/postgres-json-data-type-rails-query | |
http://stackoverflow.com/questions/40702813/query-on-postgres-json-array-field-in-rails | |
#payload: [{"kind"=>"person"}] | |
Segment.where("payload @> ?", [{kind: "person"}].to_json) | |
#data: {"interest"=>["music", "movies", "programming"]} | |
Segment.where("data @> ?", {"interest": ["music", "movies", "programming"]}.to_json) | |
Segment.where("data #>> '{interest, 1}' = 'movies' ") | |
Segment.where("jsonb_array_length(data->'interest') > 1") |
This issue is so infuriating that I'm going to take some time to write about it.
MOST IMPORTANT. Your local development server must be bound to IP address 0.0.0.0. Some do this by default, but many don't. You need to make sure that you run your local server with correct IP bindings. You may need to provide additional flags to your serve commands e.g. polymer serve --hostname domain.local
, hugo serve --bind 0.0.0.0
. If you use a named domain like domain.local
, it has to be defined in /etc/hosts
and pointing at 0.0.0.0.
My Parallels setting is using Shared Network, nothing special there.
Open macOS Terminal and type ifconfig
. Look for the value under vnic0
> inet
. It is typically 10.211.55.2
.
#!/bin/sh | |
if [ "$1" == "" ]; then | |
echo "Usage: $0 <folder to compress>" | |
exit | |
fi | |
NAME=`basename $1` | |
tar -c --use-compress-program=pigz -f $NAME.tar.gz $NAME |
As configured in my dotfiles.
start new:
tmux
start new with session name:
# This is the sshd server system-wide configuration file. See | |
# sshd_config(5) for more information. | |
# This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin | |
# The strategy used for options in the default sshd_config shipped with | |
# OpenSSH is to specify options with their default value where | |
# possible, but leave them commented. Uncommented options change a | |
# default value. |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
tell application "Safari" | |
repeat with theSafariWindow in windows | |
tell application "Google Chrome" to set theChromeWindow to make new window | |
repeat with theSafariTab in theSafariWindow's tabs | |
set theURL to URL of theSafariTab | |
tell application "Google Chrome" | |
set theChromeTab to make new tab at end of tabs of theChromeWindow | |
set URL of theChromeTab to theURL | |
end tell | |
end repeat |
wget http://www.openbioinformatics.org/annovar/download/annovar.latest.tar.gz.mirror | |
tar xzvf annovar.tar.gz | |
cd annovar | |
# download databases (goes to UCSC) | |
./annotate_variation.pl -buildver hg19 -downdb 1000g2010nov humandb | |
./annotate_variation.pl -buildver hg19 -downdb avsift humandb | |
./annotate_variation.pl -buildver hg19 -downdb refGene humandb | |
./annotate_variation.pl -buildver hg19 -downdb mce46way humandb/ | |
./annotate_variation.pl -buildver hg19 -downdb snp131 humandb/ |