-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathktor.rb
27 lines (22 loc) · 856 Bytes
/
ktor.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
class Ktor < Formula
desc "CLI tool that creates projects with ktor framework setup"
homepage "https://github.com/ktorio/ktor-cli"
url "https://packages.jetbrains.team/files/p/ktor/ktor-cli-tool/mac-releases/2.1.0-beta-1"
sha256 "f62d9e52311d1e631035476c54a1828751749a14e902254926f57d76b36d5520"
license ""
# https://youtrack.jetbrains.com/issue/KTOR-4570/Support-ARM-target-in-Ktor-client-with-KotlinNative-and-Curl
depends_on arch: :x86_64
uses_from_macos "curl"
uses_from_macos "unzip"
on_linux do
depends_on "curl"
end
def install
bin.install "2.1.0-beta-1" => "ktor"
end
test do
system "ktor", "generate", "projectName"
assert_predicate Pathname.new("projectName/build.gradle.kts"), :exist?
assert_predicate Pathname.new("projectName/src/main/kotlin/com/example/Application.kt"), :exist?
end
end