Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changes done for specifying as rebar dependency #14

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ test/server_root/logs/*_log
build
dist
doc
ebin
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,16 @@ See
to learn how to delegate incoming Cowboy HTTP requests to the
JSON-RPC service dispatcher.

### Specifying as rebar dependency

To specify erlang-rfc4627 as dependency in your rebar config please use like below

```erlang
{deps, [
{'erlang-rfc4627', ".*", {git, "git://github.com/tonyg/erlang-rfc4627.git", "master"}}
]}.
```

## Running the example test service that comes with the source code

Included with the Erlang RFC4627 source code is a small Inets-based
Expand Down
18 changes: 0 additions & 18 deletions ebin/rfc4627_jsonrpc.app

This file was deleted.

7 changes: 7 additions & 0 deletions src/erlang-rfc4627.app.src
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{application, 'erlang-rfc4627',
[{description, "RFC4627 for erlang"},
{vsn, "1.1.1"},
{modules, []},
{registered, []},
{env, []},
{applications, [kernel, stdlib]}]}.
2 changes: 1 addition & 1 deletion src/rfc4627_jsonrpc.erl
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ register_service(Pid, ServiceDescription) ->
%% @spec () -> string()
%% @doc Generates a unique name that can be used for otherwise unnamed JSON-RPC services.
gen_object_name() ->
Hash = erlang:md5(term_to_binary({node(), erlang:now()})),
Hash = erlang:md5(term_to_binary({node(), erlang:timestamp()})),
binary_to_hex(Hash).

%% @spec (binary(), Service::service()) -> jsonobj()
Expand Down