Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
[user] | |
name = Dariusz Sadowski | |
email = dariusz.sadowski@work.com | |
[core] | |
editor = vim | |
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
#excludesfile = /home/dsdw/.gitignore | |
[web] | |
browser = google-chrome | |
[rerere] |
docker config create traefik.toml-1.1.0 traefik.toml | |
docker service update --config-rm traefik.toml-1.0.0 --config-add source=traefik.toml-1.1.0,target=traefik.toml edge-router_proxy |
version: "3.4" | |
services: | |
proxy: | |
image: traefik:latest | |
command: | |
- "--api" | |
- "--entrypoints=Name:http Address::80 Redirect.EntryPoint:https" | |
- "--entrypoints=Name:https Address::443 TLS" | |
- "--defaultentrypoints=http,https" | |
- "--acme" |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
This is my attempt to give Scala newcomers a quick-and-easy rundown to the prerequisite steps they need to a) try Scala, and b) get a standard project up and running on their machine. I'm not going to talk about the language at all; there are plenty of better resources a google search away. This is just focused on the prerequisite tooling and machine setup. I will not be assuming you have any background in JVM languages. So if you're coming from Python, Ruby, JavaScript, Haskell, or anywhere… I hope to present the information you need without assuming anything.
Disclaimer It has been over a decade since I was new to Scala, and when I was new to Scala, I was coming from a Java and Ruby background. This has probably caused me to unknowingly make some assumptions. Please feel free to call me out in comments/tweets!
One assumption I'm knowingly making is that you're on a Unix-like platform. Sorry, Windows users.
<?php | |
class SomeHandler | |
{ | |
/** | |
* @var RepositoryInterface | |
*/ | |
private $repository; | |
public function __construct(RepositoryInterface $repository) { |
import java.util.{Calendar, Date} | |
class SavingsAccount(amount: Int, percent: Double, openDate: Date) { | |
def annualInterest() : Int = { | |
(amount * percent).round.toInt | |
} | |
def monthlyInterest() : Int = { | |
annualInterest() / 12 |
[user] | |
name = User Example | |
email = user@example.com | |
[core] | |
editor = vim | |
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
#excludesfile = /home/dsdw/.gitignore | |
[web] | |
browser = google-chrome | |
[rerere] |
\(\)\n\s*\{\n\s*.*\n\s*\} |
# Customize BASH PS1 prompt to show current GIT repository and branch. | |
# by Mike Stewart - http://MediaDoneRight.com | |
# Dariusz Sadowski - http://darsadow.com - added host name after time so I know where I am | |
# SETUP CONSTANTS | |
# Bunch-o-predefined colors. Makes reading code easier than escape sequences. | |
# I don't remember where I found this. o_O | |
# Reset | |
Color_Off="\[\033[0m\]" # Text Reset |