Skip to content

Commit

Permalink
Merge pull request #120 from fmcgeough/doc_generated_with_ex_doc
Browse files Browse the repository at this point in the history
Doc generated with ex doc
  • Loading branch information
zmstone authored Jun 14, 2024
2 parents 37012b5 + 1a5c411 commit 2e441ae
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
# Compile
- name: Compile
run: |
rebar3 do compile, dialyzer, edoc, xref
rebar3 do compile, dialyzer, ex_doc, xref
# Tests
- name: Run tests
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ rebar.lock
*.log
*.iml
.idea/*
.DS_Store
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,10 @@ edoc: profile=edown
edoc:
@$(rebar_cmd) edoc

.PHONY: ex_doc
ex_doc:
@$(rebar_cmd) ex_doc

.PHONY: dialyze
dialyze: compile
@$(rebar_cmd) dialyzer
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ To test with an existing kafka cluster set below environment variables:
- `KPRO_TEST_KAFKA_TOPIC_NAME`: Topic name for message produce/fetch test.
- `KPRO_TEST_KAFKA_TOPIC_LAT_NAME`: Topic name for message produce/fetch test with `message.timestamp.type=LogAppendTime` set.
- `KPRO_TEST_KAFKA_SASL_USER_PASS_FILE`: A text file having two lines for username and password.
- `KPRO_TEST_SSL_TRUE`: Set to 'TRUE' or 'true' or '1' to use `ssl => true' in connection config (if kafka ca is trusted already)
- `KPRO_TEST_SSL_TRUE`: Set to `TRUE` or `true` or '1' to use `ssl => true` in connection config (if kafka ca is trusted already)
- `KPRO_TEST_SSL_CA_CERT_FILE`: Ca cert file
- `KPRO_TEST_SSL_KEY_FILE`: Client private key file
- `KPRO_TEST_SSL_CERT_FILE`: Client cert file
Expand Down
19 changes: 19 additions & 0 deletions rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,22 @@
{xref_checks, [undefined_function_calls, undefined_functions,
locals_not_used, deprecated_function_calls,
deprecated_functions]}.

{project_plugins, [rebar3_hex, rebar3_ex_doc]}.

{hex, [
{doc, #{provider => ex_doc}}
]}.

{ex_doc, [
{extras, [
{"changelog.md", #{title => "ChangeLog"}},
{"README.md", #{title => "Overview"}},
{"LICENSE", #{title => "License"}},
{"NOTICE", #{title => "Notice"}}
]},
{main, "README.md"},
{homepage_url, "https://hexdocs.pm/kafka_protocol"},
{source_url, "https://github.com/kafka4beam/kafka_protocol"},
{api_reference, false}
]}.
2 changes: 1 addition & 1 deletion src/kpro.erl
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ connect(Endpoint, ConnConfig) ->
connect_any(Endpoints, ConnConfig) ->
kpro_brokers:connect_any(Endpoints, ConnConfig).

%% @doc Sotp connection process.
%% @doc Stop connection process.
-spec close_connection(connection()) -> ok.
close_connection(Connection) ->
kpro_connection:stop(Connection).
Expand Down

0 comments on commit 2e441ae

Please sign in to comment.