This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"id": "0", | |
"title": "", | |
"children": [ | |
{ | |
"id": "1", | |
"title": "Root Folder 1", | |
"children": [ | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function flatten(obj) { | |
const result = {}; | |
for (const key of Object.keys(obj)) { | |
if (typeof obj[key] === 'object') { | |
const nested = flatten(obj[key]); | |
for (const nestedKey of Object.keys(nested)) { | |
result[`${key}.${nestedKey}`] = nested[nestedKey]; | |
} | |
} else { | |
result[key] = obj[key]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Your goal is to count how many items exist that have an age equal to or greater than 50, and print this final value. | |
$ch = curl_init('https://coderbyte.com/api/challenges/json/age-counting'); | |
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); | |
curl_setopt($ch, CURLOPT_HEADER, 0); | |
$data = curl_exec($ch); | |
curl_close($ch); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(function() { | |
var levels = [ 100, 10, 1, 0.1, 0.01, 0.001, 0.0001, 0.00001, 0.000001, 0.0000001, 0.00000001 ]; | |
var readyRows = [], levelRows = []; | |
function isCaptchaVisible() { | |
return 0 < $('#window_captcha:visible').length; | |
} | |
function restoreRows() { | |
$('#freecoins_table > tbody > tr:hidden').show(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"basics": { | |
"name": "Andrew Gerst", | |
"label": "Senior Software Engineer" | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"editor.cursorBlinking": "phase", | |
"editor.dragAndDrop": false, | |
"editor.fontSize": 16, | |
"editor.lineHeight": 26, | |
"editor.renderIndentGuides": false, | |
"editor.renderLineHighlight": "all", | |
"editor.renderWhitespace": "all", | |
"editor.tabSize": 2, | |
"files.exclude": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"in_process_packages": | |
[ | |
], | |
"installed_packages": | |
[ | |
"Advanced CSV", | |
"AdvancedNewFile", | |
"Alignment", | |
"All Autocomplete", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"installed_packages": | |
[ | |
"Passport", | |
], | |
"repositories": | |
[ | |
"https://rawgit.com/Gerst20051/a311cfc3a1c011d7aaf0f8cbeb0ea14b/raw/46397fc958810d39c66e482b6152ee4ef9566cc4/passport_sublime_plugins_repository.json" | |
], | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# execute commands at a specified interval of seconds | |
function watch.command { | |
# USAGE: watch.commands [seconds] [commands...] | |
# EXAMPLE: watch.command 5 date | |
# EXAMPLE: watch.command 5 date echo 'ls -l' echo 'ps | grep "kubectl\\\|node\\\|npm\\\|puma"' | |
# EXAMPLE: watch.command 5 'date; echo; ls -l; echo; ps | grep "kubectl\\\|node\\\|npm\\\|puma"' echo date 'echo; ls -1' | |
local cmds=() | |
for arg in "${@:2}"; do | |
echo $arg | sed 's/; /;/g' | tr \; \\n | while read cmd; do | |
cmds+=($cmd) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
# ASCII: http://patorjk.com/software/taag/#p=display&f=Graffiti&t=Docker%20Setup%20Script | |
# SOURCE: https://gist.github.com/Gerst20051/bf1341448bd43f430761c1f8150fb1b7 | |
function double_echo { | |
echo && echo | |
} | |
function newline { |
NewerOlder