Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| sealed trait Interact[A] | |
| case class Ask(prompt: String) | |
| extends Interact[String] | |
| case class Tell(msg: String) | |
| extends Interact[Unit] | |
| trait Monad[M[_]] { | |
| def pure[A](a: A): M[A] |
| ; scala-mode2 found here: https://github.com/hvesalai/scala-mode2 is much better than the scala mode that comes with scalac | |
| (add-to-list 'load-path "~/.emacs.d/scala-mode2/") | |
| (require 'scala-mode) | |
| ; http://www.emacswiki.org/emacs/RainbowDelimiters | |
| (add-hook 'scala-mode-hook 'rainbow-delimiters-mode) | |
| ; I get ensime from git: | |
| ; https://github.com/aemoncannon/ensime | |
| ; then run `sbt stage` inside the ensime source directory, |
| import scalaz._ | |
| import Scalaz._ | |
| import scala.concurrent.{ExecutionContext, Future} | |
| import scala.concurrent.Await | |
| import scala.concurrent.duration._ | |
| import ExecutionContext.Implicits.global | |
| object FSE extends App { | |
| // scalaz doesn't yet have a monad instance for future, here is one. |
| # Mac OS X Lion introduced a new, iOS-like context menu when you press and hold a key | |
| # that enables you to choose a character from a menu of options. If you are on Lion | |
| # try it by pressing and holding down 'e' in any app that uses the default NSTextField | |
| # for input. | |
| # | |
| # It's a nice feature and continues the blending of Mac OS X and iOS features. However, | |
| # it's a nightmare to deal with in Sublime Text 2 if you're running Vintage (Vim) mode, | |
| # as it means you cannot press and hold h/j/k/l to move through your file. You have | |
| # to repeatedly press the keys to navigate. |