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
class Pizza { | |
final String sauce; | |
final List<String> toppings; | |
final bool hasExtraCheese; | |
Pizza._builder(PizzaBuilder builder) : | |
sauce = builder.sauce, | |
toppings = builder.toppings, | |
hasExtraCheese = builder.hasExtraCheese; | |
} |
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
# Remove local branches no longer on remote, also keeping master and not pushed local branches | |
alias cleanupgit="git checkout master && git fetch -p && git branch -vv | awk '/: gone]/{print }' | xargs git branch -d" | |
# Opens the browser on the specific associate Jira ticket with the current git branch | |
alias jira="git rev-parse --abbrev-ref HEAD | sed -E 's/.*(futrli|FUTRLI|Futrli)(-)([0-9]+).*/\1\2\3/g' | xargs -I{} open https://crunchboards.atlassian.net/browse/{} " |
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
.text-shadow (@string: 0 1px 3px rgba(0, 0, 0, 0.25)) { | |
text-shadow: @string; | |
} | |
.box-shadow (@string) { | |
-webkit-box-shadow: @string; | |
-moz-box-shadow: @string; | |
box-shadow: @string; | |
} | |
.drop-shadow (@x: 0, @y: 1px, @blur: 2px, @spread: 0, @alpha: 0.25) { | |
-webkit-box-shadow: @x @y @blur @spread rgba(0, 0, 0, @alpha); |
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
// Promise.all is good for executing many promises at once | |
Promise.all([ | |
promise1, | |
promise2 | |
]); | |
// Promise.resolve is good for wrapping synchronous code | |
Promise.resolve().then(function () { | |
if (somethingIsNotRight()) { | |
throw new Error("I will be rejected asynchronously!"); |
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
/* | |
* Set up your Git configuration | |
*/ | |
git config --global user.email "[email protected]" | |
git config --global user.name "Your Name" | |
git config --global core.editor "nano" |