Skip to content

Commit

Permalink
use new edown_make script to generate documentation
Browse files Browse the repository at this point in the history
To eliminate the rebar dependency on edown, change the "make edoc"
target to use the new edown_make script to generate documentation.
  • Loading branch information
vinoski committed Oct 3, 2011
1 parent c4b4bd8 commit 9d2d261
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 8 deletions.
7 changes: 6 additions & 1 deletion Makefile
Expand Up @@ -6,13 +6,18 @@ DEST:=$(PREFIX)$(PROJECT)
# from https://github.com/basho/rebar .
REBAR=rebar

# Expect to find edown_make in the PATH. This is needed only to generate
# documentation. If you don't have it, you can get it from
# https://github.com/esl/edown.git .
EDOWN_MAKE=edown_make

.PHONY: all edoc test clean build_plt dialyzer

all:
@$(REBAR) get-deps compile

edoc:
@$(REBAR) doc
$(EDOWN_MAKE) -config edown.config

test:
@rm -rf .eunit
Expand Down
11 changes: 11 additions & 0 deletions edown.config
@@ -0,0 +1,11 @@
%% -*- erlang -*-
{erlsha2, ".", [{doclet, edown_doclet},
{pretty_printer, erl_pp},
{src_path, ["src/"]},
{subpackages, true},
{stylesheet, ""},
{image, ""},
{app_default,"http://www.erlang.org/doc/man"},
{top_level_readme,
{"./doc/README.md",
"http://github.com/vinoski/erlsha2"}}]}.
12 changes: 5 additions & 7 deletions rebar.config
@@ -1,3 +1,4 @@
%% -*- erlang -*-
{so_name, "erlsha2_nif.so"}.

{port_envs, [{"DRV_CFLAGS", "$DRV_CFLAGS -O3 -I."},
Expand All @@ -9,10 +10,7 @@
{pre_hooks, [{compile, "c_src/config.sh c_src/config.h"},
{clean, "rm -f c_src/config.h"}]}.

%% The following two terms are required only for generating documentation,
%% and so are commented out by default.
%%{deps, [{edown, ".*", {git, "git://github.com/esl/edown.git", "HEAD"}}]}.
%%{edoc_opts, [{doclet, edown_doclet},
%% {pretty_printer, erl_pp},
%% {src_path, ["src/"]},
%% {subpackages, true}]}.
{edoc_opts, [{doclet, edown_doclet},
{pretty_printer, erl_pp},
{src_path, ["src/"]},
{subpackages, true}]}.

0 comments on commit 9d2d261

Please sign in to comment.