rune 0.10.3 (new formula)

* rune 0.10.3 (new formula)
* rune:  cleaner install logic

Closes #92342.

Co-authored-by: Carlo Cabrera <30379873+carlocab@users.noreply.github.com>
Signed-off-by: rui <rui@chenrui.dev>
Signed-off-by: BrewTestBot <1589480+BrewTestBot@users.noreply.github.com>
master
Alexander Ronald Altman 2021-12-31 20:35:03 -08:00 committed by BrewTestBot
parent 8683a04e08
commit e71d358224
No known key found for this signature in database
GPG Key ID: 82D7D104050B0F0F
1 changed files with 25 additions and 0 deletions

25
Formula/rune.rb Normal file
View File

@ -0,0 +1,25 @@
class Rune < Formula
desc "Embeddable dynamic programming language for Rust"
homepage "https://rune-rs.github.io"
url "https://github.com/rune-rs/rune/archive/refs/tags/0.10.3.tar.gz"
sha256 "6a7154191b9f279bad68ac474107d9a24ff8470d3aca243c9805c2ea90534dbb"
license any_of: ["Apache-2.0", "MIT"]
head "https://github.com/rune-rs/rune.git", branch: "main"
depends_on "rust" => :build
def install
system "cargo", "install", *std_cargo_args(path: "crates/rune-cli")
system "cargo", "install", *std_cargo_args(path: "crates/rune-languageserver")
end
test do
(testpath/"hello.rn").write <<~EOS
pub fn main() {
println!("Hello, world!");
}
EOS
assert_match(/Hello, world!\n== \(\) \([\d.]+[µm]?s\)/,
shell_output("#{bin/"rune"} run #{testpath/"hello.rn"}").strip)
end
end