DigitalOcean droplets
#/etc/dnsmasq.d/origin-dns.conf
server=67.207.67.2
server=67.207.67.3
db.pandas.find({}, {_id: 1, title: 1, meta: 1}).sort({insert_ts: -1}) | |
# enable featured post | |
db.pandas.update({_id: {$in: ["<uuid>"]}}, {$set: {'meta.featured': "true"}}, false, true) |
Step 1 - Config `kubectl` client to work with a new cluster | |
1. Download cluster yaml config from K8s dashboard | |
2. `export KUBECONFIG=~/.kube/config:<new yaml file>` | |
3. `kubectl config view --flatten > config.new` | |
4 Remove ~/.kube/config. Rename config.new to config | |
kubectl config get-contexts | |
kubectl config use-context <new context> | |
Step 2 - Add K8s cluster to Gitlab |
// match 5.0 up to 5.15 including + and -. Example: 5.10+ or 5.12- | |
const REGEX_5_X = RegExp(/^5\.([0-9]|1[0-5])([+-]?)$/); | |
// match 5.10x to 5.15x. Example: 5.12c | |
const REGEX_5_10_LETTER = RegExp(/^5\.(1[0-5])([abcd])(?:\/[abcd])?$/); | |
/** | |
* Test if a grade string is in valid format | |
* @param {yds} grade | |
*/ |
import { unified } from "unified"; | |
import markdown from "remark-parse"; | |
import slate, { defaultNodeTypes, serialize } from "remark-slate"; | |
const DEFAULT_HEADINGS = { | |
1: "h1", | |
2: "h2", | |
3: "h3", | |
4: "h4", | |
5: "h5", |
// createCustomNormalizingPlugin.js | |
import { getChildren } from "@udecode/plate-common"; | |
import { getPlatePluginWithOverrides, isElement } from "@udecode/plate-core"; | |
const withCustomNormalizing = (options) => (editor) => { | |
const { normalizeNode } = editor; | |
editor.normalizeNode = ([node, path]) => { | |
//console.log("#foos ", node); |
Go to https://graphiql-online.com/graphiql
Endpoint: https://api.openbeta.io
query MyQuery {
areas(filter: {field_compare: [{num: 0.5, field: density, comparison: gt}, {num: 400, field: totalClimbs, comparison: gt}], path_tokens: {tokens: "California"}}, sort: {density: -1}) {
{ | |
"data": { | |
"areas": [ | |
{ | |
"pathTokens": [ | |
"US", | |
"California", | |
"Sierra Eastside", | |
"Bishop Area", | |
"Volcanic Tablelands (Happy/Sad Boulders)", |
Top-aligned Steps saadeghi/daisyui#1041 (comment)