$ docker run -p 8000:8000 amazon/dynamodb-local
$ aws dynamodb list-tables --endpoint-url http://docker-ip:8000
| mp3splt -q -t 10.0 -o "@n @f" The\ first\ 20\ hours\ --\ how\ to\ learn\ anything\ \|\ Josh\ Kaufman\ \|\ TEDxCSU_5MgBikgcWnY.mp3 |
| curl -s https://raw.githubusercontent.com/spring-projects/spring-framework/master/spring-web/src/main/java/org/springframework/http/HttpStatus.java | \ | |
| grep '\".*),' | \ | |
| while read line; \ | |
| do echo $line | python -c 'import re,sys; s, c, m = re.search("([\w\_]+)\((\d+),\s+\"([\w\s]+)", sys.stdin.readline()).groups(); print("{}: (\"HttpStatus.{}\", \"{}\"),".format(c, s, m))'; \ | |
| done |
| # List tags | |
| git tag -l | |
| # Delete existing tag | |
| git tag -d <tag-name> | |
| # Delete tag from remote | |
| git push origin :refs/tags/<tag-name> | |
| # New tag at HEAD |
| import boto3 | |
| import click | |
| @click.command() | |
| @click.argument("bucket") | |
| @click.argument("key") | |
| @click.option("-e", "--expiration", default=3600, type=int, help="How long this presigned URL will live for") | |
| def presign_s3(bucket, key, expiration): | |
| """ Simple utility to generate presigned URL on S3 (Default 1 hour expiration) |
| // Check to see if the user has Docker installed | |
| 'use strict'; | |
| var inquirer = require('inquirer'); | |
| var chalk = require('chalk'); | |
| var YAML = require('js-yaml'); | |
| var fs = require('fs'); | |
| console.log(chalk.yellow('Hi, a few quick questions before we start:')); |
| *{margin: 0;padding: 0;list-style: none;} | |
| body, h1, h2, h3, h4, h5, h6, hr, p, blockquote, | |
| dl, dt, dd, ul, ol, li, | |
| pre, | |
| form, fieldset, legend, button, input, textarea, | |
| th, td { | |
| margin: 0; | |
| padding: 0; | |
| } |
Make sure that Mac Firewall allows incoming connection
cd <dir>
# Start WebDAV server
sudo wfsctl start
# Check status
sudo wfsctl start
# Share current directory
sudo wfsctl share $PWD
| # Simple command | |
| "cat ...".execute().text | |
| # Parse output | |
| def dockerImages = "docker images".execute().text | |
| dockerImages.eachLine { d -> !d.contains('feature') && println(d) } | |