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
license: mit | |
height: 620 | |
scrolling: no | |
border: no |
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
height: 700 |
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
# Tweak the existing Logging integration to work with Logbook. | |
# Mostly copy-paste from https://github.com/getsentry/sentry-python/blob/master/sentry_sdk/integrations/logging.py | |
# | |
# Usage: | |
# | |
# StreamHandler(sys.stdout, level="INFO").push_application() | |
# SentryErrorHandler(bubble=True, level='ERROR').push_application() | |
# SentryBreadcrumbHandler(bubble=True, level='INFO').push_application() | |
# |
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
import json | |
import sqlalchemy | |
from sqlalchemy import UnicodeText | |
from sqlalchemy.ext.mutable import Mutable | |
from datetime import datetime | |
from collections import OrderedDict | |
__all__ = ('JSON', 'JsonRaw') |
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
#!/bin/sh | |
# Installs tarsnap client on Debian and Ubuntu | |
# | |
# You'll need to setup an account at | |
# http://www.tarsnap.com | |
# and load it with some funds | |
# | |
# Make sure you run this as root | |
# |
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
// When logged in, go to "Settings > Checkout > Checkout Language", click the "View and customize this translation" link. | |
// A page with a url like this opens: "https://yourshop.myshopify.com/admin/settings/locales/[locale_id]". | |
// copy [locale_id]. | |
// Go Back and choose "create a new one". | |
// Open the Javascript console, paste this (change to your shop/locale_id first): |
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
""" | |
Usage with the following directory structure : :: | |
sources/ | |
js/ | |
css/ | |
images/ | |
_build/ | |
static/ | |
css/ |
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
class ServerRack(object): | |
"""Manages multiple gevent Servers. Works with anything that has | |
start() and stop() methods. | |
Adapted from: | |
https://gist.github.com/1008826 | |
""" | |
def __init__(self): | |
self._servers = [] |