Title: Committee-based BIP Acceptance Process Author: Andy Chase Status: Draft Type: Process Created: 2015-08-31
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" USEAGE: xclip -o | python chrome_xxd.py | xxd -r - [destination] | |
To access chrome's cache, go to about:cache in the address bar. | |
Make sure you copy the second section of the hex dump (the first section is the header). | |
""" | |
import sys | |
for line in sys.stdin.readlines(): | |
sys.stdout.write(line[1:].replace(" ", " ")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!python | |
""" A fairly simple way of parsing arguments without using libraries. | |
Licenced: http://creativecommons.org/publicdomain/zero/1.0/ | |
""" | |
import sys | |
def main(_=None, argument_1="", argument_2="", *args): | |
if not argument_1: | |
print("need arg 1!)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This gist demonstrates a performance issue with DiffuseMap/DiffuseColor & directional light/shadow map in JME3 | |
// Issue ticket: https://github.com/jMonkeyEngine/jmonkeyengine/issues/247 | |
// Press Z/X to shift back and forth between the textures to see the performance diffence. | |
import com.jme3.app.SimpleApplication; | |
import com.jme3.input.ChaseCamera; | |
import com.jme3.input.KeyInput; | |
import com.jme3.input.controls.AnalogListener; | |
import com.jme3.light.DirectionalLight; | |
import com.jme3.input.controls.KeyTrigger; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Google Forms Slack Notification | |
// Andy Chase <github.com/andychase> | |
// License: CC0 1.0 Universal <creativecommons.org/publicdomain/zero/1.0> | |
// Install 1: This code goes in ( tools > script editor... ) of your google docs form | |
// Install 2: ( resources > current project triggers ) ( [onSubmit], [from Form], [On form submit] ) | |
// Setup 1: Put your slack api url below | |
var POST_URL = "https://hooks.slack.com/services/"; | |
function onSubmit(e) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" Andy Chase | |
>>> [number_to_unique_tuple(i, 256) for i in [0, 1, 2, 255, 256]] | |
[(0,), (1,), (2,), (255,), (0, 1)] | |
>>> [number_to_unique_tuple(i, 256, 1) for i in [0, 1, 2, 255, 256]] | |
[(0, 0), (1, 1), (2, 2), (255, 255), (0, 1)] | |
>>> [number_to_unique_tuple(i, 256) for i in [256*2, (256*256) - 2, (256*256) - 1, 256*256]] | |
[(0, 2), (254, 253), (255, 254), (0, 0, 1)] | |
>>> s = [number_to_unique_tuple(i, 256) for i in range(0,256*256)] | |
>>> len(list(s)) | |
65536 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Use the Ubuntu Linux distro as the base for this image | |
FROM ubuntu | |
# Install necessary build tools | |
RUN apt-get update && apt-get upgrade --yes && apt-get install build-essential clang git --yes | |
# Download and install PseudoNode | |
RUN cd /root && git clone https://github.com/basil00/PseudoNode.git && cd ./PseudoNode && make | |
# These two commands enable port 8333 to be routed and start the node by default | |
EXPOSE 8333 | |
CMD ["bash", "-c", "cd /root/PseudoNode && ./pseudonode --stealth --coin=bitcoin-xt"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Route port in range to 8333 | |
for i in $(seq 40000 41000) | |
do echo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport $i -j REDIRECT --to-port 8333 && | |
echo -n "." | |
done | |
# Create bitcoin data volume | |
docker run --name=bitcoind-data -v /bitcoin busybox chown 1000:1000 /bitcoin | |
# Spin up Bitcoin XT node | |
docker run --volumes-from=bitcoind-data --name=bitcoind-node -d \ |
OlderNewer