Skip to content

Instantly share code, notes, and snippets.

@tommie
tommie / install.yaml
Last active May 30, 2023 12:14
githubtommie/envoy-gateway manifest
---
# Source: crds/gatewayapi-crds.yaml
# Copyright 2023 The Kubernetes Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
const AA = 42;
import * as x from './a.esm.js';
console.log('x.A is', x.A); // BAD: "x.A is Object { imports: ..., scopes: {} }"
export { AA as A };
export const A = 42;
import * as x from './a.esm.js';
console.log('x.A is', x.A); // BAD: "x.A is undefined"
#!/usr/bin/python3
# -*- coding: utf-8 -*-
import array
import json
import logging
import random
import signal
import socket
import struct
@tommie
tommie / 01http-server.pl.patch
Last active October 28, 2021 10:29
Dendrite SyTest
diff --git a/tests/01http-server.pl b/tests/01http-server.pl
index eb60bf8b..d8f099b8 100644
--- a/tests/01http-server.pl
+++ b/tests/01http-server.pl
@@ -47,6 +47,9 @@ sub start_test_server_ssl {
);
}
+# List of Awaiter structs
+my @pending_awaiters;
@tommie
tommie / i3wttr
Created November 13, 2020 22:33
i3wttr
#!/usr/bin/python3
# -*- coding: utf-8 -*-
import json
import logging
import signal
import socket
import sys
import threading
import time
map>
key: value
# Comment
list-
one
two
multiline:
A long sentence
with indentation.
@tommie
tommie / Dockerfile
Last active April 20, 2017 11:41
bazelexternals -- Bazel externals extraction for Ebuild
FROM gentoo/stage3-amd64
WORKDIR /
ADD package.accept_keywords etc/portage/
RUN wget http://distfiles.gentoo.org/snapshots/portage-latest.tar.bz2 && \
bzcat /portage-latest.tar.bz2 | tar -xf - -C /usr && \
mkdir -p /usr/portage/distfiles /usr/portage/metadata /usr/portage/packages && \
rm /portage-latest.tar.bz2
@tommie
tommie / gist:89011c5ac06553d5cdb8
Last active December 6, 2023 06:08
PL2303 USB Protocol

A description of the PL2303HX USB protocol.

Control Transfers

Read Register

Read a device register value.

  • bmRequestType: IN, VENDOR, DEVICE
  • bRequest: 1
  • wValue: 80h | registerNumber
@tommie
tommie / gist:92e15c0dbe787a02d295
Created November 12, 2014 14:34
Polymer template
<!DOCTYPE html>
<html>
<head>
<title>Template</title>
<script src="http://www.polymer-project.org/components/webcomponentsjs/webcomponents.js"></script>
<link rel="import" href="http://www.polymer-project.org/components/polymer/polymer.html">
</head>
<body>
<polymer-element name="x-test">