This file contains hidden or 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
| #!/usr/bin/env perl | |
| use strict; | |
| use warnings; | |
| use v5.18; | |
| use AnyEvent; | |
| my $app = sub { | |
| my $env = shift; |
This file contains hidden or 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
| import sys | |
| from google.appengine.ext import ndb | |
| keystring = sys.argv[1] | |
| key = ndb.Key(urlsafe=keystring) | |
| print "app: " + key.app() | |
| print "namespace: " + key.namespace() | |
| if key.parent(): | |
| print "parent: %s" % key.parent() |
This file contains hidden or 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
| #!/usr/bin/env perl | |
| use strict; | |
| use warnings; | |
| use feature qw/say/; | |
| my $INSTAGRAM_EPOCH = 1314220021721; # Thu Aug 24 2011 21:07:01 GMT | |
| my $id = $ARGV[0] or die 'id needed'; |
This file contains hidden or 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
| from qiskit import QuantumProgram | |
| qp = QuantumProgram() | |
| qr = qp.create_quantum_register('qr', 2) | |
| cr = qp.create_classical_register('cr', 2) | |
| qc = qp.create_circuit('Bell', [qr], [cr]) | |
| qc.h(qr[0]) | |
| qc.cx(qr[0], qr[1]) | |
| qc.measure(qr[0], cr[0]) |
This file contains hidden or 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
| app:dev_appserver.py app.yaml --logs_path=/tmp/log.db --port ${PORT} | |
| log:gaelv --logs_path=/tmp/log.db --port ${PORT} |
This file contains hidden or 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
| #!/usr/bin/env perl | |
| use strict; | |
| use warnings; | |
| use File::Find qw/find/; | |
| sub _find_packages { | |
| my $root = shift; | |
| my $pkg_path = $root . '/pkg'; | |
| my @packages; |
This file contains hidden or 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
| require 'yaml' | |
| require 'json' | |
| yaml_text = STDIN.read | |
| puts JSON.dump(YAML.load(yaml_text)) |
This file contains hidden or 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
| package main | |
| import ( | |
| "crypto" | |
| "crypto/rand" | |
| "crypto/rsa" | |
| "crypto/sha256" | |
| "crypto/x509" | |
| "encoding/base64" | |
| "encoding/json" |
This file contains hidden or 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
| base64 | sed s/+/-/g | sed s/\\//_/g | sed s/=//g |
This file contains hidden or 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
| package main | |
| import ( | |
| "encoding/base64" | |
| "encoding/json" | |
| "fmt" | |
| "os" | |
| "strings" | |
| ) |