A bundle of all Elm tools:
elm
,
elm-server
,
elm-repl
, and
elm-get
.
If you have any trouble installing at all, open an issue on this repo and then continue to the Platform Agnostic instructions which work on any OS.
Mac — use the installer and continue the getting started walkthrough for Mac.
Windows — use the installer and continue the getting
started walkthrough for Windows.
If you run into issues compiling programs, you may need to manually set your ELM_HOME
environment variable to C:/Program Files/Elm Platform/0.12.3/share
as reported
here.
Arch Linux — follow these directions and then jump to the My First Project section.
Platform Agnostic — download the Haskell Platform then run these commands:
cabal update
cabal install elm elm-server elm-repl elm-get
Again, all this should work on any platform, from Windows to Ubuntu.
Update to a newer version of Elm by just running the installer again. They link to the latest versions, and they will safely overwrite old executables and paths so your machine is in a consistent state.
This installs four command line tools:
elm
,
elm-server
,
elm-repl
, and
elm-get
.
To be able to call them from the command line,
you may need to add them to your PATH.
Now we will create a simple Elm project. The following commands will set-up a very basic project and start the Elm server.
mkdir helloElm
cd helloElm
printf "import Mouse\n\nmain = lift asText Mouse.position" > Main.elm
elm-server
The first two commands create a new directory and navigate into it. The printf
commands place a simple program into Main.elm
. Do this manually if you do not
have printf
. The final command starts the Elm server at
localhost:8000, allowing you to navigate to
Main.elm
and see your first program in action.
If you are stuck, check to see if anyone has had a similar issue. If not, open a new issue or email the list or ask a question in the #Elm IRC channel.