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
| This thread can house answer to common questions - installing Tor, how safe is Tor, etc. Hopefully that will de-clutter the front page a bit. Contribute to this guide here: https://gist.github.com/2909317 | |
| **FAQ** | |
| *How do I install Tor?* | |
| Go here: https://www.torproject.org/download/download-easy.html.en | |
| *How safe is Tor?* |
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
| var publicKey = our_data.servers['servername.com'].publicKey.join('\n'); |
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
| # Start with our base settings | |
| from .settings import * | |
| # Copy our working DB to /tmp.. | |
| from shutil import copyfile | |
| src = os.path.join(BASE_DIR, 'db.sqlite3') | |
| dst = "/tmp/db.sqlite3" | |
| copyfile(src, dst) | |
| # ..and use it! |
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
| <!-- Start of Async Drift Code --> | |
| <script> | |
| var YOUR_CODE = 'BLAH_BLAH_BLAH'; | |
| !function() { | |
| var t; | |
| if (t = window.driftt = window.drift = window.driftt || [], !t.init) return t.invoked ? void (window.console && console.error && console.error("Drift snippet included twice.")) : (t.invoked = !0, | |
| t.methods = [ "identify", "config", "track", "reset", "debug", "show", "ping", "page", "hide", "off", "on" ], | |
| t.factory = function(e) { | |
| return function() { | |
| var n; |
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 flask | |
| from zappa.async import task | |
| @task | |
| def make_pie(): | |
| """ This takes a long time! """ | |
| ingredients = get_ingredients() | |
| pie = bake(ingredients) | |
| deliver(pie) |
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 zappa.async import task_sns | |
| @task_sns |
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
| { | |
| "dev": { | |
| .. | |
| "async_source": "sns", // Source of async tasks. Defaults to "lambda" | |
| "async_resources": true, // Create the SNS topic to use. Defaults to true. | |
| .. | |
| } | |
| } |
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 zappa.async import run | |
| run(your_function, args, kwargs) # Using Lambda | |
| run(your_function, args, kwargs, service='sns') # Using SNS |
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 nodb import NoDB | |
| nodb = NoDB() | |
| nodb.bucket = "my-s3-bucket" | |
| nodb.index = "name" | |
| # Save an object! | |
| user = {"name": "Jeff", "age": 19} | |
| nodb.save(user) # True |
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
| class User(object): | |
| name = None | |
| age = None | |
| def print_name(self): | |
| print "Hi, I'm " + self.name + "!" | |
| new_user = User() | |
| new_user.name = "Jeff" | |
| new_user.age = 19 |
OlderNewer