#Getting Started
##Webpage:
<html>
<head>
<title>Testing with Ruby and Selenium WebDriver</title>
</head>
<body bgcolor="antiquewhite">
#Getting Started
##Webpage:
<html>
<head>
<title>Testing with Ruby and Selenium WebDriver</title>
</head>
<body bgcolor="antiquewhite">
git add HISTORY.md
git commit -m "Changelog for upcoming release 0.1.1."
bumpversion patch
| """ | |
| "Fixing common Unicode mistakes with Python — after they’ve been made" | |
| Adapted for use in Python 3.x from: | |
| http://blog.luminoso.com/2012/08/20/fix-unicode-mistakes-with-python/ | |
| """ | |
| def fix_bad_unicode(text): | |
| u""" |
| <?php | |
| # Configure | |
| $DB_USER = 'admin'; | |
| $DB_PASS = 'qwerty'; | |
| $DB_HOST = 'localhost'; | |
| $DB_NAME = 'postgis-2-0'; | |
| // Param 3 when ran in shell will override this value | |
| $DB_TABLE = 'public.florida_establishments_garman'; | |
| // Param 2 when ran in shell will override this value | |
| $CATEGORY = 'misc'; |
| #!/usr/bin/python | |
| # | |
| # K-means clustering using Lloyd's algorithm in pure Python. | |
| # Written by Lars Buitinck. This code is in the public domain. | |
| # | |
| # The main program runs the clustering algorithm on a bunch of text documents | |
| # specified as command-line arguments. These documents are first converted to | |
| # sparse vectors, represented as lists of (index, value) pairs. | |
| from collections import defaultdict |
GitHub webhooks for a URL by default only fire on repo pushes. There appears to be no way in the web UI to set up webhooks for other events. And so we go to the API. I prefer to do this type of thing with Hurl.
{
"name": "web",
"active": true,
| .DS_Store | |
| *.log | |
| Gemfile.lock |
| #See: http://daringfireball.net/2010/07/improved_regex_for_matching_urls | |
| import re, urllib | |
| GRUBER_URLINTEXT_PAT = re.compile(ur'(?i)\b((?:https?://|www\d{0,3}[.]|[a-z0-9.\-]+[.][a-z]{2,4}/)(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:\'".,<>?\xab\xbb\u201c\u201d\u2018\u2019]))') | |
| for line in urllib.urlopen("http://daringfireball.net/misc/2010/07/url-matching-regex-test-data.text"): | |
| print [ mgroups[0] for mgroups in GRUBER_URLINTEXT_PAT.findall(line) ] |
| #!/usr/bin/env ruby | |
| require 'rubygems' | |
| require 'bundler' | |
| require 'fileutils' | |
| require 'net/http' | |
| require 'net/https' | |
| require 'uri' | |
| TMP_DIR = "/tmp/gems" |