git clone works
[repobrowse.git] / GNUmakefile
blobd31998b5a7f8b7c7f9220833d137f2ac49fbfae9
1 # Copyright (C) 2013-2017 all contributors <repobrowse@80x24.org>
2 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
3 all::
4 rubybin := $(shell which ruby)
5 RUBY = $(rubybin)
6 lib := lib
8 ifeq ($(RUBY_TEST_OPTS),)
9 ifeq ($(V),1)
10 RUBY_TEST_OPTS := -v
11 endif
12 endif
14 all:: test
15 test_units := $(wildcard test/test_*.rb)
16 test: $(test_units)
17 $(test_units):
18 $(RUBY) -I $(lib) $@ $(RUBY_TEST_OPTS)
20 check-warnings:
21 @(for i in $$(git ls-files '*.rb'| grep -v '^setup\.rb$$'); \
22 do $(RUBY) -d -W2 -c $$i; done) | grep -v '^Syntax OK$$' || :
24 check: test
26 .PHONY: all test $(test_units) NEWS
27 .PHONY: check-warnings fix-perms