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
| # -*- coding: utf-8 -*- | |
| from jsmapper import ( | |
| JSONSchema, | |
| Object, | |
| Number, | |
| 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
| >>> from jsonschema import validate | |
| >>> # A sample schema, like what we'd get from json.load() | |
| >>> schema = { | |
| ... "type" : "object", | |
| ... "properties" : { | |
| ... "price" : {"type" : "number"}, | |
| ... "name" : {"type" : "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
| # -*- coding: utf-8 -*- | |
| import json | |
| from gntp.notifier import GrowlNotifier | |
| from ws4py.client.threadedclient import WebSocketClient | |
| IMAGE_NORMAL = 'http://yosida95-ubuntu1/jenkins.png' | |
| IMAGE_ONSUCCESS = 'http://yosida95-ubuntu1/success.png' | |
| IMAGE_ONFAIL = 'http://yosida95-ubuntu1/error.png' |
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
| language: python | |
| env: | |
| matrix: | |
| - TOXENV="py33" | |
| - TOXENV="py34" | |
| - TOXENV="coverage" | |
| install: | |
| - pip install tox | |
| - if test "$TOXENV" = "coverage"; then pip install coveralls; fi | |
| script: |
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
| package main | |
| import ( | |
| "database/sql" | |
| "github.com/yosida95/orm" | |
| "github.com/yosida95/orm/cond" | |
| "log" | |
| ) | |
| type Model struct { |
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
| # -*- coding: utf-8 -*- | |
| import base64 | |
| import hashlib | |
| import hmac | |
| import json | |
| from datetime import datetime | |
| from xml.etree.ElementTree import fromstring | |
| import requests |
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
| # -*- coding: utf-8 -*- | |
| import argparse | |
| import csv | |
| import sys | |
| def get_options(): | |
| parser = argparse.ArgumentParser() | |
| parser.add_argument('--input', type=argparse.FileType('rb'), |
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
| javascript:(function(){var e=window.open(null,null,"width=480,height=300,menubar=no,toolbar=no,location=no,status=no,resizable=noscrollbars=no"),t=document.createElement("img"),n=[39,53,29,41,14,20],r=function(){var e=Math.ceil(Math.random()*6),s=Math.ceil(Math.random()*n[e-1]);t.setAttribute("src","http://mogashi.no-ip.org/alice/?ep="+e.toString()+"&no="+s.toString());setTimeout(r,1e4)};t.style.margin="0";e.document.body.style.margin="0";e.document.body.style.padding="0";e.document.body.appendChild(t);r()})() |
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
| package main | |
| import ( | |
| "fmt" | |
| "sync" | |
| ) | |
| type TableCleaner struct { | |
| dependencies map[string][]string | |
| sync.Mutex |
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
| # -*- coding: utf-8 -*- | |
| import os | |
| import random | |
| import sys | |
| import time | |
| import daemon | |
| from gntp import notifier |