-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdecor.rb
More file actions
26 lines (21 loc) · 768 Bytes
/
Copy pathdecor.rb
File metadata and controls
26 lines (21 loc) · 768 Bytes
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
class Decor < Formula
desc "Markdown transformer for single page, which uses a HTML file as a template"
homepage "https://github.com/tai2/decor"
url "https://github.com/tai2/decor/archive/refs/tags/v1.1.3.tar.gz"
sha256 "2c11d45e71a432befbd2034b06a6093c9f334929a854c2156e7d5eef72508d52"
license "MIT"
depends_on "deno"
def install
prefix.install "src"
system "deno", "install", "--allow-read", "--allow-write", "--root", ".", "#{prefix}/src/decor.ts"
bin.install "bin/decor"
end
test do
(testpath/"test.md").write <<~EOS
# A markdown file
This is an *example* content
EOS
system "#{bin}/decor", testpath/"test.md", "--output", testpath/"test.html"
assert_predicate testpath/"test.html", :exist?
end
end