Skip to content

Instantly share code, notes, and snippets.

Peter DeMartini peterdemartini

Block or report user

Report or block peterdemartini

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View example-message.json
{
"message": "what is the current version of meshblu?"
}
View create-meshblu-connector.sh
curl \
--fail \
--location \
--silent \
--data '{"name":"Meshblu Connector Say Hello","connector":"meshblu-connector-say-hello","type":"device:say-hello","githubSlug":"octoblu/meshblu-connector-say-hello","version": "latest"}' \
--request POST \
--header 'Content-Type: application/json' \
--user 'my-octoblu-uuid:my-octoblu-token' \
'https://connector-service.octoblu.com/users/my-octoblu-connector-uuid/connectors'
View .eslintrc.json
{
"root": true,
"extends": [
"eslint:recommended",
"prettier"
],
"rules": {
"semi": [ 2, "never" ],
"no-undefined": "error"
},
View gist:ba0dcde9f22f2560f22bbeaeb85cfa4f
http://localhost:3000/magic-link?uuid=6e0a26ac-765c-429a-bbe0-12fc7a97a80f&token=9ce75c5c6663bba7d14ba6ef120cadb23d9fb87a
@peterdemartini
peterdemartini / gist:1bbcb83a6fcf02f6a92fa28337e22fc6
Created Jan 10, 2017
Find slow queries from compose mongo logs
View gist:1bbcb83a6fcf02f6a92fa28337e22fc6
zgrep -E ".*keysExamined.*[0-9]{3,}ms" mongodb82.log-2017-01-08.gz
@peterdemartini
peterdemartini / command.sh
Last active Dec 6, 2019
Exclude node_modules in timemachine
View command.sh
find `pwd` -type d -maxdepth 3 -name 'node_modules' | xargs -n 1 tmutil addexclusion
View one-liner.js
m_objCurrentSco.TimeSession = `0000:${(Math.floor(Math.random() * (30 - 10 + 1)) + 10)}:${Math.floor(Math.random() * 55)}`; m_objCurrentSco.ScoreRaw = "100"; m_objCurrentSco.LessonStatus = "completed"; API.SetTotalTime(); API.SetPostComplete(true)
View 01-utterances.txt
Trigger {Name}
Trigger hello {Name}
Trigger hi {Name}
Trigger start {Name}
Trigger open {Name}
Trigger trigger {Name}
Trigger {Name} there is a problem
Trigger {Name} I need help
Trigger {Name} {SymptomPrefix} {Symptom}
Trigger tell the {Name} {SymptomPrefix} {Symptom}
View tmux.conf
set -g default-command /usr/local/bin/fish
set -g default-shell /usr/local/bin/fish
You can’t perform that action at this time.