File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change 1+ class FennelLs < Formula
2+ desc "Language Server for Fennel"
3+ homepage "https://git.sr.ht/~xerool/fennel-ls/"
4+ url "https://git.sr.ht/~xerool/fennel-ls/archive/0.2.1.tar.gz"
5+ sha256 "564c9db4565decad5495e6112e025baeeb41000b03b82f237854e485f814f74b"
6+ license "MIT"
7+
8+ bottle do
9+ sha256 cellar : :any_skip_relocation , all : "07813eac3528489a90fd5ac7c0d3e56210f6783021a4e9abb51b069edf456515"
10+ end
11+
12+ depends_on "pandoc" => :build
13+ depends_on "lua"
14+
15+ def install
16+ # upstream has bump the version to 0.2.2-dev, https://git.sr.ht/~xerool/fennel-ls/commit/6826c7584d35660aac0fc52f3db7a13c52542f3b
17+ # upstream bug report, https://todo.sr.ht/~xerool/fennel-ls/87
18+ inreplace "src/fennel-ls/utils.fnl" , "0.2.0" , version . to_s
19+
20+ system "make"
21+ system "make" , "PREFIX=#{ prefix } " , "install"
22+ end
23+
24+ test do
25+ assert_match version . to_s , shell_output ( "#{ bin } /fennel-ls --version" )
26+
27+ ( testpath /"test.fnl" ) . write <<~FENNEL
28+ { foo }
29+ FENNEL
30+
31+ expected = "test.fnl:1:6: error: expected even number of values in table literal"
32+ assert_match expected , shell_output ( "#{ bin } /fennel-ls --lint test.fnl 2>&1" , 1 )
33+ end
34+ end
You can’t perform that action at this time.
0 commit comments