Skip to content

Instantly share code, notes, and snippets.

💭
status

Leo Balter leobalter

💭
status
View GitHub Profile
View generate-stuff.py
op_list = [
("<", lambda a, b: a < b, "less-than"),
("<=", lambda a, b: a <= b, "less-than-or-equal"),
(">", lambda a, b: a > b, "greater-than"),
(">=", lambda a, b: a >= b, "greater-than-or-equal"),
]
# This is the hex representation of Number.MAX_VALUE.
max_value_digits = "0xfffffffffffff8" + "0" * 242
View example.md

my provisory gist

This is a markdown content, same as in the wiki page.

How do I set it as markdown? The file name has a .md extension.

View commands.sh
test262-harness --hostType=d8 -t 4 $(git grep --name-only --extended-regexp "verify(Not)?Configurable" test/)
test262-harness --hostPath=`which js` --hostType=jsshell -t 4 $(git grep --name-only --extended-regexp "verify(Not)?Configurable" test/)
View groupMessagesByUser.js
onst getLast = (arr, def) => (arr[arr.length - 1] || def)
const getLastUser = arr => {
const last = getLast(arr, [])
return getLast(last, {})
}
const pushIntoLast = (arr, value) => {
const last = getLast(arr, [])
last.push(value)
@leobalter
leobalter / .profile
Created Mar 26, 2017 — forked from bmhatfield/.profile
Automatic Git commit signing with GPG on OSX
View .profile
# In order for gpg to find gpg-agent, gpg-agent must be running, and there must be an env
# variable pointing GPG to the gpg-agent socket. This little script, which must be sourced
# in your shell's init script (ie, .bash_profile, .zshrc, whatever), will either start
# gpg-agent or set up the GPG_AGENT_INFO variable if it's already running.
# Add the following to your shell init to set up gpg-agent automatically for every shell
if [ -f ~/.gnupg/.gpg-agent-info ] && [ -n "$(pgrep gpg-agent)" ]; then
source ~/.gnupg/.gpg-agent-info
export GPG_AGENT_INFO
else
View gist:a122cce216ca42552e91f5ff8ab1f48b
First you need to build JSC. Since it is a module in WebKit, you can follow these instructions to get the code and learn how to build it.
https://webkit.org/getting-started/#building-webkit
After the machine setup, you can build JSC as a stand-alone CLI program running
```<path_to_webkit>/Tools/Scripts/build-jsc —release```
It will build jsc into ```<path_to_webkit>/WebKitBuild/Release```
View gist:57283b496d281d92cc159827fde4250c
test262-harness --hostPath=`which d8` --hostType=d8 --hostArgs='--harmony_regexp_property' $(git diff --cached tc39/master --diff-filter=AM --name-only test/) -t 4
test262-harness --hostPath=`which d8` --hostType=d8 $(git diff --name-only)
test262-harness $(git grep --name-only --extended-regexp 'verify(Not)?Enumerable' test/) # uses node by default
test262-harness --hostPath=`which d8` --hostType=d8 $(git diff --cached --name-only) # added files only
time test262-harness --hostType=jsshell -t 4 --hostPath=`which js` $(git grep --name-only -E 'features\: \[*+object-(rest|spread)' test/language)
View notes template.md

The following is a template for a day of notes.


July 26 2016 Meeting Notes

Alice Smith (AS), Bob McCoy (BMC), Carol Waters (CW)

Introduction

View gist:86ec2502f0716791f01d051567412113
$ test262-harness --hostType="node" test/built-ins/RegExp/*.js
fs.js:951
return binding.readdir(pathModule._makeLong(path), options.encoding);
^
Error: ENOTDIR: not a directory, scandir 'test/built-ins/RegExp/15.10.2.15-6-1.js'
at Error (native)
at Object.fs.readdirSync (fs.js:951:18)
at findTest262Root (/usr/local/lib/node_modules/test262-harness/lib/findTest262.js:32:23)
at findTest262Dir (/usr/local/lib/node_modules/test262-harness/lib/findTest262.js:21:15)
View ansible-v8.yml
# https://commondatastorage.googleapis.com/chrome-infra-docs/flat/depot_tools/docs/html/depot_tools_tutorial.html#_setting_up
- name: install Google's depot tools to fetch and sync v8
git:
repo=https://chromium.googlesource.com/chromium/tools/depot_tools.git
dest=/srv/depot_tools
- name: fetch v8
git:
repo=https://chromium.googlesource.com/v8/v8.git
You can’t perform that action at this time.