Rust's simple download script

Jacob Carlborg via Digitalmars-d digitalmars-d at puremagic.com
Tue Nov 10 04:50:47 PST 2015


On 2015-11-10 00:07, Andrei Alexandrescu wrote:
> Rust has a nice way to download at
> https://www.rust-lang.org/downloads.html for Posix:
>
> $ curl -sSf https://static.rust-lang.org/rustup.sh | sh -s --
>
> The method is simple and transparent. An optional --channel=beta or
> --channel=nightly parameter chooses between a stable release (default),
> beta, or nightly build.
>
> Should we do something similar?

A bit long but this will install DVM [1] and the latest compiler:

curl -L -o dvm 
https://github.com/jacob-carlborg/dvm/releases/download/v0.4.4/dvm-0.4.4-osx 
&& chmod +x dvm && ./dvm install dvm && source ~/.dvm/scripts/dvm && dvm 
install -l

And on Windows (with Power Shell) :

powershell -Command "Invoke-WebRequest 
https://github.com/jacob-carlborg/dvm/releases/download/v0.4.4/dvm-0.4.4-win.exe 
-OutFile dvm.exe" && dvm install dvm && dvm install -l

Links to other platforms are available here [1].

[1] https://github.com/jacob-carlborg/dvm

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list