Minor changes in makefile; moved bundle install to make setup
This commit is contained in:
parent
4df09d9b05
commit
abfff1ac17
2 changed files with 24 additions and 12 deletions
|
@ -36,7 +36,7 @@ before_install:
|
|||
- export PATH=$HOME/.local/bin:$PATH
|
||||
- travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
|
||||
# Download and install agda, agda-stdlib, and agda2html
|
||||
- make setup
|
||||
- make travis-setup setup
|
||||
|
||||
script:
|
||||
- make
|
||||
|
|
34
Makefile
34
Makefile
|
@ -2,45 +2,57 @@ agda := $(wildcard src/*.lagda)
|
|||
agdai := $(wildcard src/*.agdai)
|
||||
markdown := $(subst src/,out/,$(subst .lagda,.md,$(agda)))
|
||||
|
||||
default: $(markdown)
|
||||
all: $(markdown)
|
||||
|
||||
out/:
|
||||
mkdir out
|
||||
mkdir -p out
|
||||
|
||||
out/%.md: src/%.lagda out/
|
||||
agda2html --verbose --link-to-agda-stdlib --jekyll-root=out/ -i $< -o $@
|
||||
|
||||
.phony: serve
|
||||
|
||||
# serve website using jekyll
|
||||
serve:
|
||||
ruby -S gem install bundler --no-ri --no-rdoc
|
||||
ruby -S bundle install
|
||||
ruby -S bundle exec jekyll serve
|
||||
|
||||
.phony: clean
|
||||
.phony: serve
|
||||
|
||||
|
||||
# remove all auxiliary files
|
||||
clean:
|
||||
ifneq ($(strip $(agdai)),)
|
||||
rm $(agdai)
|
||||
endif
|
||||
|
||||
.phony: clobber
|
||||
.phony: clean
|
||||
|
||||
|
||||
# remove all generated files
|
||||
clobber: clean
|
||||
ruby -S gem install bundler --no-ri --no-rdoc
|
||||
ruby -S bundle install
|
||||
ruby -S bundle exec jekyll clean
|
||||
ifneq ($(strip $(markdown)),)
|
||||
rm $(markdown)
|
||||
endif
|
||||
rmdir out/
|
||||
|
||||
setup:\
|
||||
.phony: clobber
|
||||
|
||||
|
||||
# install bundler, and gem dependencies
|
||||
setup:
|
||||
ruby -S gem install bundler --no-ri --no-rdoc
|
||||
ruby -S bundle install
|
||||
|
||||
.phony: setup
|
||||
|
||||
|
||||
# install agda, agda-stdlib, and agda2html
|
||||
travis-setup:\
|
||||
$(HOME)/agda-master/\
|
||||
$(HOME)/agda-stdlib-master/\
|
||||
$(HOME)/agda2html-master/
|
||||
|
||||
.phony: setup
|
||||
.phony: travis-setup
|
||||
|
||||
$(HOME)/agda-master/:
|
||||
curl -L https://github.com/agda/agda/archive/master.zip -o $(HOME)/agda-master.zip
|
||||
|
|
Loading…
Add table
Reference in a new issue