Skip to content

Instantly share code, notes, and snippets.

View glyph's full-sized avatar
💭
extant

Glyph glyph

💭
extant
View GitHub Profile
@glyph
glyph / # pypy3 - 2021-02-11_16-42-11.txt
Created February 12, 2021 00:50
pypy3 on macOS 11.2 - Homebrew build logs
Homebrew build logs for pypy3 on macOS 11.2
Build date: 2021-02-11 16:42:11
@glyph
glyph / profile fragment.zsh
Last active January 19, 2023 00:53 — forked from christilden/.profile fragment
git grep and replace
gg_replace() {
if [[ "$#" -lt "2" ]]; then
echo "
Usage:
$0 term replacement file_mask
Example:
$0 cappuchino cappuccino '*.html'
";
else
@glyph
glyph / fix-osx-ssl-cert-error.txt
Last active July 25, 2019 18:32 — forked from jegger/fix-osx-ssl-cert-error.txt
Certificate validation error on mac osx pyopenssl (twisted)
# When you get an error like
# ('SSL routines', 'ssl3_get_server_certificate', 'certificate verify failed')
# when using twisted, autobahn, etc...
# on macos
# than you may have to install trust roots
# Do this by using brew:
# (install brew)
brew update
brew install [email protected] # this must match the current version that the macOS cryptography wheel is built against
class Mechanism(object):
m = MethodicalMachine()
def __init__(self):
self.value = 1
@m.state(serialized="first-state")
def first(self):
"First state."
@m.state(serialized="second-state")
def second(self):
"Second state."
class Mechanism(object):
m = MethodicalMachine()
def __init__(self):
self.value = 1
@m.state(serialized="first-state")
def first(self):
"First state."
@m.state(serialized="second-state")
def second(self):
"Second state."
@glyph
glyph / gist:aa924c45e99550e09246
Created March 8, 2015 07:39
created by github.com/tr3buchet/gister
$ touch 'a b' c d
$ for c in `echo *`; do echo "$c"; done
a
b
c
d
$ for c in `echo "*"`; do echo "$c"; done
a b
c
d
@glyph
glyph / test.rb
Created March 5, 2015 22:53
created by github.com/tr3buchet/gister
# This is a stripped-down example based on Selecta's TTY handling. We store the
# TTY state in `tty_state`, then go into an infinite loop. When the loop is
# terminated by a ^C, we try to restore the TTY state. It's important that this
# work, but it doesn't in some subtle situations, and I don't know why.
#
# Save this file as test.rb and run it via this command, where `stty` should
# successfully restore the TTY state:
# bash -c 'echo | ruby test.rb'
#
# Next, run it via this command, where `stty` should fail to restore the TTY
@glyph
glyph / gist:fcc354d38222dd9d4ae0
Created March 4, 2015 01:48
created by github.com/tr3buchet/gister
glyph@elfa:~/Projects/Mimic VE:Mimic BR:pr/103
★ python setup.py py2app
↩ Tue Mar 3 17:48:02 PST 2015
running py2app
creating /Users/glyph/Projects/Mimic/build
creating /Users/glyph/Projects/Mimic/build/bdist.macosx-10.10-intel
creating /Users/glyph/Projects/Mimic/build/bdist.macosx-10.10-intel/python2.7-semi_standalone
creating /Users/glyph/Projects/Mimic/build/bdist.macosx-10.10-intel/python2.7-semi_standalone/app
creating /Users/glyph/Projects/Mimic/build/bdist.macosx-10.10-intel/python2.7-semi_standalone/app/collect
creating /Users/glyph/Projects/Mimic/build/bdist.macosx-10.10-intel/python2.7-semi_standalone/app/temp
@glyph
glyph / gist:3936e7b3ffe9b196b6d7
Created March 4, 2015 01:13
created by github.com/tr3buchet/gister
glyph@elfa:~/Projects/Mantissa VE:Mantissa BR:master
★ trial xmantissa.test.test_people.PeopleUtilitiesTestCase.test_makeThumbnail116 ↩ Tue Mar 3 17:12:20 PST 2015
xmantissa.test.test_people
PeopleUtilitiesTestCase
test_makeThumbnail116 ... ('extremas', ((0, 119),))
('extremas', ((0, 119),))
('extremas', ((0, 119),))
('extremas', ((0, 119),))
('extremas', ((0, 119),))
('extremas', ((0, 119),))
...
{
"endpoints": [
{
"publicURL": "http://localhost:8900/mimicking/MyAPIMock-523f81/ORD/v3/248246335143936",
"region": "ORD",
"tenantId": "248246335143936"
}
],
"name": "TestResource",