###Sketch trial non stop
Open hosts files:
$ open /private/etc/hosts
Edit the file adding:
127.0.0.1 backend.bohemiancoding.com
127.0.0.1 bohemiancoding.sketch.analytics.s3-website-us-east-1.amazonaws.com
| // | |
| // ContentView.swift | |
| // StretchyHeader | |
| // | |
| // Created by Alexey Belousov on 01.08.2019. | |
| // Copyright © 2019 JetRockets. All rights reserved. | |
| // | |
| import SwiftUI |
###Sketch trial non stop
Open hosts files:
$ open /private/etc/hosts
Edit the file adding:
127.0.0.1 backend.bohemiancoding.com
127.0.0.1 bohemiancoding.sketch.analytics.s3-website-us-east-1.amazonaws.com
| import json, sys, numpy as np | |
| from scipy import misc, signal | |
| from PIL import Image | |
| infile, outfile, modelpath = sys.argv[1:] | |
| model = json.load(open(modelpath)) | |
| im = Image.open(infile).convert("YCbCr") | |
| im = misc.fromimage(im.resize((2*im.size[0], 2*im.size[1]), resample=Image.NEAREST)).astype("float32") | |
| planes = [np.pad(im[:,:,0], len(model), "edge") / 255.0] | |
| for step in model: | |
| o_planes = [sum([signal.convolve2d(ip, np.float32(kernel), "valid") |
$ brew install python3 # Installed at /usr/local/Cellar/python3
Check that python3 has been installed by running it at the terminal:
$ python3
>>> Python 3.7.2
get-pip.py from https://bootstrap.pypa.io/get-pip.py and install (this should already be installed if python was installed from python.org or homebrew):| #!/usr/bin/env python | |
| import zipfile | |
| import string | |
| from lxml import etree | |
| def read_docx(filepath): | |
| # todo: Add test to make sure it's a docx | |
| zfile = zipfile.ZipFile(filepath) | |
| # return the xml |
This collection of files serves as a simple static demonstration of how to post to a google spreadsheet from an external html <form> following the example by Martin Hawksey
Depreciation Warning: This code is not maintained, and should be seen as reference implementation only. If you're looking to add features or update, fork the code and update as needed.
You should be able to just open index.html in your browser and test locally.
| """ | |
| Disable registration/signup | |
| """ | |
| #models.py | |
| from allauth.account.adapter import DefaultAccountAdapter | |
| class MyAccountAdapter(DefaultAccountAdapter): | |
| def is_open_for_signup(self, request): | |
| return False | |
| // Determine if an element is in the visible viewport | |
| function isInViewport(element) { | |
| var rect = element.getBoundingClientRect(); | |
| var html = document.documentElement; | |
| return ( | |
| rect.top >= 0 && | |
| rect.left >= 0 && | |
| rect.bottom <= (window.innerHeight || html.clientHeight) && | |
| rect.right <= (window.innerWidth || html.clientWidth) | |
| ); |
| import urllib2 | |
| from django.template.defaultfilters import slugify | |
| from django.core.files.base import ContentFile | |
| from django.dispatch import receiver | |
| from avatar.models import Avatar | |
| from allauth.account.signals import user_signed_up | |
| import ebaysdk | |
| from ebaysdk import finding | |
| api = finding(siteid='EBAY-GB', appid='<REPLACE WITH YOUR OWN APPID>') | |
| api.execute('findItemsAdvanced', { | |
| 'keywords': 'laptop', | |
| 'categoryId' : ['177', '111422'], | |
| 'itemFilter': [ | |
| {'name': 'Condition', 'value': 'Used'}, |