Skip to content

Instantly share code, notes, and snippets.

jquinter / machine.js
Last active September 3, 2020 02:47
Generated by XState Viz:
View machine.js
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
jquinter / gist:d7cd3e2451d75e67fc3d51a2a9234d2c
Created December 8, 2019 15:32 — forked from gwixted/gist:4039676
Terminal Cheatsheet
View gist:d7cd3e2451d75e67fc3d51a2a9234d2c


This contains commands shamelessly stolen from many authors. I will try to list all of them at the end of the file, but if I've missed someone, let me know.


  • UC/Use Case : a practical/frequently used example of the command in action (I find it easier to add commands into my daily workflow if I have an example that uses them in something I often do)

The Prompt

Navigating / Manipulating Text (emacs style terminal) [3]

jquinter / myViz.js
Created June 12, 2019 00:26
This is the myViz.js file obtained after step 12 in the codelab for community visualization components in datastudio
View myViz.js
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("dscc",[],t):"object"==typeof exports?exports.dscc=t():e.dscc=t()}(window,function(){return function(n){var o={};function r(e){if(o[e])return o[e].exports;var t=o[e]={i:e,l:!1,exports:{}};return n[e].call(t.exports,t,t.exports,r),t.l=!0,t.exports}return r.m=n,r.c=o,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)r.d(n,o,function(e){return t[e]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){retu
View GCP Openshift Terraform Succeeded
Warning: Permanently added '' (ECDSA) to the list of known hosts.
PLAY [localhost] ***************************************************************
TASK [debug] *******************************************************************
ok: [localhost] => {
"msg": "Install openshift cluster"
PLAY [Fail openshift_kubelet_name_override for new hosts] **********************
jquinter / Openshifter Cluster setup for jquinter
Created May 17, 2019 22:23
This is the setup I have tried on a fresh install
View Openshifter Cluster setup for jquinter
name: openshifter-cluster # file base name wihtou .yml if not specified
bastion: false # Bastioned deployment, WIP, do not use
provider: gce
type: origin # origin or ocp
release: v3.6.1 # full version for Origin; for OCP master.minor is enough
installer: ansible # currently only Ansible
#rhsm: # subscription management for OCP
# username: <username>
# pool: <id>
jquinter / gist:f69c11af9ad938f7b2fb38af8cc9b919
Created April 1, 2019 15:25 — forked from mhawksey/gist:1442370
Google Apps Script to read JSON and write to sheet
View gist:f69c11af9ad938f7b2fb38af8cc9b919
function getJSON(aUrl,sheetname) {
//var sheetname = "test";
//var aUrl = "";
var response = UrlFetchApp.fetch(aUrl); // get feed
var dataAll = JSON.parse(response.getContentText()); //
var data = dataAll.value.items;
for (i in data){
data[i].pubDate = new Date(data[i].pubDate);
data[i].start = data[i].pubDate;
jquinter / config.yml
Last active April 15, 2018 12:29
Parse YAML from bash with sed and awk.
View config.yml
adapter: mysql2
encoding: utf8
database: my_database
username: root
- somepackage
- anotherpackage
jquinter /
Last active September 15, 2019 04:08 — forked from pkuczynski/
Read YAML file from Bash script
parse_yaml() {
local prefix=$2
local s='[[:space:]]*' w='[a-zA-Z0-9_]*' fs=$(echo @|tr @ '\034'|tr -d '\015')
sed -ne "s|^\($s\)\($w\)$s:$s\"\(.*\)\"$s\$|\1$fs\2$fs\3|p" \
-e "s|^\($s\)\($w\)$s:$s\(.*\)$s\$|\1$fs\2$fs\3|p" $1 |
awk -F$fs '{
indent = length($1)/2;
vname[indent] = $2;
for (i in vname) {if (i > indent) {delete vname[i]}}
# author: Francis Byrne
# date: 2011/02/12
# Generic Script for recursively setting permissions for directories and files
# to defined or default permissions using chmod.