Skip to content

Instantly share code, notes, and snippets.

View mildred's full-sized avatar

Mildred Ki'Lya mildred

View GitHub Profile
@mildred
mildred / README.md
Last active August 29, 2015 14:22
More on How to Survive the Coming Namespace Winter

More on How to Survive the Coming Namespace Winter

Introduction: custom elements

TBD

The Issue

@mildred
mildred / README.md
Created June 24, 2015 09:47
HTTP/HTML subset for respecting privacy

We can use HTTBy default, HTTP and HTML is not very respecting of our privacy. But, we could make it way better. Let's imagine that out there, there will be some privacy-respecting web servers and browers, how could we do that?

  • A privacy respecting browser should follow as much as possible the privacy subset of HTTP/HTML, and warn when websites do not respect this.
  • The browser should sandbox web views that are not affiliated. History, cookies, and every setting should not be shared at all.
  • The server should use HTTP2 Push to push the assets (including external assets) of a web page served. Any assets that are not part of the push would be considered as not found by the privacy respecting browser.
  • The browser will not attempt to fetch any resource that is not part of the HTTP2 Push
  • When validating a form, performing a XMLHttpRequest or any network access (html refresh, ...), the browser should tell the user (as all old browsers did) "The website is attempting to send information" with the choice to
@mildred
mildred / README.md
Created September 14, 2015 10:49
IPLD thoughts

We go round and round on the same topics in IPLD, so I would like to summarize them. Let's start by stating what we would like:

  • we can put raw JSON in it, and that should work
  • we would like to be compatible with JSON-LD (or at least Linked Data)
  • we want to specify a context/schema that the data is to be interpreted against
  • we would like to have easy detection for links where we concatenate each dict key from the first level to the last using / and we get a link path

These are not directly compatible with each other. We can make several decisions, and this would lead to consequences. I'd like to present it as a tree:

  • We want any arbitrary JSON we put in the system to be strictly the same (same model) as the wire format
@mildred
mildred / gist:1328468
Created October 31, 2011 18:55
failed compilation
mildred@meryl:Projects/vanilla$ git clean -fdx ~/Projects/vanilla
Removing bin/
Removing gen/
Removing libs/
Removing local.properties
mildred@meryl:Projects/vanilla$ android update project --name VanillaMusic --path . ~/Projects/vanilla
Updated local.properties
Updated file ./build.xml
mildred@meryl:Projects/vanilla$ git st ~/Projects/vanilla
# On branch master
@mildred
mildred / transform_layouts.rb
Created December 13, 2011 15:55
Jekyll plugin to have layouts transformed by Converters as well, taken from https://github.com/mojombo/jekyll/pull/351
module Jekyll
class Layout
alias old_initialize initialize
def initialize(*args)
old_initialize(*args)
self.transform
end
@mildred
mildred / gist:1583164
Created January 9, 2012 14:28
Geometry, escalier
Marches := Object clone do(
face := method(
Polygon clone declarePoints(a, b, c, d)
)
marche1 := method(
face do(
a haveXY(5cm, 2.5cm)
b haveXY(5cm, 0)
c haveXY(80cm, 0)
d haveXY(80cm, 40cm)
@mildred
mildred / gist:1607388
Created January 13, 2012 16:37
Io with views
Let's imagine the object model if we want to implement Io in Parrot.
First, create a PMC IoObject that will represent an Io object. IoObject will contain a list of slots in the
object. There will also be a VTABLE function that will implement the behaviour when the object is activated
(called). Let's call it perform for the moment.
Let's imagine an object can have different set of slots. We call each of them views. We have the
introspection view, containing a perform2 method (different from the perform above which is a VTABLE
function), a isActivable method (true for methods, false for every other objects) and other introspection
related slots. We also have the default view for normal object operation. We can imagine having other
@mildred
mildred / gist:1607820
Created January 13, 2012 18:04
Io Parrot again
#IoObject method(args)
# $1 = VTABLE(IoObject).get(IoObject, "method")
# $2 = VTABLE(IoObject).get($1, "isActivable", "0")
# $3 = $1 0#perform(args) [if $2]
# VTABLE(IoObject).call($1, "perform", args)
# $3 = $2 [otherwise]
IoObject view#method(args)
$1 = VTABLE(IoObject).get(IoObject, "method", "view")
return VTABLE($1).call($1, IoObject, args)
@mildred
mildred / create-rpm
Created January 17, 2012 10:24
Creates a RPM file either from the command-line or from a description file. The rpm contains the files in the directory specified by files variable.
#!/bin/sh
error(){
echo "$@" >&2
exit 1
}
destdir="$(pwd)"
specdir="$(pwd)"
selffile=
@mildred
mildred / lizzy.txt
Created January 24, 2012 11:07
Lizzy Syntax
var ::= exp
assign exp to var. Type of exp is set to var (type inference)
var := exp
var an already existing variable, with a type
set exp to var, check the type is correct statically
var :type := exp