This file contains hidden or 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
#!/bin/bash | |
PROJECT_NAME=$1 | |
DOCKERFILE_PATH=/tmp/devcontainer_dockerfile | |
DOCKER_IMAGE=devcontainer | |
DEVCONTAINER_TEMPLATE=ghcr.io/ewilazarus/devcontainers/ewilazarus:latest | |
create_tmp_devcontainer_dockerfile() { | |
cat <<EOF > $DOCKERFILE_PATH |
This file contains hidden or 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
public class Markuper | |
{ | |
public virtual string execute(string content) | |
{ | |
return content; | |
} | |
} | |
public class H1Markuper : Markuper | |
{ |
This file contains hidden or 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 makeMarkup(tag) { | |
return function(content) { | |
return "<" + tag + ">" + content + "</" + tag + ">"; | |
}; | |
} | |
var makeP = makeMarkup("p"); | |
var makeH1 = makeMarkup("h1"); | |
console.log(makeH1("This is my header")); // <h1>This is my header</h1> |
This file contains hidden or 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 greet(language, name) { | |
var hi; | |
switch(language) { | |
case "en": | |
hi = "Hello"; | |
break; | |
case "pt": | |
hi = "Oi"; |
This file contains hidden or 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 buildFunctions() { | |
var arr = []; | |
for (var i = 0; i < 3; i++) { | |
arr.push((function(j) { | |
return function() { | |
console.log(j); | |
}; | |
}(i))); | |
} |
This file contains hidden or 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 buildFunctions() { | |
var arr = []; | |
for (var i = 0; i < 3; i++) { | |
arr.push(function() { | |
console.log(i); | |
}); | |
} | |
return arr; |
This file contains hidden or 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
// BUG | |
var id = 1; | |
for (var i = 0; i < products.length; i++) { | |
if (contains(offsetX, offsetY, products[i], 4)) { | |
var productName = products[i].name | |
var button = $('<button></button>'). | |
prop("class", "btn btn-xs btn-danger"). | |
click(function() { |
This file contains hidden or 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
{ | |
"nodes": [ | |
{ | |
"name": "A", | |
"x": 497, | |
"y": 400 | |
}, | |
{ | |
"name": "B", | |
"x": 497, |
This file contains hidden or 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
[ | |
{ | |
"name": "banana", | |
"x": 130, | |
"y": 350 | |
}, | |
{ | |
"name": "coffee", | |
"x": 465, | |
"y": 350 |
This file contains hidden or 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 | |
TARGET_DIR=~/Workspace | |
PY_VERSION=python3 | |
while getopts d:p:v: opts; do | |
case ${opts} in | |
d) TARGET_DIR=${OPTARG} ;; | |
p) PY_VERSION=${OPTARG} ;; | |
v) VENV=${OPTARG} ;; |
NewerOlder