Skip to content

Instantly share code, notes, and snippets.

View evilbuck's full-sized avatar

Evil Buck evilbuck

  • evilbuck llc
  • Hobe Sound, FL
View GitHub Profile
(function() {
console.log('this does nothing');
}).call(this);
{
"_id": 2,
"conditionals": [
{
"_id": "532caaf4f308b558e8000002",
"optionId": 154,
"questionIds": [
43,
44,
45,
@evilbuck
evilbuck / bash bookmarks
Created January 17, 2012 16:14
bookmark for bash
function s {
cat ~/.sdirs | grep -v "export DIR_$1=" > ~/.sdirs1
mv ~/.sdirs1 ~/.sdirs
echo "export DIR_$1=$PWD" >> ~/.sdirs
}
function l {
source ~/.sdirs
env | grep "^DIR_" | cut -c5- | grep "^.*="
}
@evilbuck
evilbuck / main.r
Created August 10, 2017 17:31
R only output
# Run with `R --vanilla --slave --silent < main.R > myoutput.txt`
hello <- function (name) {
sprintf("Hello, %s", name);
}
print(hello("Insert name here"))
@evilbuck
evilbuck / text editor bookmarklet
Created January 30, 2013 00:03
quick editor for chrome bookmarklet. has javascript syntax highlighting. Great for quick, temp snippets.
data:text/html, <style type="text/css">#e{position:absolute;top:0;right:0;bottom:0;left:0;}</style><div id="e"></div><script src="http://d1n0x3qji82z53.cloudfront.net/src-min-noconflict/ace.js" type="text/javascript" charset="utf-8"></script><script>var e=ace.edit("e");e.setTheme("ace/theme/monokai");e.getSession().setMode("ace/mode/javascript");</script>
@evilbuck
evilbuck / serverless.rds.example.yml
Created June 13, 2019 17:23
serverless.yml example with rds resources plus more
# Welcome to Serverless!
#
# This file is the main config file for your service.
# It's very minimal at this point and uses default values.
# You can always add more config options for more control.
# We've included some commented out config examples here.
# Just uncomment any of them to get that config option.
#
# For full config options, check the docs:
# docs.serverless.com
@evilbuck
evilbuck / adapter-pattern-munging-data.example.js
Last active June 27, 2019 13:33
An adapter pattern example for munging data with javascript.
const v1Data = {
metrics: {
weightLb: 400,
heightFt: 6
},
macros: {
gramsFat: 1000
}
};
@evilbuck
evilbuck / adapter-pattern-munging-data.example.js
Created June 27, 2019 13:33
Adapter pattern in javascript using data munging example.
const v1Data = {
metrics: {
weightLb: 400,
heightFt: 6
},
macros: {
gramsFat: 1000
}
};
@evilbuck
evilbuck / machine.js
Created September 3, 2019 23:19
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
# If you come from bash you might have to change your $PATH.
# export PATH=$HOME/bin:/usr/local/bin:$PATH
# Path to your oh-my-zsh installation.
export ZSH="/home/evilbuck/.oh-my-zsh"
# Set name of the theme to load --- if set to "random", it will
# load a random theme each time oh-my-zsh is loaded, in which case,
# to know which specific one was loaded, run: echo $RANDOM_THEME
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes