I hereby claim:
- I am ianjosephwilson on github.
- I am ianjosephwilson (https://keybase.io/ianjosephwilson) on keybase.
- I have a public key ASBfYmsRZsAxCQF09dG8pb9nupyVl8WQFbuje2U2eY3cwwo
To claim this, I am signing this object:
# This is based on the directions at https://github.com/sass/dart-sass?tab=readme-ov-file#in-docker on 11-04-2024. | |
# Dart stage | |
FROM bufbuild/buf AS buf | |
FROM dart:stable AS dart | |
ARG DART_SASS_VERSION=1.81.0 | |
# Include Protocol Buffer binary | |
COPY --from=buf /usr/local/bin/buf /usr/local/bin/ |
from itertools import islice | |
def p_strs(items): | |
""" Generate strings that represent all the partitions of the given items. | |
Examples: | |
items = [1, 2, 3, 4] | |
assert len(items) == 4 | |
[0,0,0,0] -- [[1,2,3,4]] |
I hereby claim:
To claim this, I am signing this object:
import sys | |
def main(argv): | |
print (argv) | |
if __name__ == '__main__': | |
# The first argument is how we were called. | |
called_as = sys.argv[0] | |
# Pass actual arguments to our main function. | |
main(sys.argv[1:]) |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Page 1</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
</head> | |
<body> | |
<h1>Page 1</h1> |
""" | |
Testing out the py mini racer v8 interface with Douglas Crockford's jslint.js from http://www.jslint.com/. | |
""" | |
import sys | |
from py_mini_racer import py_mini_racer | |
HTML_PAGE_FORMAT = """<!DOCTYPE html> | |
<head> | |
<meta charset="utf-8"> |
import logging | |
from collections import namedtuple | |
#tryton_jsonrpc is a softlink to tryton.jsonrpc. | |
from tryton_jsonrpc import ServerProxy, Fault | |
from pyramid.httpexceptions import HTTPUnauthorized | |
log = logging.getLogger(__name__) |
/// <reference path="typings/angular2/angular2.d.ts" /> | |
import {Component, View, bootstrap} from 'angular2/angular2'; | |
// Annotation section | |
@Component({ | |
selector: 'my-app' | |
}) | |
@View({ |
class BatchIterator(object): | |
""" | |
Return batches of items of batch size or less from the given source. | |
Each batch is another iterator. | |
""" | |
def __init__(self, source, batch_size=900): | |
self.source_iter = iter(source) | |
self.batch_size = batch_size | |
self.stop_iteration = False |
function startWatchingTagSettings() { | |
var request = null, timeout = null, temp = null, rate = 300; | |
$scope.$watch('tagSettings', function (val, oldVal) { | |
if (val === oldVal) { | |
// Special case where we are called durining initialization. | |
return; | |
} | |
temp = val; | |
if (timeout) { | |
$timeout.cancel(timeout); |