curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash
nvm install node --reinstall-packages-from=node
| #!/bin/bash | |
| suggest() { | |
| echo "$(/Users/kolby/Code/suggest/google_suggestions.py $*)" | |
| } | |
| search() { | |
| echo "$(/Users/kolby/Code/suggest/search.py $*)" | |
| } |
| #!/usr/bin/env python3 | |
| ''' | |
| usage: google_suggestions.py [-h] [query [query ...]] | |
| positional arguments: | |
| query search string | |
| optional arguments: | |
| -h, --help show this help message and exit |
| class DictQuery(dict): | |
| ''' | |
| source: | |
| https://www.haykranen.nl/2016/02/13/handling-complex-nested-dicts-in-python/?fbclid=IwAR1QG8j1zzjTraJKQsFqf6wrvW1hV622GtWSsEOlfWCwzEZI_NBmyp9IOmk | |
| Usage: | |
| >>> # Complex Dictionary | |
| >>> animals = [ | |
| { | |
| "animal" : { | |
| "type" : "bunny" |
| # Scroll to bottom for python code | |
| # most of this is json data | |
| items = [ | |
| { | |
| "name" : { | |
| "japanese" : "マスターボール", | |
| "english" : "Master Ball", | |
| "chinese" : "大师球" | |
| }, |
| # https://probablydance.com/2016/02/27/functional-programming-is-not-popular-because-it-is-weird/ | |
| # Banana Cake recipe | |
| # source: http://allrecipes.com/Recipe/A-Number-1-Banana-Cake/ | |
| # | |
| # 1. Preheat oven to 175 degrees C. Grease and flour 2 – 8 inch round pans. | |
| # In a small bowl, whisk together flour, baking soda and salt; set aside. | |
| # | |
| # 2. In a large bowl, cream butter, white sugar and brown sugar until light and fluffy. | |
| # Beat in eggs, one at a time. Mix in the bananas. Add flour mixture alternately |
| #!/usr/bin/env python | |
| ''' | |
| imports user from csv in format: | |
| <email address>, <first name>, <last name> | |
| ''' | |
| import csv | |
| from subprocess import call as run | |
| FILE='example.csv' |
| <html> | |
| <head> | |
| <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/brython/3.7.3/brython.min.js"> </script> | |
| <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/brython/3.7.3/brython_stdlib.js"></script> | |
| </head> | |
| <body onload="brython()"> | |
| <script type="text/python"> | |
| from browser import document, alert | |
| def echo(event): |
We're going to dive into how languages interact as a stack. First, we'll download the a copy of Python and compile with GNU debugging tags enabled. I hope you're ready to watch registers in the processor flutter and C code scroll. We start by opening our favorite terminal.
Go to the directory the debugging build will be installed in
cd /opt/
| upstream php { | |
| server unix:/var/run/php/php7.2-fpm.sock; | |
| server 127.0.0.1:9000; | |
| } | |
| server { | |
| listen 80 default_server; | |
| server_name _; | |
| return 301 https://$host$request_uri; |