start new:
tmux
start new with session name:
tmux new -s myname
(function(){ | |
var polyline = new google.maps.Polyline(); | |
google.maps.Polyline.prototype.closestDistanceToSegment = function(center, segment) | |
{ | |
var firstPoint, lastPoint, A, B, C, D, E, distanceAB, t, projection = this.getMap().getProjection(); | |
// The other extreme of the path | |
lastPoint = segment[0]; | |
<?xml version="1.0"?> | |
<root> | |
<devicevendordef> | |
<vendorname>VORTEX</vendorname> | |
<vendorid>0x04d9</vendorid> | |
</devicevendordef> | |
<deviceproductdef> | |
<productname>POK3R</productname> | |
<productid>0x0141</productid> |
class ShapeWriter: | |
"""Provides write support for ESRI Shapefiles.""" | |
def __init__(self, shapeType=None): | |
self._shapes = [] | |
self.fields = [] | |
self.records = [] | |
self.shapeType = shapeType | |
self.shp = None | |
self.shx = None | |
self.dbf = None |
############################## | |
# _ | |
# | |_ _ __ ___ _ ___ __ | |
# | __| '_ ` _ \| | | \ \/ / | |
# | |_| | | | | | |_| |> < | |
# \__|_| |_| |_|\__,_/_/\_\ | |
# | |
############################# | |
# | |
# COPY AND PASTE |
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>The HTML5 Herald</title> | |
<meta name="description" content="The HTML5 Herald"> | |
<meta name="author" content="SitePoint"> |
# coding=utf-8 | |
import re | |
import requests | |
from bs4 import BeautifulSoup | |
from utils import check_cache | |
from pycoders import MyHTMLParser | |
URL = 'http://us2.campaign-archive1.com/home/?u=e2e180baf855ac797ef407fc7&id=9e26887fc5' # noqa |
import sys | |
class Logger(object): | |
""" | |
this object will repalce default stdout object. | |
logging info into terminal with sys.stdout | |
save logging info into log file | |
{TODO} accept log file as argument | |
""" | |
def __init__(self): |
package main | |
import ( | |
"fmt" | |
"math" | |
) | |
func Sqrt(x float64) float64 { | |
z := 1.0 | |
for { |
#!/usr/bin/env python | |
# pip install renren | |
from renren import APIClient | |
import pprint | |
import json | |
import requests | |
def get_my_image(image_url, folder, name,): | |
img_data = requests.get(image_url).content | |
with open(name + '.jpg', 'wb') as handler: |