Skip to content

Instantly share code, notes, and snippets.

Avatar

Teppei Sato teppeis

View GitHub Profile
View connect-airpods.sh
# derived from https://yoshiori.hatenablog.com/entry/2021/04/13/171405
AIR_PODS_ADDRESS="aa-aa-aa-aa-aa-aa"
AIR_PODS_NAME="XXX AirPods Pro"
/usr/local/bin/bluetoothconnector -c $AIR_PODS_ADDRESS
for ((i=0 ; i<10 ; i++))
do
if [ "Connected" == "$(/usr/local/bin/bluetoothconnector -s $AIR_PODS_ADDRESS)" ]; then
# sleep 0.5
View gist:4fd9b99fbd55239e31e7706caa5236f9
// taze: Set from //third_party/javascript/node_modules/typescript:es2015.collection
import * as fs from 'fs'; // from //third_party/javascript/typings/node
import * as ts from 'typescript';
function load(fileName: string, names: Set<string>) {
const text = fs.readFileSync(fileName, 'utf8');
const sf = ts.createSourceFile(fileName, text, ts.ScriptTarget.ES5, true);
sf.forEachChild((node) => {
switch (node.kind) {
View 11570061.log
Renovate logo
repos : kintone/plugin-packer #11570061
INFO: Renovating repository
DEBUG: assignPlatform
DEBUG: initRepo("kintone/plugin-packer")
DEBUG: Setting token in env for use by gh-got
DEBUG: Resetting platform config
DEBUG: GET repos/kintone/plugin-packer [retries=5]
DEBUG: kintone/plugin-packer owner = kintone
DEBUG: GET repos/kintone/plugin-packer/git/refs/heads/master [retries=5]
View keybase.md

Keybase proof

I hereby claim:

  • I am teppeis on github.
  • I am teppeis (https://keybase.io/teppeis) on keybase.
  • I have a public key whose fingerprint is D017 16FE 42BE D344 AAE2 00FE EE91 7B25 B729 B849

To claim this, I am signing this object:

@teppeis
teppeis / array_copywithin_test.js
Last active Apr 22, 2018
Testing Closure Compiler's polyfill with Test262 suite
View array_copywithin_test.js
'use strict';
const test262 = require('./test262_util');
test262.builtins('Array.prototype.copyWithin');
@teppeis
teppeis / README.md
Created Mar 15, 2018 — forked from prog893/README.md
ECS Container Instance scale-in protector
View README.md
@teppeis
teppeis / coverage.js
Created Feb 27, 2018 — forked from ebidel/coverage.js
CSS/JS code coverage during lifecycle of page load
View coverage.js
/**
* @author ebidel@ (Eric Bidelman)
* License Apache-2.0
*
* Shows how to use Puppeeteer's code coverage API to measure CSS/JS coverage across
* different points of time during loading. Great for determining if a lazy loading strategy
* is paying off or working correctly.
*
* Install:
* npm i puppeteer chalk cli-table
View closure-library-npmignore.diff
--- original.list 2018-01-01 16:53:53.000000000 +0900
+++ npmignore.list 2018-01-01 16:54:01.000000000 +0900
@@ -1,28 +1,16 @@
-package/.travis.yml
package/AUTHORS
package/CONTRIBUTING
package/LICENSE
package/README.md
-package/all_tests.html
-package/alltests.js
@teppeis
teppeis / closure.d.ts
Created Nov 13, 2017 — forked from orian/closure.d.ts
A Google Closure Library DefinitelyTyped typings
View closure.d.ts
//!! Processing provides [] from input tools/closure-compiler/externs/browser/w3c_eventsource.js
//!! Processing provides [goog.labs.userAgent.engine] from input closure-library/closure/goog/labs/useragent/engine.js
//!! Processing provides [goog.html.TrustedResourceUrl] from input closure-library/closure/goog/html/trustedresourceurl.js
//!! Processing provides [goog.events.EventId] from input closure-library/closure/goog/events/eventid.js
//!! Processing provides [goog.html.SafeUrl] from input closure-library/closure/goog/html/safeurl.js
//!! Processing provides [] from input tools/closure-compiler/externs/browser/intl.js
//!! Processing provides [] from input tools/closure-compiler/externs/browser/w3c_pointerlock.js
//!! Processing provides [goog.dom.vendor] from input closure-library/closure/goog/dom/vendor.js
//!! Processing provides [] from input tools/closure-compiler/externs/browser/w3c_vibration.js
//!! Processing provides [] from input tools/closure-compiler/externs/browser/webkit_notifications.js
@teppeis
teppeis / safari-nomodule.js
Last active Sep 18, 2017 — forked from samthor/safari-nomodule.js
Safari 10.1 `nomodule` support
View safari-nomodule.js
/**
* Safari 10.1 supports modules, but does not support the `nomodule` attribute - it will
* load <script nomodule> anyway. This snippet solve this problem, but only for script
* tags that load external code, e.g.: <script nomodule src="nomodule.js"></script>
*
* Again: this will **not** prevent inline script, e.g.:
* <script nomodule>alert('no modules');</script>.
*
* This workaround is possible because Safari supports the non-standard 'beforeload' event.
* This allows us to trap the module and nomodule load.