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
| > var s = "this is a string"; | |
| undefined | |
| > s.slice(-1); | |
| 'g' | |
| > s.substring(-1); | |
| 'this is a string' |
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
| Income per capita http://research.stlouisfed.org/fred2/series/NASH947PCPI | |
| obesity map http://www.tennessean.com/assets/jpg/DN15498243.JPG | |
| Metro planning department (nashville) API WSDL (SOAP) | |
| http://maps.nashville.gov/MPC_Notification/MPC_Notification.asmx |
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
| # https://github.com/heroku/heroku-pg-extras#pgbackupstransfer | |
| # create a url | |
| heroku addons:add heroku-postgresql:standard-yanari | |
| heroku pg:wait | |
| heroku pgbackups:transfer [oldbcolor] [newdbcolor] |
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
| function halpme() { curl -s "http://explainshell.com/explain/$1" --data-urlencode "args=${@:2}" -G | sed -n '/<table id="help"/,/<\/table>/p' | sed 's/ *//' | sed 's/<[^>]*>//g' | grep -v "^$" } | |
| # EX: | |
| # ~ ❯ halpme tar -xzf | |
| # The GNU version of the tar archiving utility | |
| # -x, --extract, --get | |
| # extract files from an archive | |
| # -z, --gzip, --gunzip --ungzip | |
| # -f, --file ARCHIVE | |
| # use archive file or device ARCHIVE |
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
| wget https://bitbucket.org/pypa/setuptools/raw/bootstrap/ez_setup.py -O - | python | |
| pip install -U pip |
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
| function phpargs() { | |
| curl -s http://us3.php.net/$1 | \ | |
| sed -n '/<div class="methodsynopsis dc-description">/,/<\/div>/p' | \ | |
| sed 's/<[^>]*>//g' | tr -d "\n" | |
| echo | |
| } |
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
| # see http://boto.readthedocs.org/en/latest/ref/boto.html#boto.set_stream_logger | |
| import boto | |
| boto.set_stream_logger('paws') | |
| ec2 = boto.connect_ec2(debug=2) | |
| s3 = boto.connect_s3(debug=2) |
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
| import sys | |
| import argparse | |
| import glob | |
| import subprocess | |
| import boto | |
| parser = argparse.ArgumentParser(description='Upload large (5GB+) file to Amazon S3.') | |
| parser.add_argument('--aws_access_key_id', required=True, |
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
| # select count(*); | |
| count | |
| ------- | |
| 1 | |
| (1 row) |
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/app/views/devise/shared/_links.erb b/app/views/devise/shared/_links.erb | |
| dissimilarity index 99% | |
| index 414904b..0b0b21d 100644 | |
| --- a/app/views/devise/shared/_links.erb | |
| +++ b/app/views/devise/shared/_links.erb | |
| @@ -1,19 +1,15 @@ | |
| -<%- if controller_name != 'sessions' %> | |
| - <%= link_to "Sign in", new_session_path(resource_name) %><br /> | |
| -<% end -%> | |
| - |