CLICK ME
yes, even hidden code blocks!
print("hello world!")| [alias] | |
| # Returns name of current branch | |
| # Usage: git current | |
| current = rev-parse --abbrev-ref HEAD | |
| # Makes a full copy of the current branch with `backup.<epoch>` appended before doing an interactive rebase | |
| # Usage: git safebase HEAD~2 | |
| safebase = !CURRENT=$(git current) && git branch -c $CURRENT $CURRENT.backup.$(date +%s) && git rebase -i |
| ## chef report handler for Consul | |
| ## depends on a chef-client check being registered with the agent | |
| ## • pings TTL-style check with ok/warning status on chef run pass/fail | |
| ## • stores run report and node attributes in chef/reports/<datacenter>/<consul_node_name> | |
| require "chef/handler" | |
| require "rest_client" | |
| class ConsulHandler < Chef::Handler | |
| attr_reader :config |
| <!-- Bibliography data --> | |
| {{ $numParams := len .Params }} | |
| {{ if eq $numParams 0 }} | |
| {{ if isset .Page.Params "bibliography" }} | |
| {{ $.Scratch.Set "bib_source" .Page.Params.bibliography }} | |
| {{ end }} | |
| {{ if isset .Page.Params "bibliography_ignore" }} | |
| {{ $.Scratch.Set "bib_ignore" .Page.Params.bibliography_ignore }} | |
| {{ end }} | |
| {{ else if eq $numParams 1 }} |
| def binary_search(L, s): | |
| '''(list) -> bool | |
| Return True iff s is an element of L, otherwise False | |
| REQ: L must be a sorted list | |
| ''' | |
| # BASE CASE: If L is empty, it's not in the list | |
| if L == []: | |
| result = False | |
| # RECURSIVE DECOMP: Pick the middle element, if we found | |
| # what we're looking for, great. If not, then we've at |
| export ANACONDAPATH=$HOME/anaconda; | |
| anaconda() { | |
| export PATH=$ANACONDAPATH/bin:$PATH; | |
| } | |
| alias "anaconda"="anaconda" | |
| nanaconda() { | |
| export PATH=$(echo $PATH | sed -e "s|$ANACONDAPATH/bin:||g"); | |
| } | |
| alias "nanaconda"="nanaconda" |
| #lang scheme | |
| (define (fact n) | |
| (fact-tail n 1)) | |
| (define (fact-tail n acc) | |
| (if (= 0 n) | |
| acc | |
| (fact-tail (- n 1) (* acc n)))) |
| #!/bin/bash | |
| ## Sample POST request to /scripts/qmd_bench.sh | |
| ## | |
| ## { | |
| ## "args": ["1", "10"], | |
| ## "callback_url": "http://192.168.88.88:9090" | |
| ## } | |
| MIN=$1 |
I hereby claim:
To claim this, I am signing this object: