Rsbin compiles Rust or Haskell scripts to executables if necessary and executes the cached executables.
$ cargo install --git https://github.com/iquiw/rsbin
Configuration file is ~/.rsbin/config.toml
on Unix, %APPDATA\rsbin\config.toml
on Windows.
[[scripts]]
name = "foo"
path = "/path/to/foo.rs"
build-type = "rustc"
[[scripts]]
name = "bar"
path = "/path/to/bar.rs"
build-type = "Rustc"
With the above configuration, run script foo
as follows. It compiles foo.rs
if not yet done and executes foo
executable.
$ rsbin run foo
To list avaiable scripts, run list
. With -l
option, list paths also.
$ rsbin list
Available scripts:
foo
bar
baz