// jQuery
$(document).ready(function() {
// code
})
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
. ~/.bashrc | |
mkdir ~/local | |
mkdir ~/node-latest-install | |
cd ~/node-latest-install | |
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
./configure --prefix=~/local | |
make install # ok, fine, this step probably takes more than 30 seconds... | |
curl https://www.npmjs.org/install.sh | sh |
Eric Bidelman has documented some of the common workflows possible with headless Chrome over in https://developers.google.com/web/updates/2017/04/headless-chrome.
If you're looking at this in 2016 and beyond, I strongly recommend investigating real headless Chrome: https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md
Windows and Mac users might find using Justin Ribeiro's Docker setup useful here while full support for these platforms is being worked out.
<select name="estados-brasil"> | |
<option value="AC">Acre</option> | |
<option value="AL">Alagoas</option> | |
<option value="AP">Amapá</option> | |
<option value="AM">Amazonas</option> | |
<option value="BA">Bahia</option> | |
<option value="CE">Ceará</option> | |
<option value="DF">Distrito Federal</option> | |
<option value="ES">Espírito Santo</option> | |
<option value="GO">Goiás</option> |
from flask import Flask | |
from flask.ext.sqlalchemy import SQLAlchemy | |
from flask.ext import admin | |
from wtforms import TextAreaField | |
from wtforms.widgets import TextArea | |
from flask.ext.admin.contrib.sqla import ModelView | |
app = Flask(__name__) | |
app.config['SECRET_KEY'] = '123456790' |
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
# Python script to find the largest files in a git repository. | |
# The general method is based on the script in this blog post: | |
# http://stubbisms.wordpress.com/2009/07/10/git-script-to-show-largest-pack-objects-and-trim-your-waist-line/ | |
# | |
# The above script worked for me, but was very slow on my 11GB repository. This version has a bunch | |
# of changes to speed things up to a more reasonable time. It takes less than a minute on repos with 250K objects. | |
# |
[ | |
{ "keys": ["ctrl+t"], "command": "phpunit_run_tests" }, | |
{ "keys": ["ctrl+shift+."], "command": "phpunit_run_all_tests" }, | |
{ "keys": ["ctrl+shift+,"], "command": "phpunit_open_class_being_tested" }, | |
{ "keys": ["ctrl+shift+1"], "command": "run_macro_file", "args": {"file": "res://Packages/User/var_dump.sublime-macro"} }, | |
{ "keys": ["ctrl+shift+2"], "command": "run_macro_file", "args": {"file": "res://Packages/User/ini_set.sublime-macro"} }, | |
{ "keys": ["ctrl+shift+3"], "command": "run_macro_file", "args": {"file": "res://Packages/User/importante.sublime-macro"} }, | |
{ "keys": ["ctrl+shift+["], "command": "bh_key", "args": { "no_outside_adj": true, "lines" : true, "plugin": { "type": ["__all__"], "command": "bh_modules.bracketselect", "args": {"select": "left"} }}}, | |
{ "keys": ["ctrl+shift+]"], "command": "bh_key", "args": { "no_outside_adj": true, "lines" : true, "plugin": { "type": ["__all__"], "command": "bh_modules.bracketselect", "args": {"select": "right"} }}}, | |
{ "keys": [ |
#!/bin/bash | |
set -e | |
# file: hooks/post-receive inside git repository. | |
$WORK_DIR=path/to/work/directory | |
$GIT_DIR=path/to/git/directory | |
git --work-tree=$WORK_DIR --git-dir=$GIT_DIR checkout -f |
Never break backcompat, keep the API nimble
An extension of SemVer with a stricter (yet more realistic) backcompat guarantee, that provides more flexibility to change the API, for libraries that are packaged and downloaded (not services accessed remotely over the Internet (see Note 4)).
var gulp = require("gulp"), | |
concat = require("gulp-concat"), | |
minify = require("gulp-minify-css"), | |
sass = require("gulp-sass"), | |
sourcemaps = require("gulp-sourcemaps"), | |
rename = require("gulp-rename"), | |
php = require("gulp-connect-php"), | |
gulpif = require("gulp-if"), | |
env = process.env.NODE_ENV || "dev"; |